Uploaded image for project: 'XNIO'
  1. XNIO
  2. XNIO-328

Thread allocation hash can result in only allocating to 50% of IO threads

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      There was a recent change to linux where it will favour allocating even port numbers:

      https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=07f4c90062f8fc7c8c26f8f95324cbe8fa3145a5

      For some scenarios (e.g. load balancer, local client) the report port is the only part of the hash algorithm that changes, which means that if the rest of the hash resolves to an even number then the final result of the hash will always be even. If the number of IO threads is also even then only even threads will be assigned.

      This needs to be revisited. I think we could even possibly replace this with a round robin type assignment now that we have a single accept thread (as contention is not an issue).

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                swd847 Stuart Douglas
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated: