Using the AquaLogic Service Bus Console

     Previous  Next    Open TOC in new window    View as PDF - New Window  Get Adobe Reader - New Window
Content starts here

JARs

A JAR (Java ARchive) is a zipped file that contains a set of Java classes. It is used to store compiled Java classes and associated metadata that can constitute a program. A JAR acts like a callable program library for Java code elements (so that a single compilation link provides access to multiple elements, rather than requiring bindings for each element individually). To learn more about JARs, see http://java.sun.com/docs/books/tutorial/deployment/jar/

JAR resources in ALSB are used in:

Locating JARs

  1. Do either of the following:
  2. To restrict the number of items in the list or locate a specific JAR, search for a JAR using name and path filters. In the Name and Path fields, enter the name and path of the search target(s), then click Search.
  3. The path is the project name and the name of the folder in which the JAR resides.

    This search supports wildcard characters. For example, you can enter “j*” in the Name field to get a list of JARs that start with “j”.

    Click View All to remove the search filters and display all JARs.

    Table 7-1 JAR Details
    Property
    Description
    JAR Name
    The unique name assigned to the JAR. The name is a link to the View a JAR Resource - JAR Configuration page. See Editing JARs.
    Path
    The path is the project name and the name of the folder in which the JAR resides. It is a link to the project or folder that contains this resource. See Qualifying Resource Names Using Projects and Folders.
    No. of Classes
    The number of classes the JAR contains.
    Size
    The size of the JAR in bytes.
    Options
    Click the Delete icon to delete a specific JAR. See Deleting JARs.

Adding JARs

  1. If you have not already done so, click Create to create a new session or click Edit to enter an existing session. See Using the Change Center.
  2. Select Project Explorer, then select a project or folder in which to add the JAR. The Project/Folder View page is displayed.
  3. From the Create Resource drop-down list, select JAR from under Utility to display the Create a New JAR Resource page.
  4. In the Resource Name field, enter a unique name for this JAR. This is a required field.
  5. In the Resource Description field, enter a description for the JAR.
  6. In the JAR Source File field, do one of the following:
    • Enter the path to the location of the JAR.
    • Click Browse to locate and import an existing JAR.
    • This is a required field.

  7. Click Save. The JAR resource is created and saved in the current session.
  8. If the JAR loads without problems, the contents of the JAR will be available for viewing. To learn how to view JAR details, see Editing JARs.

  9. To end the session and deploy the configuration to the run time, click Activate under Change Center.

Editing JARs

Use the View a JAR Resource - Configuration page to update JAR files. Updating a JAR file essentially involves pointing the resource to a new version of the JAR, as you cannot edit a JAR using ALSB.

  1. If you have not already done so, click Create to create a new session, or click Edit to enter an existing session. See Using the Change Center.
  2. Locate the JAR, as described in Locating JARs.
  3. Click the JAR name. The View a JAR Resource - JAR Configuration page displays the information shown in Table 7-2.
  4. Table 7-2 JAR Information 
    Property
    Description
    Last Modified By
    The user who imported this JAR into the configuration.
    Last Modified On
    The date and time that the user imported this JAR into the configuration. Click the date and time link to view the change history of this resource. See View Change History page.
    References
    The number of JARs that this JAR references. If such references exist, click the numeric link to view a list of the JARs. See Viewing References to Resources.
    Referenced by
    The number of objects that reference this JAR. If such references exist, click the numeric link to view a list of the objects. See Viewing References to Resources.
    Description
    A description of this JAR, if one exists.

    The JAR configuration is displayed by default, which includes the information shown in Table 7-3.

    Table 7-3 JAR Configuration Details
    Property
    Description
    JAR Configuration
    The list of classes and interfaces in this JAR.
    Click (+) beside the name of a Java class to display a list of methods included in the class.

  5. To make a change to the fields, click Update.
  6. The only field you can edit is Description. You cannot edit a JAR in ALSB. To update the JAR, you must select a new JAR to use. To learn how, see Adding JARs.

  7. Click Save to commit the updates in the current session.
  8. To end the session and deploy the configuration to the run time, click Activate under Change Center.
Note: If you change the JAR used by an EJB Business Service (point the JAR resource to a new version of the JAR), you need to redeploy the EJB. You will then have to edit any EJB service that uses this JAR, and reselect the JAR resource, save, and activate. That will repackage the EJB business service to use the new JAR.
Note: Java callout actions and Tuxedo-based services, however, will automatically pick up the new JAR.

Editing JAR Dependencies

In ALSB, JAR resources can contain classes that depend on other classes in different JARs. Use the Edit JAR Dependencies page to add or remove referenced JAR resources.

  1. If you have not already done so, click Create to create a new session, or click Edit to enter an existing session. See Using the Change Center.
  2. Locate the JAR, as described in Locating JARs.
  3. Click the JAR name.
  4. On the View a JAR Resource - JAR Configuration page, a numeric indicator on the Dependencies tab displays the number of referenced JARs configured for this JAR resource, or a zero if there are none.

  5. Select the Dependencies tab to display referenced JARs or to add them.
  6. The JAR dependencies page includes the information shown in Table 7-4.

    Table 7-4 JAR Dependencies Information 
    Property
    Description
    Name
    The name of the referenced JAR. The name is a link to the View a JAR Resource - JAR Configuration page. See Editing JARs.
    Path
    The path is the project name and the name of the folder in which the JAR resides.

  7. To add or remove referenced JARs, click Edit.
  8. The Edit JAR dependencies page includes the information shown in Table 7-5.

    Table 7-5 JAR Dependencies Details
    Property
    Description
    Manifest Class Path
    Class-Path entries in the JAR manifest file.
    Name
    The name and path of the referenced JAR resource.
    Options
    • Use the Up and Down arrows to change the referenced JARs order of precedence.
    • Click the Delete icon to remove a referenced JAR.

  9. Click Add JARS.
  10. In the JARs Browser, locate or select referenced JAR resources and click Submit.
  11. For example, if you are editing JAR A and adding JARs B and C, JAR A references (depends on) JAR B and JAR A references (depends on) JAR C.

    Use the arrows in the Options column to reorder the hierarchy of referenced JARs or the Delete icon to remove them.

  12. Click Save to commit the updates in the current session.
  13. To end the session and deploy the configuration to the run time, click Activate under Change Center.

Deleting JARs

  1. If you have not already done so, click Create to create a new session or click Edit to enter an existing session. See Using the Change Center.
  2. Select Resource Browser > JARs.
  3. Click the Delete icon in the Options field of the JAR you want to delete. The JAR is deleted in the current session. A Deletion Warning icon is displayed when other resources reference this resource. You can delete the resource with a warning confirmation. This might result in conflicts due to unresolved references to the deleted resource.
  4. To end the session and deploy the configuration to the run time, click Activate under Change Center.

  Back to Top       Previous  Next