# Framework/multiprocessing support for opensearch-py?

**URL:** <https://forum.opensearch.org/t/framework-multiprocessing-support-for-opensearch-py/9249>\
**Category:** OpenSearch Client Libraries\
**Tags:** opensearch-py\
**Created:** [April 14, 2022, 7:14pm UTC](https://forum.opensearch.org/t/framework-multiprocessing-support-for-opensearch-py/9249 "2022-04-14T19:14:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![atransm](https://avatars.discourse-cdn.com/v4/letter/a/3bc359/32.png) [@atransm](https://forum.opensearch.org/u/atransm)\
**Post date:** [April 14, 2022, 7:14pm UTC](https://forum.opensearch.org/t/framework-multiprocessing-support-for-opensearch-py/9249/1 "2022-04-14T19:14:32Z")

</div>

I am using Python3 and the Pyramid framework behind Green Unicorn. What is the recommended way of using the OpenSearch client?

For example, should I instantiate a new one before each call to OpenSearch? Or, can it handle fork/threading (not sure which Pyramid uses exactly) such that I can just make a single global instances of OpenSearch?

Thank you for any help!

---

<div class="post-metadata">

**Author:** ![kris](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/kris/32/2208_2.png) [@kris](https://forum.opensearch.org/u/kris)\
**Post date:** [February 7, 2023, 6:37pm UTC](https://forum.opensearch.org/t/framework-multiprocessing-support-for-opensearch-py/9249/2 "2023-02-07T18:37:00Z")

</div>


