Oracle GlassFish Server 3.0.1 Application Development Guide


To create a custom resource that provides instances of a JavaBean class, follow these steps:

  1. Set the custom resource's factory class to org.glassfish.resources.custom.factory.JavaBeanFactory.

  2. Create a property in the custom resource for each setter method in the JavaBean class.

    For example, if the JavaBean class has a method named setAccount, specify a property named account and give it a value.

  3. Make sure the JavaBean class is accessible to the GlassFish Server.

    For example, you can place the JavaBean class in the as-install/lib directory.