Use the set-web-context-param subcommand in remote mode to change the configuration of a deployed application without the need to modify the application's deployment descriptors and repackage and redeploy the application. By using this subcommand, you are either adding a new parameter that did not appear in the original web module's descriptor, or overriding the descriptor's setting of the parameter.
If the --ignoreDescriptorItem option is set to true, then the server ignores any setting for that context parameter in the descriptor, which means you do not need to specify an overriding value on the set-web-context-param subcommand. The server behaves as if the descriptor had never contained a setting for that context parameter.
This subcommand sets a servlet context-initialization parameter of one of the following items:
A deployed web application
A web module in a deployed Java Platform, Enterprise Edition (Java EE) application
The application must already be deployed. Otherwise, an error occurs.
Ensure that the server is running.
Remote commands require a running server.
Set a servlet context-initialization parameter by using the set-web-context-param(1) subcommand.
Information about the options for the subcommand is included in this help page.
This example sets the servlet context-initialization parameter javax.faces.STATE_SAVING_METHOD of the web application basic-ezcomp to client.
asadmin> set-web-context-param --name=javax.faces.STATE_SAVING_METHOD --description="The location where the application?s state is preserved" --value=client basic-ezcomp Command set-web-context-param executed successfully. |
You can also view the full syntax and options of the subcommand by typing asadmin help set-web-context-param at the command line.