Java Frameworks Indy Java Users Group January 29, 2003.

Slides:



Advertisements
Similar presentations
Introduction to the Spring Framework
Advertisements

January 30, 2014 Copyright Jim Farley Beyond JDBC: Java Object- Relational Mappings Jim Farley e-Commerce Program Manager GE Research and Development
3 Copyright © 2005, Oracle. All rights reserved. Designing J2EE Applications.
Web Development with Karsten Schulz Terp-Nielsen Master Principal Sales Consultant Oracle Denmark.
Apache Struts Technology
J2EE Design patterns Sharath Sahadevan August 8, 2002 St Louis Java SIG.
Spring, Hibernate and Web Services 13 th September 2014.
An architecture for webb applications, J2EE
George Blank University Lecturer. CS 602 Java and the Web Object Oriented Software Development Using Java Chapter 10.
Enterprise Applications & Java/J2EE Technologies Dr. Douglas C. Schmidt Professor of EECS.
Struts Basics SSE USTC Qing Ding. Agenda What is and Why Struts? Struts architecture – Controller: Focus of this presentation – Model – View Struts tag.
© 2005, Cornell University. Rapid Application Development using the Kuali Architecture (Struts, Spring and OJB) A Case Study Bryan Hutchinson
J2EE Java2 Enterprise Edition by Damian Borth. Contents Introduction Architectures styles Components Scenarios Roles Processing a HTTP request.
Pragmatic Application Building: Step by Step Jay Sissom Principal Systems Analyst Indiana University
Faculty of Information Technology © Copyright UTS Faculty of Information Technology 2004Design-1 Advanced Java Programming Design issues Chris Wong
Application Architectures Vijayan Sugumaran Department of DIS Oakland University.
Structure of a web application1 Dr Jim Briggs. MVC Structure of a web application2.
Apache Struts Technology A MVC Framework for Java Web Applications.
Session-01. Layers Struts 2 Framework The struts 2 framework is used to develop MVC-based web application. Struts 1.0 was released in June The.
Web Application Architecture: multi-tier (2-tier, 3-tier) & mvc
Java Pet Store Application. Outline Introduction Introduction Information Layer Information Layer Application Layer Application Layer Infrastructure Layer.
Struts 2.0 an Overview ( )
Introduction to Struts 2.0 Jenny Ni Joey Feng Winddays Wang Hewmmi Zhu Heather Lv Software School,Fudan University 1.
Struts. Agenda Preface Struts and its components An example The architecture required for Struts Applications.
UNIT-V The MVC architecture and Struts Framework.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 18 Slide 1 Software Reuse 2.
Chapter 10 EJB Concepts of EJB Three Components in Creating an EJB Starting/Stopping J2EE Server and Deployment Tool Installation and Configuration of.
JDBC Session 5 Tonight: Data Access Patterns 1.J2EE Architecture & Design Patterns 2.The Data Access Tier 3.Data Access Patterns –DataAccessObject (DAO)
Introduction to the Enterprise Library. Sounds familiar? Writing a component to encapsulate data access Building a component that allows you to log errors.
NMS1.0(c) Copyright Final Year Project Demonstration Dublin City University 29 th May 2003 Team Members : David ReadeTimothy Kelly
Copyright © 2012 Accenture All Rights Reserved.Copyright © 2012 Accenture All Rights Reserved. Accenture, its logo, and High Performance Delivered are.
COMP 410 & Sky.NET May 2 nd, What is COMP 410? Forming an independent company The customer The planning Learning teamwork.
Introduction to J2EE Architecture Portions by Kunal Mehta.
EJB Framework.  As we know, EJB is the center of the J2EE architecture that provides a sturdy framework for building enterprise applications. The major.
TDDD05 EJB Lab (Part of slides reused from Mikhail’s) Lu Li
JSP Architecture Outline  Model 1 Architecture  Model 2 Architecture.
® IBM Software Group © 2007 IBM Corporation J2EE Web Component Introduction
8/15/2003System Specialists Corporation How to implement BC4J with the Struts Framework Eugene Sicat Technical Architect/Project Manager System Specialists.
JSF Introduction Copyright © Liferay, Inc. All Rights Reserved. No material may be reproduced electronically or in print without written permission.
Struts J2EE web application framework “ Model 2 ” Model View Controller Controller Servlet Key features XML metadata Struts taglib Simplified form validation.
Lecturer: Prof. Piero Fraternali, Teaching Assistant: Alessandro Bozzon, Advanced Web Technologies: Struts–
Adaptive Hypermedia Tutorial System Based on AHA Jing Zhai Dublin City University.
Component frameworks Roy Kensmil. Historical trens in software development. ABSTRACT INTERACTIONS COMPONENT BUS COMPONENT GLUE THIRD-PARTY BINDING.
Struts Framework Anna Paščenko. What is Struts?  An open source framework for building Java web applications.
Model View Controller Architecture of Java Web Applications Dr. M V S Peri Sastry, Ph.D.[BITS-Pilani]
Apache Struts. J2EE Web Application using MVC design pattern Why MVC? Separate components = easier maintenance – Model component holds object data – View.
COMP9321 Web Application Engineering Semester 2, 2015 Dr. Amin Beheshti Service Oriented Computing Group, CSE, UNSW Australia Week 8 1COMP9321, 15s2, Week.
Java EE Patterns Dan Bugariu.  What is Java EE ?  What is a Pattern ?
Page 1 R MVC Design Pattern Definition Properties Describing MVC design patterns.
Spring and DWR Frameworks for Rich Web Enterprise Application Thomas Wiradikusuma Presentation to the 20 th.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
Preface IIntroduction Objectives I-2 Course Overview I-3 1Oracle Application Development Framework Objectives 1-2 J2EE Platform 1-3 Benefits of the J2EE.
1 Copyright © 2004, Oracle. All rights reserved. Oracle Application Development Framework.
1 Java Server Pages A Java Server Page is a file consisting of HTML or XML markup into which special tags and code blocks are inserted When the page is.
Java Programming: Advanced Topics 1 Enterprise JavaBeans Chapter 14.
Lecture 21: Component-Based Software Engineering
Text 16 de mayo de 2009 Spring Framework Part III. Portable Service Abstractions and Spring MVC Buenos Aires, June 2009.
Apache Struts Technology A MVC Framework for Java Web Applications.
Introduction to J2EE 1 Introduction to Java 2 Enterprise Edition Presented by Software engineering group Computer science faculty Binus University Welcome!
Enterprise Java v050228MVC1 Model, View, Controller Web Architecture.
Structure of a web application
Introduction to J2EE Architecture
Unit 6-Chapter 2 Struts.
Design and Maintenance of Web Applications in J2EE
The Model Layer What is Model?
J2EE Application Framework
JavaServer Faces: The Fundamentals
Web Application Server 2001/3/27 Kang, Seungwoo. Web Application Server A class of middleware Speeding application development Strategic platform for.
Component-based Applications
Knowledge Byte In this section, you will learn about:
Presentation transcript:

Java Frameworks Indy Java Users Group January 29, 2003

Introduction David Stevenson – FUSION Alliance Senior Software Developer 9+ years of OOA & OOD experience 4+ years Java experience Sun Certified Java Programmer Developed systems for DOD and several Fortune 500 companies

Agenda What are frameworks Why do we need frameworks Advantages of frameworks Identify common frameworks Architectural frameworks Example

What are frameworks? Components/tools used to create applications. Tried and tested. Fulfill a specific need. Easy interface. Extensible. May be based on established Design Patterns.

Why do we need frameworks? In today’s economy, clients expect more for less. With a standard set of building blocks available, we can concentrate on the implementation of the business logic. It allows for either a shortened development timeframe or the ability to deliver more functionality. Cost – Schedule – Quality

Some more advantages derived from the use of frameworks Allows faster prototyping. Improved application quality: Fewer opportunities to introduce defects. Easier learning curve for new developers: Simplified APIs & better documentation Experienced peers for available for support Examples exists displaying proper usage. Consistent design across applications. Easier for the maintenance activity.

Identify some common frameworks The following are horizontal frameworks. Logging Configuration Exception Hierarchy Database Management JNDI Lookup

Logging Framework Provide a simple to use interface with a flexible output capability (format and location). This will facilitate its use for application development debugging as well as application health monitoring. Recommend that this framework be built as a Service Provider Interface. Therefore, this framework will support any logging engine that implements the interface.

Logging Framework Possible Logging Engines include: StdOut Log4J JDK 1.4 Logging API

Logging Framework Recommend a set of logging standards for developers to follow. Guidelines for Debugging Method Entry/Exit Key Decision Points LogIt.debug(“descriptive message” + value); Guidelines for Exceptions LogIt.error(“message”, thrownException);

Configuration Framework Provide a single access point for readily accessing configuration and semi-dynamic information in order to avoid hard coding into application code. Allows for the hiding of vendor specific information. Support standard Java properties files test.data=test Should consider supporting XML files

Configuration Framework Can be used to minimize use of J2EE container environment entry lookups. Recommend supporting the return of more than just java.lang.String types. Configurator.get(“test.data”); -> “test” Configurator.getLong(“test.long”); -> 99

Exception Hierarchy Provide a consistent exception handling representation and processing for application development. Provide a base class that handles exception messages and can capture the thrown exception for logging purposes.

Exception Hierarchy Consider extending the base exception class to handle tier and system exceptions. IntegrationSystemException BusinessSystemException BusinessException PresentationException

Database Management Framework Easy to use interface to get a connection to a database. Return a connection based on an alias. Connection from a DriverManager Connection from a DataSource DriverManagers and DataSources are created during an initialization process.

Database Management Framework Framework could implement the Singleton Design Pattern. Connections are returned using static calls: DatabaseHelper.getInstance().getConnection(“alias”);

JNDI Lookup Framework Abstract all JNDI usage and to hide the complexities of initial context creation and JNDI lookups including EJB Home lookups. Framework could be based on the Service Locator Design Pattern

Architectural Frameworks A base structure used for the rapid development of a family of applications. Based on Proven Design Patterns Consists Extensible Components Provided with Implementation Guidelines and Examples

Architectural Frameworks Examples MVC Object – RDMS Mapping Business Service using EJBs

MVC Framework The goal of a Model-View-Controller framework is to achieve decoupling among the software components that are responsible for encapsulating business functions, rendering the content and controlling the navigation or flow.

Jakarta Struts MVC Framework Implements the following Design Patterns. Front Controller Service to Worker View Helpers Composite View

Jakarta Struts MVC Framework

Controller Servlet configuration is handled by entries in struts-config.xml

Jakarta Struts MVC Framework Use of the Struts framework is handled by entries in web.xml action org.apache.struts.action.ActionServlet application ApplicationResources config /WEB-INF/struts-config.xml 2 action /ssl/* /WEB-INF/struts-bean.tld /WEB-INF/struts-html.tld /WEB-INF/struts-template.tld

Jakarta Struts MVC Framework General guidance Try to design one Action to handle a specific work flow. Only use session scope if the workflow will span more that one JSP. Use Business Delegates in Action classes to handle the actual processing and let the Action deal with forwarding decisions based on the Business Delegate results.

Business Service Framework This framework design is based on the following Design Patterns Business Delegate – Wraps the workflow management of the Session Facade. Session Facade – The session bean for work- flow management. Data Access Objects – one for each table in the database. Value Objects – one for each table in the database.

Business Service Framework Stateless Session Beans are used for CRUD operations that are called by the Session Facade. Read-Only Entity Beans – Used for retrieving values from Look-Up tables. The interfaces for DAOs, EJBs and the Business Delegate expect a Container of Value Objects.

Business Service Framework Client Side Client Object VO VO Containe r Business Delegate Session Facade EJB

Business Service Framework Session Facade EJB Database DAODAO Sessio n EJB Entity EJB Sessio n EJB Server Side

Example User Registration Application MVC front-end Business Service to MySQL database

Q & A Questions?