# Setting the data\_stream.namespace

**URL:** <https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506>\
**Category:** Elastic Observability\
**Tags:** elastic-stack-monitoring\
**Created:** [October 21, 2023, 2:20pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506 "2023-10-21T14:20:51Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kevin\_Patterson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kevin_patterson/32/126741_2.png) [@Kevin\_Patterson](https://discuss.elastic.co/u/Kevin_Patterson)\
**Post date:** [October 21, 2023, 2:20pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/1 "2023-10-21T14:20:51Z")

</div>

I've seen numerous posts for folks requesting how to set the `data_stream.namespace` in the apm-server.yml, but I dont think any have a response. They've all been closed after 20 days, so attempting to ask that same question again:

how do we set data\_stream.namespace in the apm-server.yml ?

Thank you,

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [October 21, 2023, 2:41pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/2 "2023-10-21T14:41:58Z")

</div>

Hi @Kevin_Patterson Welcome to the community.

Is this what you are looking for?

> **[General configuration options | APM User Guide \[8.11\] | Elastic](https://www.elastic.co/guide/en/apm/guide/current/configuration-process.html#data_streams.namespace)**

> APM Server binary
> 
> apm-server.data\_streams.namespace
> 
> Fleet-managed
> 
> Namespace (Integration settings \> Advanced options)

---

<div class="post-metadata">

**Author:** ![Kevin\_Patterson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kevin_patterson/32/126741_2.png) [@Kevin\_Patterson](https://discuss.elastic.co/u/Kevin_Patterson)\
**Post date:** [October 21, 2023, 5:59pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/3 "2023-10-21T17:59:55Z")

</div>

> [@stephenb](#):
>
> apm-server.data\_streams.namespace

That is what I'm looking for but that doesn't seem to work....My v7 related APM had a setup like so:

```auto
    indices:
    - index: "apm-%{[observer.version]}-%{[service.name]}-transaction-000001"
      when.contains:
        processor.event: "transaction"

```

But using the equivalent with the data\_stream it seems that namespace does not get set....

even using:

```auto
    data_stream:
      namespace: testnamespace

```

I still see only the default getting used.

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [October 21, 2023, 9:33pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/4 "2023-10-21T21:33:32Z")

</div>

Apologies I should have asked exactly what version APM server?

And Binary or Fleet Managed?

Looks like that setting became available in 8.8

---

<div class="post-metadata">

**Author:** ![Kevin\_Patterson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kevin_patterson/32/126741_2.png) [@Kevin\_Patterson](https://discuss.elastic.co/u/Kevin_Patterson)\
**Post date:** [October 21, 2023, 10:04pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/5 "2023-10-21T22:04:55Z")

</div>

I'm using 8.5.3 Binary.

If/Can I use a newer APM (8.8) with the 8.5.3 server ?

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [October 21, 2023, 10:18pm UTC](https://discuss.elastic.co/t/setting-the-data-stream-namespace/345506/6 "2023-10-21T22:18:58Z")

</div>

No, Although it may / may not work ... Other components should not be "ahead" of Elasticsearch.

Elasticsearch should be equal to or ahead of the other components. Kibana and Elasticsearch should always be at the same version.

> **[Upgrade Elastic on-prem | Elastic Installation and Upgrade Guide \[8.10\] |...](https://www.elastic.co/guide/en/elastic-stack/current/upgrading-elastic-stack-on-prem.html#upgrading-elastic-stack-on-prem)**
