Fall 2008 1 CIS 764 Database Systems Engineering L7. EJB’s.

Slides:



Advertisements
Similar presentations
12 Copyright © 2005, Oracle. All rights reserved. Implementing Business Tasks with Session EJBs.
Advertisements

1 Copyright © 2005, Oracle. All rights reserved. Introduction.
An architecture for webb applications, J2EE
Fall CIS 764 Database Systems Engineering L13: Status: grading, assignments, tutorials, presentations projects.
Internet Technologies 1 Master of Information System Management Java Server Faces Model/View/Controller Design Pattern for Web Development Slides.
EJB Design. Server-side components Perform –complex algorithms –high volume transactions Run in –highly available environment (365 days/year) –fault tolerant.
Outline IS400: Development of Business Applications on the Internet Fall 2004 Instructor: Dr. Boris Jukic Server Side Web Technologies: Part 2.
Java 2 – Enterprise Edition Kevin J. LaFata April 21, 2003 UM – St. Louis.
1 Build a Web Application on J2EE. 2 J2EE Scenario Client – Web Server – EIS Resources Client – Web Server – EIS Resources Client – Application Server.
J2EE Java2 Enterprise Edition by Damian Borth. Contents Introduction Architectures styles Components Scenarios Roles Processing a HTTP request.
1 CS 483 Enterprise and Web Application Programming Week 6 Session Beans JSP Tutorial.
Java Server Faces Model/View/Controller Design Pattern for Web Development Slides adapted from “Core JavaServer Faces” by Geary and Horstmann and the J2EE.
1 Java Server Pages Can web pages be created specially for each user? What part does Java play?
Emmanuel Cecchet et al.  Performance Scalability of J2EE application servers.  Test effect of: ◦ Application Implementation Methods ◦ Container Design.
Sys Prog & Scripting - HW Univ1 Systems Programming & Scripting Lecture 15: PHP Introduction.
Chapter 10 EJB Concepts of EJB Three Components in Creating an EJB Starting/Stopping J2EE Server and Deployment Tool Installation and Configuration of.
Fall CIS 764 Database Systems Engineering L3: Two Assignments Relating to J2EE.
CSCI 6962: Server-side Design and Programming Course Introduction and Overview.
J2EE Part 2: Enterprise JavaBeans CSCI 4300 Images and code samples from jGuru EJB tutorial,
Ing. Ignacio Roqueta ARTech GeneXus and J2EE.
Enterprise JavaBeans EJB Container Services. EJB container Enterprise JavaBeans are deployed in an EJB container within the application server EJB container.
Session Beans Overview EJB container Remote Invocation Represent client's access to app Local / Remote speed / flexibility trade-off when to choose local.
Jonathan Westlake, ed: Nic Shulver JSP, Structure and JavaBeans JSP models Assignment context “Register as a member of the site/show member details/update.
CS 493/693: Distributed Systems Programming V. “Juggy” Jagannathan CSEE, West Virginia University March 21, 2005.
Fall CIS 764 Database Systems Engineering L3: Status Reverse Engineering Assignment JDeveloper Assignment.
Entity Java Beans Jorg Janke Open Source ERP & CRM.
Enterprise JavaBeans Umer Farooq CS6704: Design Patterns & Component FrameworksFebruary 25, 2002.
1 Stateful Session Beans Stateless Session Beans Michael Brockway Sajjad Shami Northumbria University School of Computing, Engineering & Information Sciences.
Enterprise Java Bean Matt. 2 J2EE 3 J2EE Overview.
COMP 321 Week 7. Overview HTML and HTTP Basics Dynamic Web Content ServletsMVC Tomcat in Eclipse Demonstration Lab 7-1 Introduction.
J2EE Structure & Definitions Catie Welsh CSE 432
A TUTORIAL TO USING EJBs by SHREERAM IYER 09/17/2001.
Fall CIS 764 Database Systems Design L8. Web ….
Source: Peter Eeles, Kelli Houston, and Wojtek Kozaczynsky, Building J2EE Applicationa with the Rational Unified Process, Addison Wesley, 2003 Prepared.
Fall CIS 764 Database Systems Engineering L13: Status: grading, assignments, tutorials, presentations projects
Fall CIS 764 Database Systems Engineering L1: Introduction to … CIS 764 Enterprise Database Systems Engineering: Software.
1 Architectural Overview For application developers, assembling enterprise beans requires little or no expertise in the complex system-level issues that.
1 MSCS 237 Overview of web technologies (A specific type of distributed systems)
Fall CIS 764 Database Systems Engineering L7. ADF + EJB Context: Oracle Application Development Framework …but … only EJB.
Enterprise Java Beans. Model 1 J2EE – Web View Model/View/Controller Model View Control Data base Web Server Model One Architecture HTTP Request HTTP.
Introduction to Enterprise JavaBeans Topics In Systems Architecture Barry Herbold
Fall CIS 764 Database Systems Engineering L18.2 : Object Relational Mapping … ….Object persistence.
Assignment of JAVA id : BSSE-F10-M-10-JAVA1 Overview of J2EE/Session 2/Slide 1 of 38.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
Fall CIS 764 Database Systems Engineering L15: Deployment Deploy … to place or arrange for deliberate (intended) purpose.
Enterprise JavaBeans Session Beans. Session beans are a type of Enterprise JavaBean component designed to implement business logic responsible for managing.
Session Beans Based on: Patel, Brose, Silverman, Mastering Enterprise JavaBeans 3.0.
Introduction to EJB. What is an EJB ?  An enterprise java bean is a server-side component that encapsulates the business logic of an application. By.
Java Programming: Advanced Topics 1 Enterprise JavaBeans Chapter 14.
Enterprise JavaBeans: Fundamentals. EJB Fundamentals(c)CDAC(Formerly NCST)2 Contents Introduction Technology Overview EJB Architecture EJB Specification.
Java Programming: Advanced Topics 1 Building Web Applications Chapter 13.
EJB Enterprise Java Beans JAVA Enterprise Edition
27.1 Chapter 27 WWW and HTTP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
1 Chapter 22 World Wide Web (HTTP) Chapter 22 World Wide Web (HTTP) Mi-Jung Choi Dept. of Computer Science and Engineering
14 Copyright © 2004, Oracle. All rights reserved. Achieving State Management in the Business Tier.
17 Copyright © 2004, Oracle. All rights reserved. Integrating J2EE Components.
Computing with C# and the .NET Framework
Structure of a web application
Java Servlets By: Tejashri Udavant..
EJB (Enterprise Java Beans)
Scope and State Handling in JSPs
Web Software Model CS 4640 Programming Languages for Web Applications
PHP / MySQL Introduction
Distributed System Using Java 2 Enterprise Edition (J2EE)
CIS 764 Database Systems Engineering
CIS 764 Database Systems Engineering
Component-based Applications
Component Technology Bina Ramamurthy 2/25/2019 B.Ramamurthy.
Understanding and Designing with EJB
Enterprise Java Beans.
Presentation transcript:

Fall CIS 764 Database Systems Engineering L7. EJB’s

Fall CIS 764 Database Systems Engineering

Fall CIS 764 Database Systems Engineering … V. Bush, concept of hypertext 1961 … Kleinrock paper on packet switching 1966 … Roberts, plan for ARPA net 1967 … hypertext system, Brown Univ 1969 …. ARPA net, 4 nodes 1972 … … Cerf, Kahn … TCP paper 1981 … APRA net down, status virus 1982 … CS net 1986 … NSF net 1987 … 10 K nodes 1987 … Apple Hypercard 1988 … CERT 1989 … 100K nodes 1991 … WWW … CGI scripts (each request is separate process, non-OO)

Fall CIS 764 Database Systems Engineering … WWW … CGI scripts 1992 … 1M nodes 1995 … Java 1998 … Google … servlets … JDeveloper 1999 … J2EE, servlets, EJB 1 (RMI remote objects) JSP 1 (embedded code) 2000 … 20 M web sites 2001 … JDev separate from Borland 2003 … SQL Slammer worm … EJB 2 (adds QL ) … JSP 2 (tags ) 2005 … YouTube … Java annotations 2006 … Google buys YouTube … EJB 3 ( annotated POJO’s)

Fall CIS 764 Database Systems Engineering EJB specification details how an application server provides:application server Persistence Transaction processing Concurrency control Events using Java Message ServiceEventsJava Message Service Java Naming and directory services (JNDI)directory servicesJNDI Security ( Java Cryptography Extension (JCE) and JAAS )SecurityJava Cryptography Extension (JCE)JAAS Deployment of software components in an application serverDeploymentsoftware components Remote procedure calls using RMI-IIOP.Remote procedure callsRMI-IIOP Exposing business methods as Web Services.Web Services defines the roles played by the EJB container vs the EJBs From

Fall CIS 764 Database Systems Engineering … old EJB 1, 2

Fall CIS 764 Database Systems Engineering

Fall CIS 764 Database Systems Engineering EJB3 POJO + Annotations => EJB EJB 3.0 Resources Introduction: or Java World: (has more code examples)

Fall CIS 764 Database Systems Engineering Entity bean … bound to entity data, with unique key value; can contain multiple subitems.  where is the concept of a result set ? Session bean …  “session beans generally represent actions …” << bad OO ! “process entity” vs “data entity” Stateless … do not have internal state (  ) … rather: do not keep track of the callers state ! Stateful …..maintains the conversation state across multiple method invocations (e.g. a shopping cart) Beans have an associated deployment descriptor Beans have own QL … “OO version of sql “

Fall CIS 764 Database Systems Engineering EJB annotations

Fall CIS 764 Database Systems Engineering

Fall CIS 764 Database Systems Engineering import public class CalculateEJBBean implements CalculateEJB { int value = 0; public String incrementValue() { value++; return "value incremented by 1"; } }

Fall CIS 764 Database Systems Engineering import javax.persistence.*; import java.util.ArrayList; = "EMPLOYEES") public class Employee implements java.io.Serializable { private int empId; private String eName; private primaryKey=true) /* getters and setters here … see next slide }

Fall CIS 764 Database Systems Engineering public int getEmpId( ) { return empId; } public void setEmpId(int empId) { this.empId = empId; } public String getEname( ) { return eName; } public void setEname(String eName) { this.eName = eName; } public double getSal( ) { return sal; } public void setSal(double sal) { this.sal = sal; } public String toString() { StringBuffer buf = new StringBuffer(); buf.append("Class:").append(this.getClass(). getName()).append(" :: ").append(" empId:").append(getEmpId()). append(" ename:").append(getEname()).append("sal:").append(getSal()); return buf.toString(); } ??? Why the toString method <<<<<<<<<<<<<<<< ??? Why ArrayList and Collection

Fall CIS 764 Database Systems Engineering import javax.naming.Context; import javax.naming.InitialContext; public class CalculateejbClient { public static void main(String [] args) { Context context = new InitialContext(); CalculateEJB myejb = (CalculateEJB)context.lookup("java:comp/env/ejb/CalculateEJB"); myejb.incrementValue(); } } ??? Where does this “client” run ??

Fall CIS 764 Database Systems Engineering An OQL Resources ool_precision.doc/pr35se/xF html ool_precision.doc/pr35se/xF html

Fall CIS 764 Database Systems Engineering Homework: Oracle “EJB3 Simple Tutorial” 30.htm 30.htm Do an “in essence” version for the PO DB. (e.g. … not the DB in the tutorial, do not need to implements all of the operations) Note: This is not a web app. The client has remote access to the bean. The client does just text output. Post snapshots in JDev, running the client, link to code

Fall CIS 764 Database Systems Engineering Note: Begin planning for future requirements: Group project: requirements, design, implementation, doc’s (weekly during 2ed half of semester) Contribute some tutorial content … ** “how to” ( more Oracle tutorials or dotNet, Ruby, Eclipse, etc.) ( expend previous tutorials or add new ones ) Submit some technical paper …. ** concepts … not “how to” ( pages, w references, related to 764 topics ) Class presentation or either tutorial or paper: ** both require prior approval of topics.

Fall CIS 764 Database Systems Engineering end.