This low-level client is a very lightweight wrapper for Elasticsearch's REST APIs to obtain maximum flexibility. Each client is equipped with a separate connection pool to support persistent connections. By default, 10 connections are allowed to open each node. The maxsize parameter is used to set the maximum degree of parallelism. The Python Elasticsearch client is thread-safe. The best practice is to create a singleton to use throughout the application. However, for multiprocessing, a new client should be created after the fork is called.
The Python low-level Elasticsearch client
Workflow for the Python low-level Elasticsearch client
To illustrate the programming, we'll target only the workflow, not the details...