Can not modify Xmx in a container in JBoss Fuse 6.2.0. Error: {... : No operation setJvmOpts found on MBean io.fabric8:type=Fabric","status":400 ...}
Issue
Failed to use "fabric:container-edit-jvm-options" to modify a container's xmx parameter, but Fuse always write back to the original values (overwriting instances.properties)
Further more, using curl command from KCS https://access.redhat.com/solutions/1599643 caused errors as below:
curl -v -H "Content-Type: application/json" -X POST http://xxxxx.yy:8181/jolokia -d '{"operation":"setJvmOpts (java.lang.String,java.lang.String)","mbean":"io.fabric8:type=Fabric","arguments":["sepsa-agl","-Xmx1024m -Xms64m"],"type":"exec"}' --user "adm:******"
Note: Unnecessary use of -X or --request, POST is already inferred.
* Trying 192.168.211.133...
* Connected to xxxx.yy (192.168.211.133) port 8181 (#0)
* Server auth using Basic with user 'most'
> POST /jolokia HTTP/1.1
> Host: xxxx.yy:8181
> Authorization: Basic bW9zdDplaXg5QWhydQ==
> User-Agent: curl/7.45.0
> Accept: */*
> Content-Type: application/json
> Content-Length: 155
>
* upload completely sent off: 155 out of 155 bytes
< HTTP/1.1 200 OK
< Content-Type: text/plain;charset=UTF-8
< Cache-Control: no-cache
< Pragma: no-cache
< Date: Mon, 02 Nov 2015 19:22:15 GMT
< Expires: Mon, 02 Nov 2015 18:22:15 GMT
< Content-Length: 4429
< Server: Jetty(8.1.17.v20150415)
<
{"error_type":"java.lang.IllegalArgumentException","error":"java.lang.IllegalArgumentException : No operation setJvmOpts found on MBean io.fabric8:type=Fabric","status":400,"request":{"operation":"setJvmOpts (java.lang.String,java.lang.String)","mbean":"io.fabric8:type=Fabric","arguments":["sepsa-agl","-Xmx1024m -Xms64m"],"type":"exec"},"stacktrace":"java.lang.IllegalArgumentException: No operation setJvmOpts found on MBean io.fabric8:type=Fabric\n\tat org.jolokia.handler.ExecHandler.extractMBeanParameterInfos(ExecHandler.java:175)\n\tat org.jolokia.handler.ExecHandler.extractOperationTypes(ExecHandler.java:143)\n\tat org.jolokia.handler.ExecHandler.doHandleRequest(ExecHandler.java:84)\n\tat org.jolokia.handler.ExecHandler.doHandleRequest(ExecHandler.java:40)\n\tat org.jolokia.handler.JsonRequestHandler.handleRequest(JsonRequestHandler.java:89)\n\tat org.jolokia.backend.MBeanServerExecutorLocal.handleRequest(MBeanServerExecutorLocal.java:109)\n\tat org.jolokia.backend.MBeanServerHandler.dispatchRequest(MBeanServerHandler.java:102)\n\tat org.jolokia.backend.LocalRequestDispatcher.dispatchRequest(LocalRequestDispatcher.java:98)\n\tat org.jolokia.backend.BackendManager.callRequestDispatcher(BackendManager.java:410)\n\tat org.jolokia.backend.BackendManager.handleRequest(BackendManager.java:158)\n\tat org.jolokia.http.HttpRequestHandler.executeRequest(HttpRequestHandler.java:197)\n\tat org.jolokia.http.HttpRequestHandler.handlePostRequest(HttpRequestHandler.java:137)\n\tat org.jolokia.http.AgentServlet$3.handleRequest(AgentServlet.java:425)\n\tat org.jolokia.http.AgentServlet$2.run(AgentServlet.java:316)\n\tat org.jolokia.http.AgentServlet$2.run(AgentServlet.java:314)\n\tat java.security.AccessController.doPrivileged(Native Method)\n\tat javax.security.auth.Subject.doAs(Subject.java:415)\n\tat org.jolokia.http.AgentServlet.handleSecurely(AgentServlet.java:314)\n\tat org.jolokia.http.AgentServlet.handle(AgentServlet.java:291)\n\tat org.jolokia.http.AgentServlet.doPost(AgentServlet.java:259)\n\tat javax.servlet.http.HttpServlet.service(HttpServlet.java:595)\n\tat javax.servlet.http.HttpServlet.service(HttpServlet.java:668)\n\tat org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:684)\n\tat org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:503)\n\tat org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:69)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)\n\tat org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:533)\n\tat org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)\n\tat org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:240)\n\tat org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:429)\n\tat org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)\n\tat org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:75)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)\n\tat org.eclipse.jetty.server.Server.handle(Server.java:370)\n\tat org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)\n\tat org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:982)\n\tat org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:1043)\n\tat org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:865)\n\tat org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:240)\n\tat org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)\n\tat org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectCha* Connection #0 to host xxxx.yy left intact
nnelEndPoint.java:696)\n\tat org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:53)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)\n\tat java.lang.Thread.run(Thread.java:745)\n"}
Environment
- Red Hat JBoss Fuse
- 6.2.0
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
