EJB BioNet Integration - PowerPoint PPT Presentation

1 / 16
About This Presentation
Title:

EJB BioNet Integration

Description:

Examples: a credit card charging bean, a order-placing bean, or a interest-calculating bean. ... is created has an associated BioNet entity that is responsible ... – PowerPoint PPT presentation

Number of Views:34
Avg rating:3.0/5.0
Slides: 17
Provided by: justinmich5
Category:

less

Transcript and Presenter's Notes

Title: EJB BioNet Integration


1
EJB BioNet Integration
  • Implementing EJB via agent-based BioNet
    architecture

2
EJB 101
  • Based on factory design pattern (separates
    implementation and interface of object).

List objList ListFactory.newList() objList.add(
1, new Integer(1)) int nJustStored
objList.get(1)
User code
public List newList() return (List)(new
ListAsArray())
Factory class
public interface List public void add(int
index, Object toAdd) public Object get(int
index)
Interface
public class ListAsArrray implements List . . .

Implementation
3
EJB 101
  • In addition to the factory design pattern
    facilitating object distribution, EJB also
    specifies several different types of remote
    objects (beans).
  • There are two major categories session beans
    and entity beans.

4
Session Beans
  • Session beans are designed to perform some sort
    of business task.
  • Examples a credit card charging bean, a
    order-placing bean, or a interest-calculating
    bean.
  • Two kinds of session beans stateless and
    stateful session beans.

5
Stateless Session Beans
  • Do not retain state information between method
    calls.
  • Marking a session bean stateless allows EJB
    container manage bean to meet demand for
    effectively.
  • Although user code thinks it has the same bean
    instance, the instance may be shared, serialized,
    or even changed between method calls.

6
Entity Beans
  • Support object persistence. Entity beans do not
    disappear during container startup/shutdowns/crash
    es.
  • Home interface supports finding entity beans by
    some attribute.
  • Can be thought of as a collection of objects that
    never disappear, often implemented with a SQL
    database by the EJB container.

7
EJB Problems
  • Although EJB containers often implement
    load-balancing techniques, EJB has limited
    internet-scope because of the number of network
    hopes needed to do one remote method invocation,
    even to a server farm.
  • In addition, EJB containers usually must be
    extremely robust, scalable, and reliable but,
    this means that objects have to be isolated on
    systems far from user systems.

8
BioNet Offers Solutions
  • Since the container layer can take action
    transparently to the user code, specialized
    BioNet based techniques can be applied
    transparently.
  • Main goal To improve performance of remote
    method calls without sacrificing robustness or
    scalability.

9
Migration Services
  • An EJB object is often called. Since each call
    results in network trips, migrating a frequently
    called object to the callers system provides
    large performance gains.
  • The BioNet architecture provides adaptive
    techniques for deciding when to migrate an
    agent, or in this case, possibly a remote EJB
    object.
  • BioNet also provides facilities for performing
    the object/agent migration.

10
Reproduction Services
  • If more than one network host needs to access a
    given EJB object, possibly the reproduction
    facilities of BioNet can be employed to allow a
    bean to reproduce and move to both systems.
  • Again, the BioNet adaptive ability can help tune
    the EJB object reproduction to correctly scale to
    user demand.

11
Relationship Services
  • However, reproduction of EJB objects is a
    double-edged sword.
  • Provides better performance and results in less
    network bandwidth consumption.
  • Also provides robustness if one EJB object
    container dies, the other reproduced object still
    exists.
  • But, the potential for locking and coherency
    problems now exists.

12
Relationship Services - Locking
  • By having the reproduced EJB objects maintain
    relationships with one another, and by creating a
    lock entity when an EJB object is initially
    reproduced, these problems can be handled.
  • Since lock entity is unique to each EJB object
    instance, and is a BioNet entity itself, locality
    is maintained and optimal locking ability can be
    achieved.
  • Loss of lock entity is easily handled since all
    EJB objects stay in relationship.

13
Relationship Services Robust
  • By having co-reproduced EJB objects all stay in
    relationship with one another, a minimum
    population for a given EJB object instance can be
    maintained.
  • Minimum population will reside on different
    systems, meaning that a system failure will not
    result in loss of data.

14
Migration Services - Robust
  • Migration services also provide robustness
    because entity beans no longer reside on a single
    group of close systems.
  • Rather, data is distributed across large numbers
    of systems, and over time, will migrate to the
    most optimal distribution for the average network
    load.

15
High-level Implementation
  • Every BioNet platform can serve as a EJB
    container.
  • Every EJB object that is created has an
    associated BioNet entity that is responsible for
    the EJB object.
  • The EJB object stub probably will communicate
    with this BioNet entity to allow the entity make
    decisions.
  • The BioNet entity will most likely communicate
    with the EJB object skeleton to allow the EJB
    object to migrate, etc.

16
Summary
  • BioNet and EJB have very similar goals.
  • BioNet concepts easily apply to an implementation
    of EJB container middleware.
  • Goal implemented a distributed object technology
    effectively using an distributed entity-based
    solution.
Write a Comment
User Comments (0)
About PowerShow.com