Code Monkey home page Code Monkey logo

Comments (2)

BrianNichols avatar BrianNichols commented on July 21, 2024 1

The thread pool is not designed to automatically detect load and adjust thread pool size accordingly. That would be a much more complex implementation.

Synchronous batch/scan/query are the only commands that use this thread pool. These commands subdivide into subcommands for each server node so they can be run in parallel. The thread pool is used to run these subcommands.

The thread pool size is configured per each aerospike client instance. Different client processes can have different thread pool sizes at instance creation.

It's important for the user to size the pool according to how many concurrent batch/scan/query commands need to run concurrently on that instance. If the cluster size is 8 and at least 4 batch/scan/queries need to run in parallel, then the thread pool size should be 32 (8 * 4).

The thread pool implementation is shared with server. as_thread_pool_resize() is only called by the server when batch thread size is modified by the user via an info command on a running server.

from aerospike-client-c.

thomas-activevideo avatar thomas-activevideo commented on July 21, 2024

Thanks for the answer. It is clearer.

We circumvented the hanging issue by defining a different thread pool size per aerospike client instance. A small thread pool size (1 thread) for the first context mentioned and a larger size (default value so 16 threads) for solving the hanging issue in the second context.

from aerospike-client-c.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.