# Cross DC architecture

**URL:** <https://community.temporal.io/t/cross-dc-architecture/1133>\
**Category:** Community Support\
**Tags:** elasticsearch, xdc\
**Created:** [December 7, 2020, 9:03am UTC](https://community.temporal.io/t/cross-dc-architecture/1133 "2020-12-07T09:03:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![wandrewchan](https://avatars.discourse-cdn.com/v4/letter/w/a587f6/32.png) [@wandrewchan](https://community.temporal.io/u/wandrewchan)\
**Post date:** [December 7, 2020, 9:03am UTC](https://community.temporal.io/t/cross-dc-architecture/1133/1 "2020-12-07T09:03:11Z")

</div>

Hi all, we would like to have a cross dc function for temporal service, so that we would like to know the relationship between Kafka and Elasticsearch, how these two can help with cross dc replication? Thanks.

---

<div class="post-metadata">

**Author:** ![Wenquan\_Xing](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/wenquan_xing/32/362_2.png) [@Wenquan\_Xing](https://community.temporal.io/u/Wenquan_Xing)\
**Post date:** [December 7, 2020, 6:30pm UTC](https://community.temporal.io/t/cross-dc-architecture/1133/3 "2020-12-07T18:30:55Z")

</div>

Current implementation (v1.3.2):

1. XDC is using Kafka for replication log distribution, e.g. source cluster sends replication log to Kafka, target cluster polls from Kafka for replication logs.  
NOTE: We are in the progress of removing Kafka for XDC reducing number of dependencies.

2. Advanced visibility (backed by ES) is using Kafka for records buffer and batch processing.  
NOTE: We are in the progress of removing Kafka for Advanced visibility reducing number of dependencies.

---

<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:** [December 8, 2020, 2:46pm UTC](https://community.temporal.io/t/cross-dc-architecture/1133/4 "2020-12-08T14:46:28Z")

</div>

few more threads on this

> [@Cross data center replication setup](https://community.temporal.io/t/cross-data-center-replication-setup/475/3):
>
> Ok i had similar questions, and i am trying to consolidate bits and pieces of info lying else where to get this thread moving ( and possibly this can serve as unofficial document) Disclaimer : i have not attempted to set this up yet/ or tried these out smileysmiley At high level cross dc/xdc architecture look something like [this post](https://community.temporal.io/t/temporal-with-aurora-db/357/5) So In my opinion one need to a) setup two independent temporal clusters using existing [helms](https://github.com/temporalio/helm-charts#default-installation-batteries-included) b)Enable global namespace in cluster metadata section c) co…

> [@Global domain registration in java sdk](https://community.temporal.io/t/global-domain-registration-in-java-sdk/282):
>
> I am using temporal 27 ,when i try to register a global domain, its failing unable to register domain Version temporal 27 Request sent : RegisterNamespaceRequest request = RegisterNamespaceRequest.newBuilder().setName(ns) .setEmitMetric(true) .setHistoryArchivalState(ArchivalState.ARCHIVAL\_STATE\_ENABLED) .setIsGlobalNamespace(true) .setOwnerEmail(“[me@myself.me](mailto:me@myself.me)”) .setWorkflowExecutionRetentionPeriodDays(5).build(); int retryCount = 0; // in while loop i attempt registration with th…

> [@Temporal with Aurora db](https://community.temporal.io/t/temporal-with-aurora-db/357/5):
>
> This area has always been confusing, are you saying with XDC settings, each cluster can have its own database and temporal will replicate all info from the primary namespace/domain to secondary automatically?

---

<div class="post-metadata">

**Author:** ![nanzhong](https://avatars.discourse-cdn.com/v4/letter/n/e9a140/32.png) [@nanzhong](https://community.temporal.io/u/nanzhong)\
**Post date:** [December 18, 2020, 3:30pm UTC](https://community.temporal.io/t/cross-dc-architecture/1133/5 "2020-12-18T15:30:32Z")

</div>

I noticed that in the docs there is a reference to an `rpc` replication consumer type. Is this the path forward to remove the dependency on kafka? If so is this feature already working and just not documented completely yet, or is it still a work in progress?

---

<div class="post-metadata">

**Author:** ![Wenquan\_Xing](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/wenquan_xing/32/362_2.png) [@Wenquan\_Xing](https://community.temporal.io/u/Wenquan_Xing)\
**Post date:** [December 18, 2020, 10:35pm UTC](https://community.temporal.io/t/cross-dc-architecture/1133/6 "2020-12-18T22:35:54Z")

</div>

> [@nanzhong](#):
>
> I noticed that in the docs there is a reference to an `rpc` replication consumer type. Is this the path forward to remove the dependency on kafka

yes.

> [@nanzhong](#):
>
> If so is this feature already working and just not documented completely yet, or is it still a work in progress

the cross DC feature is still `experimental`, but you can run it (using RPC stack)

> <https://github.com/temporalio/temporal/blob/main/Makefile#L428-L432>

[https://github.com/temporalio/temporal/blob/master/config/development\_active.yaml](https://github.com/temporalio/temporal/blob/master/config/development_active.yaml)  
[https://github.com/temporalio/temporal/blob/master/config/development\_standby.yaml](https://github.com/temporalio/temporal/blob/master/config/development_standby.yaml)
