Skip to main content

How to manage Namespaces in Temporal Cloud

A Namespace is a unit of isolation within the Temporal Platform.

What is a Cloud Namespace Name?

A Cloud Namespace Name is a customer-supplied name for a Namespace in Temporal Cloud. Each Namespace Name, such as accounting-production, is unique within the scope of a customer's account. It cannot be changed after the Namespace is provisioned.

Each Namespace Name must conform to the following rules:

  • A Namespace Name must contain at least 2 characters and no more than 34 characters.
  • A Namespace Name must begin with a letter, end with a letter or number, and contain only letters, numbers, and the hyphen (-) character.
  • Each hyphen (-) character must be immediately preceded and followed by a letter or number; consecutive hyphens are not permitted.
  • All letters in a Namespace Name must be lowercase.

What is a Temporal Cloud Account Id?

A Temporal Cloud Account Id is a unique identifier for a customer for the entire time they use Temporal Cloud. Temporal Technologies assigns each Account Id, which is an opaque code of five or six alphanumeric characters, such as f45a2. The Account Id is shown in the upper-right corner of Workflows and Schedules listed in the Web UI.

info

For more information on obtaining a Temporal Cloud Account Id, see our Cloud account commands page.

What is a Cloud Namespace Id?

A Cloud Namespace Id is a globally unique identifier for a Namespace in Temporal Cloud. A Namespace Id is formed by concatenating the following:

  1. A Namespace Name
  2. A period (.)
  3. The Account Id to which the Namespace belongs

For example, for the Account Id f45a2 and Namespace Name accounting-production, the Namespace Id is accounting-production.f45a2.

How to create a Namespace in Temporal Cloud

info

The user who creates a Namespace is automatically granted Namespace Admin permission for that Namespace.

To create a Namespace, a user must have the Developer or Global Admin account-level Role.

tip

By default, each account has a quota of 10 Namespaces. If you want to increase this limit, open a support ticket.

Information needed to create a Namespace

To create a Namespace in Temporal Cloud, gather the following information:

Create a Namespace using Temporal Cloud UI

  1. Gather the information listed earlier in Information needed to create a Namespace.
  2. Go to the Temporal Cloud UI and log in.
  3. On the left side of the window, click Namespaces.
  4. On the Namespaces page, click Create Namespace in the upper-right portion of the window.
  5. On the Create Namespace page in Name, enter the Namespace Name.
  6. In Region, select the region in which to host this Namespace.
  7. In Retention Period, specify a value from 1 to 90 days. When choosing this value, consider your needs for Event History versus the cost of maintaining that Event History. Typically, a development Namespace has a short retention period and a production Namespace has a longer retention period. (If you need to change this value later, contact Temporal Support.)
  8. In Certificate, paste the CA certificate for this Namespace.
  9. Optional: In Codec Server, enter the URL and port number of your Codec Server endpoint. For details, see Securing your data.
  10. Click Create Namespace.

Create a Namespace using tcld

See the tcld namespace create command reference for details.

What are some Namespace best practices?

This section provides general guidance for organizing Namespaces across use cases, services, applications, or domains. Temporal Cloud provides Namespace–as-a-service, so the Namespace is the endpoint. Customers should consider not only a Namespace naming convention but also how to group or isolate workloads using the Namespace as a boundary.

Constraints and limitations

Before considering an appropriate Namespace configuration, you should be aware of the following constraints:

  • Each Temporal account has a default limit of 10 Namespaces. You can request an increase by creating a ticket for Temporal Support.
  • Cross-Namespace communications between Workflows is not yet supported. For now, you can use the SDK client from within an Activity as a workaround.
  • Each Namespace has a rate limit ("throttling"). The default rate limit is 200 Actions per second but can be increased via a support ticket.
  • Each Namespace has a service-level agreement (SLA) of 99.9% uptime.
  • For now, Namespaces are single-region only.
  • A Namespace is a security isolation boundary. Access to Temporal by Worker Processes is permitted at the Namespace level. Isolating applications or environments (development, test, staging, production) should take this into consideration.
  • A Namespace is an endpoint. To access a Namespace from a Temporal Client requires mTLS authorization, which requires CA certificates.
  • Workflow Id uniqueness is per Namespace.
  • Task Queue names are unique per Namespace.
  • Closed Workflow retention is per Namespace.
  • RBAC permissions are implemented at the Namespace level.

General guidance

Namespace configuration requires some consideration. Following are some general guidelines to consider.

  • Namespaces are usually defined per use case. A use case can encompass a broad range of Workflow types and a nearly unlimited scale of concurrent Workflow Executions.
  • Namespaces can be split along additional boundaries such as service, application, domain or even sub-domain.
  • Environments such as production and development usually have requirements for isolation. We recommend that each environment has its own Namespace.
  • Namespaces should be used to reduce the "blast radius" for mission-critical applications.
  • Workflows that need to communicate with each other should (for now) be in the same Namespace.
  • If you need to share Namespaces across team or domain boundaries, be sure to ensure the uniqueness of Workflow Ids.

Examples

Following are some ideas about how to organize Namespaces.

Example 1: Namespace per use case and environment

We recommend using one Namespace for each use case and environment combination for simple configurations in which multiple services and team or domain boundaries don't exist.

Sample naming convention:

<use-case>_<environment>

Example 2: Namespace per use case, service, and environment

We recommend using one Namespace for each use case, service, and environment combination when multiple services that are part of same use case communicate externally to Temporal via API (HTTP/gRPC).

Sample naming convention:

<use-case>_<service>_<environment>

Example 3: Namespace per use case, domain, and environment

We recommend using one namespace per use case, domain, and environment combination when multiple services that are part of the same use case need to communicate with each another via Signals or by starting Child Workflows. In this case, though, you must be mindful about Workflow Id uniqueness by prefixing each Workflow Id with a service-specific string. The name of each Task Queue must also be unique. If multiple teams are involved, the domain could also represent a team boundary.

Sample naming convention:

<use-case>_<domain>_<environment>

Sample workflowId convention:

<service-string>_<workflow-id>

How to access a Namespace in Temporal Cloud

Each Namespace in Temporal Cloud has two unique endpoints, both of which include the Namespace Id.

  • For programmatic access, a gRPC endpoint in the form <NamespaceId>.tmprl.cloud; for example, accounting-production.f45a2.tmprl.cloud:7233.
  • For accessing Temporal Web UI, an HTTPS endpoint in the form https://cloud.temporal.io/namespaces/<namespaceId>; for example, https://cloud.temporal.io/namespaces/accounting-production.f45a2.

How to manage Namespaces in Temporal Cloud

Manage Namespaces in Temporal Cloud using Temporal Cloud UI

To list Namespaces:

  • On the left side of the window, select Namespaces.

To edit a Namespace (including custom Search Attributes, certificates, certificate filters, Codec Server endpoint, permissions, and users), find the Namespace and do either of the following:

  • On the right end of the Namespace row, select the three vertical dots (⋮). Click Edit.
  • Select the Namespace name. In the top-right portion of the page, select Edit.

On the Edit page, you can do the following:

To add a user to a Namespace, scroll to the bottom of the page and select Add User.

After you make changes, select Save in the top-right or bottom-left portion of the page.

Manage Namespaces in Temporal Cloud using tcld

To list Namespaces and get information about them, use the following tcld commands:

To manage certificates, use the tcld namespace accepted-client-ca commands. For more information, see How to manage certificates in Temporal Cloud.

To manage certificate filters, use the tcld namespace certificate-filters commands. For more information, see How to manage certificate filters in Temporal Cloud.

How to delete a Namespace in Temporal Cloud

info

To delete a Namespace, a user must have Namespace Admin permission for that Namespace.

Delete a Namespace using Temporal Cloud UI

  1. Go to the Temporal Cloud UI and log in.
  2. On the left side of the window, select Namespaces.
  3. On the Namespaces page, select a Namespace Name.
  4. On the Namespace page, select Edit in the upper-right portion of the window.
  5. On the Edit Namespace page, select Delete Namespace in the upper-right portion of the window.
  6. In the Delete Namespace dialog, type DELETE to confirm the deletion of that Namespace.
  7. Select Delete.

Delete a Namespace using tcld

This functionality is in development.