entity java beans l.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Entity Java Beans PowerPoint Presentation
Download Presentation
Entity Java Beans

Loading in 2 Seconds...

play fullscreen
1 / 45

Entity Java Beans - PowerPoint PPT Presentation


  • 194 Views
  • Uploaded on

Entity Java Beans. Jorg Janke http://www.compiere.org Open Source ERP & CRM. Objectives. Know J2EE & EJB Buzzwords Understanding of J2EE Architecture Understanding of EJB Architecture Know next steps to explore J2EE & EJB. Java Application Tiers. Java Application Tiers (Detail). J2SE.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Entity Java Beans' - jacob


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
entity java beans

Entity Java Beans

Jorg Janke

http://www.compiere.org

Open Source ERP & CRM

objectives
Objectives
  • Know J2EE & EJB Buzzwords
  • Understanding of J2EE Architecture
  • Understanding of EJB Architecture
  • Know next steps to explore J2EE & EJB
ejb types
EJB Types
  • Session Beans
    • Stateless
    • Stateful
  • Entity Bean
    • Bean Managed Persistency
    • Container Managed Persistency (CMP)
  • Message Bean
ejb source code
EJB Source Code
  • Home Interface (extends EJBHome)
    • Create - Find (for Entity)
    • Factory Pattern
  • Remote Interface (EJBObject)
    • “Business Methods”
    • Proxy Pattern
  • Bean Class (EntityBean/SessionBean)
  • Deployment descriptor (ejb-jar.xml)
ejb runtime
EJB Runtime
  • Home (“create”, “find”)
    • Home Object Stub
    • Home Object
  • EJB (“business methods”)
    • EJB Object Stub
    • EJB Object
  • Bean (“the entity”)
    • Enterprise Bean Object
ejb container client
EJB Container - Client

JNDI

Client

Container

Home Object

Home Stub

Home Stub

RMI-IIOP

Enterprise

Bean Object

EJB Object

Object Stub

Object Stub

ejb use
EJB Use
  • Context ctx = new InitialContext();
    • JNDI to LDAP or other Directory Service
  • BeanHome home = ctx.lookup(“myBean");
    • Container finds/creates Factory
  • BeanRemote bean = home.create();
    • Container creates EJB Object -> myBean
  • Bean.doSomething();
    • Business Method “Proxy”
getting started
Getting started
  • The hard way
    • Download, Install & Implement the J2EE Reference Implementation (Cloudscape)
  • The easy way
    • Select a IDE
      • J2EE support often in “Enterprise Edition”
      • Free: Forte / NetBeans
now you have your ide
Now you have your IDE …
  • Check what Containers are supported (or included)
  • Download & Install the Container
    • E.g. JBoss includes Tomcat
  • IDEs provide
    • Wizards / Templates
    • Packaging & Deployment
how do ejbs fit in
How do EJBs “fit in”
  • Application Server
  • Business Objects
  • Coarse Grained Objects
  • Fine Grained Objects (not suited)
    • Local Interface
what is j2ee compliant
Server providing

Web Services

Servlet, JSP

JNDI, RMI, JDBC

EJB Services

EJB with CMP

JMS, JTA, JAAS

Compliance Test

Version 1.2, 1.3, …

License

Application using

One of the technologies

Servlet or RMI & JDBC will do

What is J2EE compliant
when to use ejbs
When to use EJBs
  • You need a EJB project for your CV
  • Highly shared, long lived objects
    • Entity Beans
  • Container Managed Persistency (CMP)
    • Data Access Object
  • Receiving Messages (JMS)
  • (Simple) Transaction Support (outside JDBC)
  • Security Support
compiere j2ee
Compiere & J2EE
  • Compiere does not use EJBs
  • EJB Container (candidate: JBoss)
    • Additional Installation effort
    • Additional Operation effort
    • Plus: Could be installed automatically
  • Compiere’s Business Objects (Invoice,..) dynamically are generated
    • Based on Data Dictionary
    • Business Objects & Behavior are “personalized”
intro resources
Intro Resources
  • http://java.sun.com/j2ee/
    • Deployathon
    • http://java.sun.com/blueprints
  • http://java.sun.com/j2ee/tutorial
  • J2EE “community” sites
    • http://www.theserverside.com
    • http://www.middleware-company.com/
    • http://www.onjava.com (O’Reilly)
thanks
Thanks
  • You can download the presentation
    • http://www.compiere.org/download
  • My contact:
    • http://www.compiere.com/consulting.html
    • jorg.janke@compiere.org