Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-8516

Documentation in the XSD for the queue-length is incorrect based on the model description

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 11.0.0.Beta1
    • None
    • EE

    Description

      The documentation for in the XSD for the queue-length on the managed-executor-service states:

      A managed executor service (implementing javax.enterprise.concurrent.ManagedExecutorService).
      If the "thread-factory" attribute is not defined a managed thread factory with no context service and normal thread priority will be created and used by the executor.
      The task queue is based on the values of "core-threads" and "queue-length":

      • If "queue-length" is 0, or "queue-length" is Integer.MAX_VALUE (2147483647) and "core-threads" is 0, direct handoff queuing strategy will be used and a SynchronousQueue will be created.
      • If "queue-length" is Integer.MAX_VALUE but "core-threads" is not 0, an unbounded queue will be used.
      • For any other valid value for "queue-length", a bounded queue wil be created.

      The model description states:

      The executors task queue capacity. A length of 0 means direct hand-off and possible rejection will occur. An undefined length (the default), or Integer.MAX_VALUE, indicates that an unbounded queue should be used. All other values specify an exact queue size. If an unbounded queue or direct hand-off is used, a core-threads value greater than zero is required.

      The two descriptions should match. The model validation should also be checked as one of the messages doesn't seem to be correct:

      // Validate an unbounded queue
      if (!queueLength.isDefined() || queueLength.asInt() == Integer.MAX_VALUE) {
          if (coreThreads.isDefined() && coreThreads.asInt() <= 0) {
              throw EeLogger.ROOT_LOGGER.invalidCoreThreadsSize(coreThreads.asString());
          }
      
      }
      

      That message doesn't really describe the real problem and will always be

      WFLYEE0112: The core-threads value must be greater than 0 when the queue-length is 0

      Attachments

        Issue Links

          Activity

            People

              jperkins-rhn James Perkins
              jperkins-rhn James Perkins
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: