Uploaded image for project: 'Application Server 7'
  1. Application Server 7
  2. AS7-4069

Custom bootstrap-context element, added to JCA subsystem by CLI or DMR API disappears after server reload

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 7.1.1.Final
    • 7.1.0.Final
    • JCA
    • None
    • Hide

      At the beginning we have standart jca configuration from standalone.xml

      <subsystem xmlns="urn:jboss:domain:jca:1.1">
      <archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/>
      <bean-validation enabled="false"/>
      <default-workmanager>
      <short-running-threads>
      <core-threads count="50"/>
      <queue-length count="50"/>
      <max-threads count="50"/>
      <keepalive-time time="10" unit="seconds"/>
      </short-running-threads>
      <long-running-threads>
      <core-threads count="50"/>
      <queue-length count="50"/>
      <max-threads count="50"/>
      <keepalive-time time="10" unit="seconds"/>
      </long-running-threads>
      </default-workmanager>
      <cached-connection-manager/>
      </subsystem>

      After server start with this configuration we have:

      [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true)
      {
      "outcome" => "success",
      "result" => {
      "archive-validation" => {"archive-validation" => {
      "enabled" => true,
      "fail-on-error" => true,
      "fail-on-warn" => false
      }},
      "bean-validation" => {"bean-validation" => {"enabled" => false}},
      "bootstrap-context" => {"default" => {
      "name" => "default",
      "workmanager" => "default"
      }},
      "cached-connection-manager" => {"cached-connection-manager" => {
      "debug" => false,
      "error" => false,
      "install" => true
      }},
      "workmanager" => {"default" => {
      "name" => "default",
      "long-running-threads" => {"default-long-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" =>

      { "time" => 10L, "unit" => "SECONDS" },
      "max-threads" => 50,
      "name" => "default-long-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }},
      "short-running-threads" => {"default-short-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }

      ,
      "max-threads" => 50,
      "name" => "default-short-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }}
      }}
      }
      }

      Adding work manager and custom bootstrap context:

      [standalone@localhost:9999 /] /subsystem=jca/workmanager=n:add(name=n)
      {
      "outcome" => "success",
      "response-headers" =>

      { "operation-requires-reload" => true, "process-state" => "reload-required" }
      }
      [standalone@localhost:9999 /] /subsystem=jca/workmanager=n/short-running-threads=n:add(max-threads=10,queue-length=20,core-threads=25)
      {
      "outcome" => "success",
      "response-headers" => {"process-state" => "reload-required"}
      }
      [standalone@localhost:9999 /] /subsystem=jca/bootstrap-context=n:add(name=n,workmanager=n)
      {
      "outcome" => "success",
      "response-headers" => { "operation-requires-reload" => true, "process-state" => "reload-required" }

      }
      [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true)
      {
      "outcome" => "success",
      "result" => {
      "archive-validation" => {"archive-validation" => {
      "enabled" => true,
      "fail-on-error" => true,
      "fail-on-warn" => false
      }},
      "bean-validation" => {"bean-validation" => {"enabled" => false}},
      "bootstrap-context" => {
      "default" =>

      { "name" => "default", "workmanager" => "default" }

      ,
      "n" =>

      { "name" => "n", "workmanager" => "n" }

      },
      "cached-connection-manager" => {"cached-connection-manager" => {
      "debug" => false,
      "error" => false,
      "install" => true
      }},
      "workmanager" => {
      "default" => {
      "name" => "default",
      "long-running-threads" => {"default-long-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" =>

      { "time" => 10L, "unit" => "SECONDS" },
      "max-threads" => 50,
      "name" => "default-long-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }},
      "short-running-threads" => {"default-short-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }

      ,
      "max-threads" => 50,
      "name" => "default-short-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }}
      },
      "n" => {
      "long-running-threads" => undefined,
      "name" => "n",
      "short-running-threads" => {"n-short-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 25,
      "keepalive-time" => undefined,
      "max-threads" => 10,
      "name" => "n-short-running-threads",
      "queue-length" => 20,
      "thread-factory" => undefined
      }}
      }
      }
      },
      "response-headers" =>

      {"process-state" => "reload-required"}
      }

      As we see, added bootstrap context is presented in model. Then:

      [standalone@localhost:9999 /] :reload
      {
      "outcome" => "success",
      "response-headers" => {"process-state" => "reload-required"}

      }
      [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true)
      {
      "outcome" => "success",
      "result" => {
      "archive-validation" => {"archive-validation" => {
      "enabled" => true,
      "fail-on-error" => true,
      "fail-on-warn" => false
      }},
      "bean-validation" => {"bean-validation" => {"enabled" => false}},
      "bootstrap-context" => {"default" => {
      "name" => "default",
      "workmanager" => "default"
      }},
      "cached-connection-manager" => {"cached-connection-manager" => {
      "debug" => false,
      "error" => false,
      "install" => true
      }},
      "workmanager" => {
      "default" => {
      "name" => "default",
      "long-running-threads" => {"default-long-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" =>

      { "time" => 10L, "unit" => "SECONDS" },
      "max-threads" => 50,
      "name" => "default-long-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }},
      "short-running-threads" => {"default-short-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 50,
      "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }

      ,
      "max-threads" => 50,
      "name" => "default-short-running-threads",
      "queue-length" => 50,
      "thread-factory" => undefined
      }}
      },
      "n" => {
      "long-running-threads" => undefined,
      "name" => "n",
      "short-running-threads" => {"n-short-running-threads" => {
      "allow-core-timeout" => false,
      "core-threads" => 25,
      "keepalive-time" => undefined,
      "max-threads" => 10,
      "name" => "n-short-running-threads",
      "queue-length" => 20,
      "thread-factory" => undefined
      }}
      }
      }
      }
      }

      Bootstrap context diappeared. So we can't see it in standalone.xml too:

      <subsystem xmlns="urn:jboss:domain:jca:1.1">
      <archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/>
      <bean-validation enabled="false"/>
      <default-workmanager>
      <short-running-threads>
      <core-threads count="50"/>
      <queue-length count="50"/>
      <max-threads count="50"/>
      <keepalive-time time="10" unit="seconds"/>
      </short-running-threads>
      <long-running-threads>
      <core-threads count="50"/>
      <queue-length count="50"/>
      <max-threads count="50"/>
      <keepalive-time time="10" unit="seconds"/>
      </long-running-threads>
      </default-workmanager>
      <workmanager name="n">
      <short-running-threads>
      <core-threads count="25"/>
      <queue-length count="20"/>
      <max-threads count="10"/>
      </short-running-threads>
      </workmanager>
      <cached-connection-manager/>
      </subsystem>

      Show
      At the beginning we have standart jca configuration from standalone.xml <subsystem xmlns="urn:jboss:domain:jca:1.1"> <archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/> <bean-validation enabled="false"/> <default-workmanager> <short-running-threads> <core-threads count="50"/> <queue-length count="50"/> <max-threads count="50"/> <keepalive-time time="10" unit="seconds"/> </short-running-threads> <long-running-threads> <core-threads count="50"/> <queue-length count="50"/> <max-threads count="50"/> <keepalive-time time="10" unit="seconds"/> </long-running-threads> </default-workmanager> <cached-connection-manager/> </subsystem> After server start with this configuration we have: [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true) { "outcome" => "success", "result" => { "archive-validation" => {"archive-validation" => { "enabled" => true, "fail-on-error" => true, "fail-on-warn" => false }}, "bean-validation" => {"bean-validation" => {"enabled" => false}}, "bootstrap-context" => {"default" => { "name" => "default", "workmanager" => "default" }}, "cached-connection-manager" => {"cached-connection-manager" => { "debug" => false, "error" => false, "install" => true }}, "workmanager" => {"default" => { "name" => "default", "long-running-threads" => {"default-long-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }, "max-threads" => 50, "name" => "default-long-running-threads", "queue-length" => 50, "thread-factory" => undefined }}, "short-running-threads" => {"default-short-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" } , "max-threads" => 50, "name" => "default-short-running-threads", "queue-length" => 50, "thread-factory" => undefined }} }} } } Adding work manager and custom bootstrap context: [standalone@localhost:9999 /] /subsystem=jca/workmanager=n:add(name=n) { "outcome" => "success", "response-headers" => { "operation-requires-reload" => true, "process-state" => "reload-required" } } [standalone@localhost:9999 /] /subsystem=jca/workmanager=n/short-running-threads=n:add(max-threads=10,queue-length=20,core-threads=25) { "outcome" => "success", "response-headers" => {"process-state" => "reload-required"} } [standalone@localhost:9999 /] /subsystem=jca/bootstrap-context=n:add(name=n,workmanager=n) { "outcome" => "success", "response-headers" => { "operation-requires-reload" => true, "process-state" => "reload-required" } } [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true) { "outcome" => "success", "result" => { "archive-validation" => {"archive-validation" => { "enabled" => true, "fail-on-error" => true, "fail-on-warn" => false }}, "bean-validation" => {"bean-validation" => {"enabled" => false}}, "bootstrap-context" => { "default" => { "name" => "default", "workmanager" => "default" } , "n" => { "name" => "n", "workmanager" => "n" } }, "cached-connection-manager" => {"cached-connection-manager" => { "debug" => false, "error" => false, "install" => true }}, "workmanager" => { "default" => { "name" => "default", "long-running-threads" => {"default-long-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }, "max-threads" => 50, "name" => "default-long-running-threads", "queue-length" => 50, "thread-factory" => undefined }}, "short-running-threads" => {"default-short-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" } , "max-threads" => 50, "name" => "default-short-running-threads", "queue-length" => 50, "thread-factory" => undefined }} }, "n" => { "long-running-threads" => undefined, "name" => "n", "short-running-threads" => {"n-short-running-threads" => { "allow-core-timeout" => false, "core-threads" => 25, "keepalive-time" => undefined, "max-threads" => 10, "name" => "n-short-running-threads", "queue-length" => 20, "thread-factory" => undefined }} } } }, "response-headers" => {"process-state" => "reload-required"} } As we see, added bootstrap context is presented in model. Then: [standalone@localhost:9999 /] :reload { "outcome" => "success", "response-headers" => {"process-state" => "reload-required"} } [standalone@localhost:9999 /] /subsystem=jca:read-resource(recursive=true) { "outcome" => "success", "result" => { "archive-validation" => {"archive-validation" => { "enabled" => true, "fail-on-error" => true, "fail-on-warn" => false }}, "bean-validation" => {"bean-validation" => {"enabled" => false}}, "bootstrap-context" => {"default" => { "name" => "default", "workmanager" => "default" }}, "cached-connection-manager" => {"cached-connection-manager" => { "debug" => false, "error" => false, "install" => true }}, "workmanager" => { "default" => { "name" => "default", "long-running-threads" => {"default-long-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" }, "max-threads" => 50, "name" => "default-long-running-threads", "queue-length" => 50, "thread-factory" => undefined }}, "short-running-threads" => {"default-short-running-threads" => { "allow-core-timeout" => false, "core-threads" => 50, "keepalive-time" => { "time" => 10L, "unit" => "SECONDS" } , "max-threads" => 50, "name" => "default-short-running-threads", "queue-length" => 50, "thread-factory" => undefined }} }, "n" => { "long-running-threads" => undefined, "name" => "n", "short-running-threads" => {"n-short-running-threads" => { "allow-core-timeout" => false, "core-threads" => 25, "keepalive-time" => undefined, "max-threads" => 10, "name" => "n-short-running-threads", "queue-length" => 20, "thread-factory" => undefined }} } } } } Bootstrap context diappeared. So we can't see it in standalone.xml too: <subsystem xmlns="urn:jboss:domain:jca:1.1"> <archive-validation enabled="true" fail-on-error="true" fail-on-warn="false"/> <bean-validation enabled="false"/> <default-workmanager> <short-running-threads> <core-threads count="50"/> <queue-length count="50"/> <max-threads count="50"/> <keepalive-time time="10" unit="seconds"/> </short-running-threads> <long-running-threads> <core-threads count="50"/> <queue-length count="50"/> <max-threads count="50"/> <keepalive-time time="10" unit="seconds"/> </long-running-threads> </default-workmanager> <workmanager name="n"> <short-running-threads> <core-threads count="25"/> <queue-length count="20"/> <max-threads count="10"/> </short-running-threads> </workmanager> <cached-connection-manager/> </subsystem>

    Description

      See steps to reproduce.

      Attachments

        Activity

          People

            smaestri@redhat.com Stefano Maestri
            vrastsel_jira Vladimir Rastseluev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: