[jboss-jira] [JBoss JIRA] (AS7-2445) CLI does not allow you to define all of the available JVM attributes

Alexey Loubyansky (Resolved) (JIRA) jira-events at lists.jboss.org
Mon Nov 7 09:56:45 EST 2011


     [ https://issues.jboss.org/browse/AS7-2445?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexey Loubyansky resolved AS7-2445.
------------------------------------

    Fix Version/s:     (was: 7.1.0.CR1)
       Resolution: Rejected


I spoke too soon that it's a bug. It's not. Check the operation description. This is how the relevant parameters are described:
            "heap-size" => {
                "type" => OBJECT,
                "description" => "The Heap size settings allocated by the JVM.",
                "attributes" => {
                    "size" => STRING,
                    "max-size" => STRING
                },
                "required" => false
            },
            "permgen-size" => {
                "type" => OBJECT,
                "description" => "The JVM PermGen settings.",
                "attributes" => {
                    "size" => STRING,
                    "max-size" => STRING
                },
                "required" => false
            }

So, they are complex types. Here is how you should have done it:

[domain at localhost:9999 /] /host=master/jvm=small_jvm:add(heap-size=64m,max-heap-size=128m)
'max-heap-size' is not found among the supported properties: [type, agent-lib, agent-path, env-classpath-ignored, environment-variables, java-agent, java-home, jvm-options, stack-size, heap-size, permgen-size]
[domain at localhost:9999 /] /host=master/jvm=small_jvm:add(heap-size=>{"size"=>"64m","max-size"=>"128m"})
{
    "outcome" => "success",
    "result" => {
        "domain-results" => {"step-1" => undefined},
        "server-operations" => undefined
    }
}

Now, maybe you find it over complicated to provide the arguments this way. If so, then feel free to re-open and get comments from the author(s) of this stuff.
                
> CLI does not allow you to define all of the available JVM attributes
> --------------------------------------------------------------------
>
>                 Key: AS7-2445
>                 URL: https://issues.jboss.org/browse/AS7-2445
>             Project: Application Server 7
>          Issue Type: Bug
>          Components: Domain Management
>            Reporter: Rich Raposa
>            Assignee: Alexey Loubyansky
>
> In attempting to define a new JVM for a host, the following command should work:
> [domain at localhost:9999 /] /host=master/jvm=small_jvm:add(heap-size=64m,max-heap-size=128m)
> 'max-heap-size' is not found among the supported properties
> max-heap-size is a valid attribute. Notice that max-permgen-size is also a valid attribute but is not allowed in the :add operation. Not being able to define these attributes seems to contradict the output of a :read-resource, which looks like:
> [domain at localhost:9999 /] /host=master/jvm=default:read-resource(recursive=true)
> {
>     "outcome" => "success",
>     "result" => {
>         "agent-lib" => undefined,
>         "agent-path" => undefined,
>         "env-classpath-ignored" => undefined,
>         "environment-variables" => undefined,
>         "heap-size" => "64m",
>         "java-agent" => undefined,
>         "java-home" => undefined,
>         "jvm-options" => undefined,
>         "max-heap-size" => "128m",
>         "max-permgen-size" => undefined,
>         "permgen-size" => undefined,
>         "stack-size" => undefined,
>         "type" => undefined
>     }
> }

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list