<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    敬的世界

    常用鏈接

    統(tǒng)計

    最新評論

    關(guān)于 EJB

    Overview

    EJB consists of a remote interface, a home interface and an EJBimplementation.??

    The remote interface declares business methods that clients of the EJB?may invoke. The remote interface must extend interface javax.ejb.EJBObject. The EJB container generates a class that implements the remote interface.

    The home interface?provides create?methods for creating new EJB instances.?finder methods for finding EJB instance and remove methods fro removing EJB instances.?

    The EJB?container?provides the EJB's runtime environment and life-cycle management.?

    What EJB?Container does ?

    ?The EJB container manages an EJB's client interfactons, method invocations transactions security, exceptions, etc. Clients of an EJB do nnot interact directly with the EJB,Clients access the EJB container to obtain remote references to EJB instances.

    The EJB container also manages the life cycles of its EJBs. EJB containers typically perform pooling of EJB instances to enhance performance. The EJB container also can create new EJB instances and remove existing instances.

    The Methods calls :

    When? a client invokes a create method in the home interface, the EJB container invokes method ejbCreate. The EJB implementation must provide an ejbCreate
    method for each create method declared in the home interface.? The ejbCreate method must have the same number and types of auguments as their corresponding create methods.

    The EJB container invokes method ejbRemove in response to an invocation of method remove in the home interface. The EJB container also may invoke method ejbRemove if the session expires due to lengthy inactivity. Method ejbRemove should free resources the EJB has used.

    The EJB container invokes method ejbPassivate when the container determines that the EJB is no longer needed in memory. The algorithm that the EJB container uses to determine when it should passivate an EJB is application -server dependent . Many application servers enforce a least recently used policy, which? passivated EJBs that clients have not accessed recently.

    When the EJB container passivates an EJB, the container serializes the state of the EJB and removes the EJB from memory.?

    The EJB container invokes method ejbActivate to restore an EJB instance that the container passivated previousy. The EJB container activates an EJB instance if the client assoicated with the EJB instance invokes a business method of that EJB instance.

    The EJB container reads the state information that it saved during passivation and restores the EJB instance in memory.

    EJB Transaction

    The Java 2 Enterprise Edition supports distributed transaction. A distributed transaction is a transaction that includes multiple databases or multiple application servers.? For example , a distributed transaction could transfer funds from an account at one bank into an account at another bank atomically.

    Container Managed Transaction Type

    NotSupported?? Method does not support transactions . The EJB container suspends the existing transaction context if the method is invoked within a transaction context.

    Required????????? Method requires a transaction. The EJB container creates a new transaction if the method is invoked without an existing transaction context and commits the transaction at the end of the method

    Supports?????????? Method supports transactions. The EJB container will not create a new transaction if the methods is invoked without an existing transaction context. but will execute the method as part of an existing transaction context if one is available.

    RequiresNew???Method requires a new transaction. The EJB container suspends the existing transaction context and starts a new transaction if the method is invoked as part of another transaction.

    Mandatory?????? The method must execute in an existing transaction context. The EJB container throws a TransactionRequiredException if the method is invoked without a valid transaction context.

    Never????????????? ?The method must not execute in a transaction context. The EJB container throws a RemoteException if the method is invoked inside a transaction context.

    posted on 2008-10-07 23:09 picture talk 閱讀(133) 評論(0)  編輯  收藏


    只有注冊用戶登錄后才能發(fā)表評論。


    網(wǎng)站導(dǎo)航:
     
    主站蜘蛛池模板: 99久久成人国产精品免费| 亚洲永久中文字幕在线| 国产乱色精品成人免费视频| 日韩精品免费一区二区三区| 亚洲国产精品自在拍在线播放| 亚洲伊人成无码综合网| 久久精品国产亚洲AV高清热| 亚洲制服丝袜一区二区三区| 国产精品亚洲精品爽爽| 精品多毛少妇人妻AV免费久久| 一级毛片在线免费观看| 无码人妻精品一二三区免费| 亚洲人成影院在线观看| 一级黄色免费大片| 国产精品入口麻豆免费观看| 成年女人永久免费观看片| 最新亚洲人成网站在线观看| 99精品视频免费观看| www国产亚洲精品久久久| 亚洲欧洲自拍拍偷午夜色| 一个人免费观看视频www| 亚洲精品无码Av人在线观看国产| 在线亚洲午夜片AV大片| 亚洲国产系列一区二区三区| 最新69国产成人精品免费视频动漫 | 久久亚洲精品成人无码| 一级毛片**不卡免费播| 亚洲色偷偷偷网站色偷一区| 波霸在线精品视频免费观看| 超pen个人视频国产免费观看| 国产成人亚洲综合无| 国产偷v国产偷v亚洲高清| 国产91免费在线观看| 美女被免费网站视频在线| 国产免费AV片在线播放唯爱网| 亚洲精品国产摄像头| 黄在线观看www免费看| 国产亚洲日韩在线a不卡| 亚洲av永久无码精品秋霞电影影院| 欧洲精品码一区二区三区免费看| 午夜免费福利在线|