Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No core value reported for scaling thread pool type #29113

Closed
lukas-vlcek opened this issue Mar 16, 2018 · 6 comments · Fixed by #29123
Closed

No core value reported for scaling thread pool type #29113

lukas-vlcek opened this issue Mar 16, 2018 · 6 comments · Fixed by #29123
Labels
:Core/Infra/Core Core issues without another label

Comments

@lukas-vlcek
Copy link
Contributor

Elasticsearch version (bin/elasticsearch --version): >= 5.x

Description of the problem including expected versus actual behavior:

This is probably documentation related issue. There are a few places where the documentation mentions that the scaling thread pool uses the core value for the minimum value. For example:

However, in the output I see only min value where the core should be expected:

// http://10.8.245.12:9200/_nodes/_local/thread_pool

{
  "_nodes": {
    "total": 1,
    "successful": 1,
    "failed": 0
  },
  "cluster_name": "xxxxxxxx",
  "nodes": {
    "DK0UQ_fFTZ6fz0H2v9XsKw": {
      "name": "xxxxxxxx-1",
      "transport_address": "172.16.220.11:9300",
      "host": "172.16.220.11",
      "ip": "172.16.220.11",
      "version": "5.5.2",
      "build_hash": "b2f0c09",
      "roles": [
        "master",
        "data",
        "ingest"
      ],
      "thread_pool": {
        "force_merge": {
          "type": "fixed",
          "min": 1,
          "max": 1,
          "queue_size": -1
        },
        "fetch_shard_started": {
          "type": "scaling",
          "min": 1,
          "max": 8,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "listener": {
          "type": "fixed",
          "min": 2,
          "max": 2,
          "queue_size": -1
        },
        "index": {
          "type": "fixed",
          "min": 4,
          "max": 4,
          "queue_size": 200
        },
        "refresh": {
          "type": "scaling",
          "min": 1,
          "max": 2,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "generic": {
          "type": "scaling",
          "min": 4,
          "max": 128,
          "keep_alive": "30s",
          "queue_size": -1
        },
        "warmer": {
          "type": "scaling",
          "min": 1,
          "max": 2,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "search": {
          "type": "fixed",
          "min": 7,
          "max": 7,
          "queue_size": 1000
        },
        "flush": {
          "type": "scaling",
          "min": 1,
          "max": 2,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "fetch_shard_store": {
          "type": "scaling",
          "min": 1,
          "max": 8,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "management": {
          "type": "scaling",
          "min": 1,
          "max": 5,
          "keep_alive": "5m",
          "queue_size": -1
        },
        "get": {
          "type": "fixed",
          "min": 4,
          "max": 4,
          "queue_size": 1000
        },
        "bulk": {
          "type": "fixed",
          "min": 4,
          "max": 4,
          "queue_size": 200
        },
        "snapshot": {
          "type": "scaling",
          "min": 1,
          "max": 2,
          "keep_alive": "5m",
          "queue_size": -1
}}}}}
@jasontedor
Copy link
Member

We report the same thread pool info for all thread pools. That is, all thread pools, regardless of type, report a min and max (as well as their name and type, and keep_alive and queue_size when applicable) . For a scaling thread pool it is min == core and max == size. For a fixed thread pool it is min == size and max == size.

@lukas-vlcek
Copy link
Contributor Author

So the thing is that in settings part you say core but what you get back from the API is min. It is confusing but I think I get it now.

@jasontedor
Copy link
Member

Yeah, I am sorry for the confusion, it is something that has bothered be that we use this single thread pool info class to represent the underlying information regardless of the thread pool type. I looked into it once before and walked away because I did not see a clean way to refactor this.

@jasontedor
Copy link
Member

On second thought, I think we can change this on the display side only without having to endure a wider refactoring.

@jasontedor jasontedor added the :Core/Infra/Core Core issues without another label label Mar 17, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

@jasontedor
Copy link
Member

I opened #29123. Now we get:

{

  "_nodes" : {
    "total" : 1,
    "successful" : 1,
    "failed" : 0
  },
  "cluster_name" : "elasticsearch",
  "nodes" : {
    "TQM_SNpDSsaYROQly2-KgQ" : {
      "name" : "TQM_SNp",
      "transport_address" : "127.0.0.1:9300",
      "host" : "127.0.0.1",
      "ip" : "127.0.0.1",
      "version" : "7.0.0-alpha1",
      "build_hash" : "2f21dc7",
      "roles" : [
        "master",
        "data",
        "ingest"
      ],
      "thread_pool" : {
        "force_merge" : {
          "type" : "fixed",
          "size" : 1,
          "queue_size" : -1
        },
        "fetch_shard_started" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 16,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "listener" : {
          "type" : "fixed",
          "size" : 4,
          "queue_size" : -1
        },
        "index" : {
          "type" : "fixed",
          "size" : 8,
          "queue_size" : 200
        },
        "refresh" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 4,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "generic" : {
          "type" : "scaling",
          "core" : 4,
          "max" : 128,
          "keep_alive" : "30s",
          "queue_size" : -1
        },
        "warmer" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 4,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "search" : {
          "type" : "fixed_auto_queue_size",
          "size" : 13,
          "queue_size" : 1000
        },
        "flush" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 4,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "fetch_shard_store" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 16,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "management" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 5,
          "keep_alive" : "5m",
          "queue_size" : -1
        },
        "get" : {
          "type" : "fixed",
          "size" : 8,
          "queue_size" : 1000
        },
        "bulk" : {
          "type" : "fixed",
          "size" : 8,
          "queue_size" : 200
        },
        "snapshot" : {
          "type" : "scaling",
          "core" : 1,
          "max" : 4,
          "keep_alive" : "5m",
          "queue_size" : -1
        }
      }
    }
  }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Core Core issues without another label
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants