Programmer's Rules

Glassfish

How to list jndi entries for a context of an application in Glassfish

The way to lookup services by names in Glassfish

GlassfishwebejbJava

1. Go to Glassfish bin folder, e.g. run cmd console and write:

2. Write the following:

where:
- asadmin is the Glassfish administrator task command
- --port 4848 is optional for giving the domain's port
- list-jndi-entries - allows to lookup services by names
- --context - points to the running enviroments of applications
- java:global/webApp - the global context of the application
- webApp - is the application name
If the context is not specified, all entries in the naming service are returned.

3. The result will be the list of ejb beans.
Tutorial statistics