Oracle GlassFish Server 3.1 Section 1: asadmin Utility Subcommands
create-connector-connection-pool(1)
create-connector-security-map(1)
create-connector-work-security-map(1)
create-jdbc-connection-pool(1)
create-message-security-provider(1)
create-resource-adapter-config(1)
delete-connector-connection-pool(1)
delete-connector-security-map(1)
delete-connector-work-security-map(1)
delete-jdbc-connection-pool(1)
delete-message-security-provider(1)
delete-resource-adapter-config(1)
disable-http-lb-application(1)
disable-secure-admin-internal-user(1)
disable-secure-admin-principal(1)
enable-secure-admin-internal-user(1)
enable-secure-admin-principal(1)
list-connector-connection-pools(1)
list-connector-security-maps(1)
list-connector-work-security-maps(1)
list-message-security-providers(1)
list-resource-adapter-configs(1)
list-secure-admin-internal-users(1)
list-secure-admin-principals(1)
list-supported-cipher-suites(1)
unfreeze-transaction-service(1)
update-admin-server-coordinates(1)
update-admin-server-local-coordinates(1)
update-connector-security-map(1)
update-connector-work-security-map(1)
Oracle GlassFish Server 3.1 Section 1M: Utility Commands
Oracle GlassFish Server 3.1 Section 5ASC: GlassFish Server Concepts
- creates a JavaMail session resource
create-javamail-resource [--help] [--target target] --mailhost hostname --mailuser username --fromaddress address [--storeprotocol storeprotocol] [--storeprotocolclass storeprotocolclass] [--transprotocol transprotocol] [--transprotocolclass transprotocolclass] [--debug={false|true}] [--enabled={true|false}] [--description resource-description] [--property (name=value)[:name=value]*] jndi-name
The create-javamail-resource subcommand creates a JavaMail session resource.
This subcommand is supported in remote mode only.
Displays the help text for the subcommand.
This option specifies the target for which you are creating the JavaMail session resource. Valid values are:
Creates the resource for the default server instance. This is the default value.
Creates the resource for the domain.
Creates the resource for every server instance in the cluster.
Creates the resource for a particular server instance.
The DNS name of the default mail server. The connect methods of the Store and Transport objects use this value if a protocol-specific host property is not supplied. The name must be resolvable to an actual host name.
The name of the mail account user provided when connecting to a mail server. The connect methods of the Store and Transport objects use this value if a protocol-specific username property is not supplied.
The email address of the default user, in the form username@host.domain.
The mail server store protocol. The default is imap. Change this value only if you have reconfigured the GlassFish Server's mail provider to use a non-default store protocol.
The mail server store protocol class name. The default is com.sun.mail.imap.IMAPStore. Change this value only if you have reconfigured the GlassFish Server's mail provider to use a nondefault store protocol.
The mail server transport protocol. The default is smtp. Change this value only if you have reconfigured the GlassFish Server's mail provider to use a nondefault transport protocol.
The mail server transport protocol class name. The default is com.sun.mail.smtp.SMTPTransport. Change this value only if you have reconfigured the GlassFish Server's mail provider to use a nondefault transport protocol.
If set to true, the server starts up in debug mode for this resource. If the JavaMail log level is set to FINE or FINER, the debugging output will be generated and will be included in the server log file. The default value is false.
If set to true, the resource is enabled at runtime. The default value is true.
Text providing some details of the JavaMail resource.
Optional attribute name/value pairs for configuring the JavaMail resource. The GlassFish Server-specific mail- prefix is converted to the standard mail prefix. The JavaMail API documentation lists the properties you might want to set.
The JNDI name of the JavaMail resource to be created. It is a recommended practice to use the naming subcontext prefix mail/ for JavaMail resources.
Example 1 Creating a JavaMail Resource
This example creates a JavaMail resource named mail/MyMailSession. The JNDI name for a JavaMail session resource customarily includes the mail/ naming subcontext.
asadmin> create-javamail-resource --mailhost localhost --mailuser sample --fromaddress sample@sun.com mail/MyMailSession Command create-javamail-resource executed successfully.
subcommand executed successfully
error in executing the subcommand