# Temporal with synchronous python services

**URL:** https://community.temporal.io/t/temporal-with-synchronous-python-services/11981
**Category:** Community Support
**Tags:** python-sdk
**Created:** [May 2, 2024, 7:35pm UTC](https://community.temporal.io/t/temporal-with-synchronous-python-services/11981 "2024-05-02T19:35:08Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![e5\_me](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/e5_me/32/5083_2.png) [@e5\_me](https://community.temporal.io/u/e5_me)
#### Post date: [May 2, 2024, 7:35pm UTC](https://community.temporal.io/t/temporal-with-synchronous-python-services/11981/1 "2024-05-02T19:35:08Z")

</div>

Currently our stack is based of python micro-services, which do not use async-io. We would like to use temporal for some of our workloads, but are facing an issue when the activities call our existing microservices. We deploy the worker inside a GRPC server (python service). But when an async activity makes an I/O bound call, in this case a grpc call to another service, this becomes a blocking call and other activities are blocked. Our understanding is that in Python, the I/O bound calls will relinquish the thread, but we do not see this behavior when a temporal activity makes a I/O bound call. This means in a worker, only 1 activity can run at the same time which defeats the purpose of using Temporal. Could we get some guidance on how we can solve this specifically with Python services setup which do not use asyncio?

---

<div class="post-metadata">

### Author: ![Chad\_Retz](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/chad_retz/32/1396_2.png) [@Chad\_Retz](https://community.temporal.io/u/Chad_Retz)
#### Post date: [May 2, 2024, 7:40pm UTC](https://community.temporal.io/t/temporal-with-synchronous-python-services/11981/2 "2024-05-02T19:40:32Z")

</div>

> [@e5\_me](#):
>
> But when an async activity makes an I/O bound call

You should not use `async def` activities, you should just use normal `def` activities which are in their own thread and can block normally. You’ll need to provide a `ThreadPoolExecutor` to the activity. See [this doc](https://docs.temporal.io/dev-guide/python/foundations#develop-activities), [this doc](https://docs.temporal.io/encyclopedia/python-sdk-sync-vs-async), and [this sample](https://github.com/temporalio/samples-python/blob/main/hello/hello_activity_threaded.py).
