Published on

  • Be the first to comment

  • Be the first to like this

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide
  • J2EE defines a simple standard that applies to all aspects of architecting and developing large scale applications. J2EE naturally encourages the adoption of a multiple tier architecture and a strict separation between business logic and the presentation layer. In addition, the architectural approach suggested by the J2EE standards lends itself to the implementation of highly scalable infrastructures, such as WebSphere, where the application workload can be transparently distributed across a number of concurrent processes, or even across a number of parallel systems. J2EE also provides technologies to facilitate the integration of existing applications with newly developed J2EE applications. The specifications are generic enough to allow an end customer to choose among a wide array of middleware, tools, hardware, operating systems, and application designs. Actually, J2EE has sparked a whole new market of application servers, development tools, connectors, and components - where IBM is in the leading position with a vast portfolio of best of breed products. Security is one of the premier areas of focus in J2EE - actually, the security specifications have been significantly redesigned to better fit the demands of Internet-based environments and to better integrate with legacy security schemes.
  • J2EE Application components execute in runtime environments provided by the containers that are part of the J2EE platform. The J2EE platform supports four separate types of containers, one for each J2EE application component type - application client containers, applet containers, web containers for Servlets and JSPs and enterprise bean containers. The J2EE platform also includes a number of Java Standard extensions . Table indicates which standard extensions are required to be available in each type of container.Table also indicates the required version of the Standard Extension.
  • JSP enables server side scripting using Java. Server-side scripting is not an alternative to client-side scripting. Client-side scripting (JavaScript or Java Applet) is important for performing input validity tests and other computation eliminating interaction with the server. A JSP Page is an HTML document with special embedded tags and inline Java Code. At runtime, the JSP Page is parsed and compiled into a Java Servlet. JSP Pages enable you to effectively separate the HTML coding from the business logic in your Web pages. JSP Pages can be built using a Web page editor. JSP provides a simpler mechanism to create dynamic content than coding a servlet. This parsing, code generation, compilation need only be performed once (if .jsp file does not change). The loading and execution is a separate step which follows normal Servlet loading and execution rules. If the "JSP Servlet" is currently loaded, and a request for the JSP page is made, the JSP Servlet's service method is invoked. If the JSP Servlet exists (.class file) but is not yet loaded -- it is loaded and then its service method is invoked.
  • Servlet 2.2 extends Servlet 2.1 with support for the packaging and deployment of web applications, standalone and as part of a J2EE application. Servlet2.2 also addresses security, both standalone and within the J2EE platform and provides support for the notion of a Web Application.
  • Notes: Applications servers allow you to run server side Java applications such as servlets, JavaServer Pages and Enterprise JavaBeans. They simplify the deployment of web-enabled e-business applications. They allow you to contol and scale your server side Java applications.
  • Notes: Applications servers allow you to run server side Java applications such as servlets, JavaServer Pages and Enterprise JavaBeans. They simplify the deployment of web-enabled e-business applications. They allow you to contol and scale your server side Java applications.
  • Dictates component's interaction with container
  • The relational model used the basic concept of a relation or table. The columns or fields in the table identify the attributes such as name, age, and so. A tuple or row contains all the data of a single instance of the table such as a person named Doug. In the relational model, every tuple must have a unique identification or key based on the data. In this figure, a social security account number (SSAN) is the key that uniquely identifies each tuple in the relation. Often, keys are used to join data from two or more relations based on matching identification. The relational model also includes concepts such as foreign keys, which are primary keys in one relation that re kept in another relation to allow for the joining of data. As an example of foreign keys is storing your mother's and father's SSAN in the tuple that represent you. Your parents' SSANs are keys for the tuples that represent them and they are foreign keys in the the tuple that represents you.
  • Review

    1. 1. e-business Application Development
    2. 2. J2EE vs .Net
    3. 3. Benefits of J2EE <ul><li>Simplified architecture and development </li></ul><ul><ul><li>Variety of standard services, components, and clients </li></ul></ul><ul><ul><li>Choices of tools </li></ul></ul><ul><ul><li>Portability </li></ul></ul><ul><ul><li>Integration with existing information systems </li></ul></ul><ul><li>Separation of Responsibilities </li></ul><ul><li>Scalability </li></ul><ul><li>Flexible security model </li></ul>
    4. 4. API Applet Application Client Web EJB JDBC 2.0 N Y Y Y JTA 1.0 N N Y Y JNDI 1.2 N Y Y Y Servlet 2.3 N N Y N JSP 1.2 N N Y N EJB 2.0 N Y 1 Y 2 Y RMI-IIOP 1.0 N Y Y Y JMS 1.0x N Y Y Y JavaMail 1.2 N N Y Y JAF 1.0x N N Y Y J2EE 1.3 Required Standard Extension APIs 1 Application clients can only make use of the enterprise bean client APIs. 2 Servlets and JSP pages can only make use of the enterprise bean client APIs. J2EE Technologies Summary
    5. 5. <ul><li>HTML document </li></ul><ul><ul><li>Embedded JSP specific tags </li></ul></ul><ul><ul><li>Inline Java Code </li></ul></ul><ul><li>On the server, JSP Page is parsed and compiled into a Java Servlet </li></ul><ul><li>WebSphere 5.0 fully supports JSP1.2 </li></ul>Server Side Component - JSP
    6. 6. Server-Side Components - Servlets <ul><li>Servlets are Java classes that allow application logic to be embedded in HTTP request-response process. </li></ul><ul><li>J2EE 1.3 requires: </li></ul><ul><ul><li>Servlet 2.3 specification </li></ul></ul>
    7. 7. J2EE Services: JDBC <ul><li>Provides database-independent connectivity to a variety of data stores </li></ul><ul><li>J2EE 1.2 specifies: </li></ul><ul><ul><li>JDBC 2.0 Core APIs - Basic database services </li></ul></ul><ul><ul><li>JDBC 2.0 Extension APIs - Advanced functionality </li></ul></ul><ul><ul><ul><li>Connection Pooling </li></ul></ul></ul><ul><ul><ul><li>Transactional capabilities </li></ul></ul></ul><ul><li>Functionality provided by a combination of WebSphere and a compliant JDBC driver </li></ul>
    8. 8. <ul><li>Application Servers: </li></ul><ul><ul><li>Work with Web server to manage browser and Java based client sessions </li></ul></ul><ul><ul><li>Support server-side business logic (Servlets/JavaServer Pages/EJBs) </li></ul></ul><ul><ul><li>Connect to back end computing resources for data and transaction processing </li></ul></ul><ul><li>Application server benefits: </li></ul><ul><ul><li>Simplify development and deployment of web-enabled e-business applications </li></ul></ul><ul><ul><li>Support connections to legacy data and applications </li></ul></ul><ul><ul><li>Deliver a set of application deployment and management tools </li></ul></ul>Application Serving Transaction Serving Active Business Rules Web Server Business Applications App Server Client Page Serving User Interface Transactions Application Servers
    9. 9. Model-View-Controller architecture <ul><li>Reduce the programming effort required to build and maintain systems </li></ul><ul><li>Separate the application into 3 distinct layers </li></ul><ul><ul><li>Controller - application flow </li></ul></ul><ul><ul><li>Model - business logic </li></ul></ul><ul><ul><li>View - the output </li></ul></ul><ul><li>Models, Controllers, and the views are treated as separate entities </li></ul><ul><li>Changes can be made independently </li></ul><ul><li>Different people/skills can work independently </li></ul>
    10. 10. WebSphere Application Server /JSP Model 1 Model 2
    11. 11. Software <ul><li>HTTP Servers </li></ul><ul><ul><li>Apache HTTP Server (Open Source) </li></ul></ul><ul><ul><li>IBM HTTP Server powered by Apache </li></ul></ul><ul><ul><li>Many others </li></ul></ul><ul><li>Some Application Servers </li></ul><ul><ul><li>Jakata Apache (Open Source) </li></ul></ul><ul><ul><ul><li>Tomcat </li></ul></ul></ul><ul><ul><li>IBM WebSphere Application Server </li></ul></ul><ul><ul><li>BEA Weblogic </li></ul></ul><ul><ul><li>Sun iPlanet </li></ul></ul><ul><ul><li>And more </li></ul></ul><ul><li>Comparable MS support </li></ul><ul><ul><li>IIS (Internet Information Services) </li></ul></ul>
    12. 12. WebSphere Application Server - Express <ul><li>An offering from IBM that contains: </li></ul><ul><ul><li>WebSphere Application Server </li></ul></ul><ul><ul><li>WebSphere Studio Site Developer </li></ul></ul><ul><ul><li>IBM Agent Controller </li></ul></ul><ul><li>Tools to build and deploy J2EE compliant applications </li></ul>
    13. 13. Site Developer Express Application Server Application server - JSPs - Servlets Web server -HTML -images Web projects Express Test Environment Develop deploy Data Access -DB2 -Oracle -SQL Server -Cloudscape Web Client WebSphere Application Server Express Agent Controller
    14. 14. Perspectives <ul><li>There is a perspective for each of the different roles in a development life cycle (some roles overlap) </li></ul><ul><li>Open different perspectives by </li></ul><ul><ul><li>Perspective>Open>Other </li></ul></ul><ul><ul><li>Selecting Open Perspective Button </li></ul></ul><ul><li>To switch between perspectives use: shortcut bar </li></ul><ul><li>A group of related views and editors is called a perspective </li></ul><ul><li>Configurable </li></ul>
    15. 15. Perspective/Project, What's the difference? Projects - a grouping of resources Perspectives-multiple views of assets in workbench providing tools to help with task <ul><li>Perspectives are different ways of looking at the same project </li></ul>
    16. 16. <ul><li>Perspectives are made up of views </li></ul><ul><li>Display a view by selecting Perspective > Show Views </li></ul><ul><li>Views support: </li></ul><ul><ul><li>Editors </li></ul></ul><ul><ul><li>Provide alternative presentations or navigation of the information </li></ul></ul><ul><li>A view might appear by itself, or stacked with other views in a tabbed notebook </li></ul><ul><li>Views can be floated by Selecting the blue bar at the top of the Tasks view and drag it on to the desktop. </li></ul>Views
    17. 17. Web Application <ul><li>Defined in J2EE and Java servlet specification </li></ul><ul><li>Standardized format which is compatible between multiple vendors </li></ul><ul><li>Contains: </li></ul><ul><ul><li>JavaServer Pages </li></ul></ul><ul><ul><li>Servlets </li></ul></ul><ul><ul><li>Applets </li></ul></ul><ul><ul><li>HTML and XML files </li></ul></ul><ul><ul><li>Meta information to connect elements </li></ul></ul><ul><ul><ul><li>Deployment descriptor </li></ul></ul></ul>
    18. 18. <ul><li>XML-based files describing the environment for modules and its components </li></ul><ul><ul><li>Each module and ear file has a deployment descriptor </li></ul></ul><ul><li>Can be automatically created and verified by WebSphere's deployment tool </li></ul><ul><ul><li>Application Assembly Tool (AAT) </li></ul></ul><ul><li>Can be manually created or edited </li></ul>J2EE: Deployment Descriptor (DD)
    19. 19. Running the Application <ul><li>Need to create an application server </li></ul><ul><li>Site Developer will create one for you </li></ul><ul><ul><li>HTTP Server </li></ul></ul><ul><ul><li>Application Server </li></ul></ul>
    20. 20. Site Developer Express Application Server Application server - JSPs - Servlets Web server -HTML -images Web projects Express Test Environment Develop deploy Data Access -DB2 -Oracle -SQL Server -Cloudscape Web Client WebSphere Application Server Express Agent Controller
    21. 21. Web Pages <ul><li>Static </li></ul><ul><ul><li>Constant information </li></ul></ul><ul><ul><li>Can only be changed by changing the html page </li></ul></ul><ul><li>Dynamic </li></ul><ul><ul><li>Information changes </li></ul></ul><ul><ul><li>Database access </li></ul></ul><ul><ul><li>May be customized for individual end user </li></ul></ul><ul><ul><ul><li>Personalization </li></ul></ul></ul>
    22. 22. Creating an HTML Page
    23. 23. HTML Editor
    24. 24. Framesets header.html main.html menu.html toggle
    25. 25. Frameset source
    26. 26. Setting attributes
    27. 27. Using tables
    28. 28. The completed table
    29. 29. Adding Links
    30. 30. Cascading Style Sheet <ul><ul><li>A file that defines a hierarchical set of style rules that the creator of an HTML or XML file uses in order to control how that page is rendered in a browser or viewer, or how it is printed.  </li></ul></ul><ul><ul><li>A CSS includes a defined order of precedence to address cases when the definitions of any style element in a document conflict.  </li></ul></ul>
    31. 31. Cascading Style Sheets
    32. 32. Set Style Properties
    33. 33. WebArt Designer
    34. 34. Common Database Models <ul><li>Relational </li></ul><ul><ul><li>Stores data in a database consisting of one or more tables of rows and columns </li></ul></ul><ul><li>Object </li></ul><ul><ul><li>Combine the elements of object orientation and object-oriented programming languages with database capabilities </li></ul></ul><ul><ul><li>Support additional data types (complex types) </li></ul></ul>
    35. 35. Relational Model Concepts
    36. 36. SQL <ul><li>Structured Query Language </li></ul><ul><li>Provides a standard language to access relational databases </li></ul><ul><li>Works with most common database systems </li></ul><ul><ul><li>Microsoft Access, IBM DB2, Oracle, Informix, MS SQL Server </li></ul></ul><ul><li>SQL statements can be used to manipulate a database </li></ul><ul><ul><li>Define a database </li></ul></ul><ul><ul><li>Define tables </li></ul></ul><ul><ul><li>Define columns and their characteristics </li></ul></ul><ul><li>SQL can be used to request rows from a database </li></ul><ul><li>SQL can be used to add, update and delete rows </li></ul>
    37. 37. Middleware <ul><li>A layer of software between your application and the database </li></ul><ul><li>Provides a standard interface to any DBMS </li></ul><ul><li>Examples: </li></ul><ul><ul><li>ODBC – Open Database Connectivity </li></ul></ul><ul><ul><ul><li>Microsoft Products like Visual Basic </li></ul></ul></ul><ul><ul><li>JDBC – Java Database Connectivity </li></ul></ul><ul><ul><ul><li>Java </li></ul></ul></ul>
    38. 38. Benefits of Middleware <ul><li>The same object code can be used to access different DMBS products </li></ul><ul><li>The application is independent of the data communications protocol </li></ul><ul><li>Data can be handled in a format convenient to the application </li></ul>
    39. 39. JDBC <ul><li>JDBC provides standard Java interfaces to access databases </li></ul><ul><li>It is based on ODBC and supports a subset of what ODBC supports </li></ul><ul><li>Database definition and manipulation is done using SQL statements </li></ul><ul><li>JDBC is useful because it implements a standard interface </li></ul><ul><li>It can theoretically work for accessing any database </li></ul><ul><li>A JDBC driver provides a database specific connection </li></ul>
    40. 40. Some JDBC Drivers <ul><li>JDBC Driver provides access to a specific database </li></ul><ul><ul><li> </li></ul></ul><ul><ul><ul><li>Driver from IBM for accessing DB/2 across a network </li></ul></ul></ul><ul><ul><li> </li></ul></ul><ul><ul><ul><li>Driver from IBM for accessing DB/2 locally </li></ul></ul></ul><ul><ul><li>sun.jdbc.odbc.JdbcOdbcDriver </li></ul></ul><ul><ul><ul><li>Driver from Sun for accessing databases supported by ODBC </li></ul></ul></ul><ul><ul><ul><li>ie, MS Access </li></ul></ul></ul><ul><ul><li>oracle.jdbc.driver.OracleDriver </li></ul></ul><ul><ul><ul><li>Driver to access Oracle databases </li></ul></ul></ul>