WAS v8.5 > Develop applications > Develop EJB applications > Assemble access intents to EJB 2.x entity beans

Applying access intent policies to methods

You apply an access intent policy to a method, or set of methods, in an application's entity beans through the assembly tool. Note: Method-level access intent is deprecated in v6.0.

  1. Start an assembly tool.

  2. Optional: Open the Java EE perspective to work with Java EE projects. Click Window > Open Perspective > Other > Java EE.

  3. Optional: Open the Project Explorer view. Click Window > Show View > Project Explorer. Another helpful view is the Navigator view (Window > Show View > Navigator).

  4. Create a new application EAR file or edit an existing one.

    For example, to change attributes of an existing application, use the import wizard to import an EAR file. To start the import wizard:

    1. Select File > Import > EAR file > Next

    2. Select the EAR file.

    3. Create a WebSphere Application Server v6.0 type of Server Runtime. Select New to open the New Server Runtime Wizard and follow the instructions.
    4. In the Target server field, select WAS v6.0 type of Server Runtime.

    5. Select Finish

  5. In the Project Explorer view of the J2EE perspective, right-click the Deployment Descriptor: EJB Module Name under the EJB module for the bean instance, then select Open With > Deployment Descriptor Editor. A property dialog notebook for the EJB project is displayed in the property pane.

  6. Select the Access tab.

  7. On the right side of the Access Intent for Entities 2.x (Method Level) panel, select Add. The Add Access Intent panel displays.

  8. Specify the Name for the new intent policy.

  9. Select the Access intent name from the drop-down list.

  10. Enter a Description to help remember what this policy does.

  11. Optional: Select Read Ahead Hint. A single access intent read ahead hint might not refer to the same bean type in more than one relationship. For example, if a Department enterprise bean has a relationship employees with the Employee enterprise bean, and also has a relationship manager with the Employee enterprise bean, then a read ahead hint cannot specify both employees and manager.

  12. Click Next. The next Add Access Intent panel displays, with optional attributes.

  13. Optional: Decide whether or not to overwrite these optional access intent attributes. Click on those to change.

  14. Click Next. The next Add Access Intent panel, with a list of Enterprise Beans, displays.

  15. Select one or more Enterprise Beans from the list.

    If we selected Read Ahead Hint in an earlier step, we can only select ONE bean at this step.

  16. Click Next. The next Add Access Intent panel, with a list of methods, displays.

  17. Select the methods to use.

  18. If we DID NOT select Read Ahead Hint in an earlier step, click Finish. If we DID select the Read Ahead Hint option, we can click Next to specify your Read Ahead Hint for the specified bean. The next Add Access Intent panel, with a list of EJB preload paths, displays.
  19. Edit the EJB preload path by selecting relationship roles from the Relationship roles: window.

  20. Click Finish. A new entry is created in the Access Intent for Entities 2.x (Method Level) panel


Related concepts:

Access intent policies for EJB 2.x entity beans


Related


Use access intent policies for EJB 2.x entity beans
Assemble applications


Reference:

Access intent assembly settings
Access intent -- isolation levels and update locks


+

Search Tips   |   Advanced Search