# Synchronized activity /queue

**URL:** <https://community.temporal.io/t/synchronized-activity-queue/9342>\
**Category:** Community Support\
**Created:** [August 30, 2023, 5:04pm UTC](https://community.temporal.io/t/synchronized-activity-queue/9342 "2023-08-30T17:04:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![madhu](https://avatars.discourse-cdn.com/v4/letter/m/a8b319/32.png) [@madhu](https://community.temporal.io/u/madhu)\
**Post date:** [August 30, 2023, 5:04pm UTC](https://community.temporal.io/t/synchronized-activity-queue/9342/1 "2023-08-30T17:04:09Z")

</div>

Is there a way i can create an activity which is synchronized in nature?  
i.e. multiple workflows could call an activiely but only one of them will execute it at a give time…

Or is there a way i can create a special taks queue which ensures that only one task is processed at a time. ?

My use case is 1000s of workflow does many things, there are few critical part , which only one workflow should get access to at a time… is there a way I can achieve this using some kind of special activity/activity option or queue?

---

<div class="post-metadata">

**Author:** ![madhu](https://avatars.discourse-cdn.com/v4/letter/m/a8b319/32.png) [@madhu](https://community.temporal.io/u/madhu)\
**Post date:** [August 30, 2023, 5:14pm UTC](https://community.temporal.io/t/synchronized-activity-queue/9342/2 "2023-08-30T17:14:06Z")

</div>

my requirement may be very similar to [Implementing a Rate Limiter Service for Workflow Activities](https://community.temporal.io/t/implementing-a-rate-limiter-service-for-workflow-activities/8584)

But i dont really want the workflow to be aware of the rate limiter etc…  
i want to leverage temporal activity/queue defination which lets only set number of concurrent tasks across the cluster…

---

<div class="post-metadata">

**Author:** ![taonic](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/taonic/32/5556_2.png) [@taonic](https://community.temporal.io/u/taonic)\
**Post date:** [September 4, 2023, 8:29am UTC](https://community.temporal.io/t/synchronized-activity-queue/9342/3 "2023-09-04T08:29:21Z")

</div>

You have a couple of options:

1. Create a dedicated task queue for that activity and have a single worker to consume it. Also set the worker’s `MaxConcurrentActivityExecutionSize` to 1. Obviously, this is not great for HA.

2. Use a distributed lock, e.g. [Distributed Locks with Redis | Redis](https://redis.io/docs/manual/patterns/distributed-locks/)
