# I want to write in another index with project monitor (synthetic monitor) It's possible?

**URL:** <https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232>\
**Category:** Synthetics\
**Created:** [August 2, 2022, 3:24pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232 "2022-08-02T15:24:00Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![odelacruzc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/odelacruzc/32/48992_2.png) [@odelacruzc](https://discuss.elastic.co/u/odelacruzc)\
**Post date:** [August 2, 2022, 3:24pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/1 "2022-08-02T15:24:00Z")

</div>

I want to write in another index with project monitor (synthetic monitor) It's possible?, I can to change the index synthetic-\* or write in other datastream?

---

<div class="post-metadata">

**Author:** ![lucasfcosta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lucasfcosta/32/97382_2.png) [@lucasfcosta](https://discuss.elastic.co/u/lucasfcosta)\
**Post date:** [August 3, 2022, 10:06am UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/2 "2022-08-03T10:06:42Z")

</div>

Hi Oscar,

Thank you for your question. It seems like your question is similar to [this one](https://discuss.elastic.co/t/separating-heartbeat-synthetics-logs-from-the-rest/311193).

In there you will find Tiago's comments which outlines that you can indeed configure these indexing conditions depending on the data. For that, you can have a look at the docs [here](https://www.elastic.co/guide/en/beats/heartbeat/current/elasticsearch-output.html#indices-option-es).

Hope that helps! Please let me know if that's not exactly what you needed or whether there's anything else I can do to help 🙂

---

<div class="post-metadata">

**Author:** ![odelacruzc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/odelacruzc/32/48992_2.png) [@odelacruzc](https://discuss.elastic.co/u/odelacruzc)\
**Post date:** [August 3, 2022, 2:39pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/3 "2022-08-03T14:39:42Z")

</div>

Hi Lucas,  
Currently I don't use Heartbeat, I use Project monitor so I send the monitor by push command (Push api-key url-kibana name-project), installed nodeJS and Playwright @elastic/synthetic, so this method send to index synthetic-\* by default, this is a DataStream.

---

<div class="post-metadata">

**Author:** ![lucasfcosta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lucasfcosta/32/97382_2.png) [@lucasfcosta](https://discuss.elastic.co/u/lucasfcosta)\
**Post date:** [August 8, 2022, 8:28am UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/4 "2022-08-08T08:28:13Z")

</div>

Hi Oscar, unfortunately there's no way of doing this yet in case you're pushing monitors to the managed infrastructure to run.

I will bring your suggestion to the team for us to discuss and maybe implement, but I can't make any promises about that, although I do think it is an interesting/useful request.

In the mean time, you should be able to edit the data stream, change the backing-indices, and then reindex the documents from the old index that was being used as the current. I know this is suboptimal, but thought I'd bring it up in case you think it could be helpful.

Thanks again for reaching out, Oscar

---

<div class="post-metadata">

**Author:** ![lucasfcosta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lucasfcosta/32/97382_2.png) [@lucasfcosta](https://discuss.elastic.co/u/lucasfcosta)\
**Post date:** [August 11, 2022, 12:50pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/5 "2022-08-11T12:50:41Z")

</div>

Hey Oscar, one question we discussed within the team is whether you'd be able to explain us a bit more about the use case of changing those indices. We thought that maybe there would be a better way of accomplishing what you wanted without changing the backing indices themselves.

Would you be able to provide us with some more details on this?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![odelacruzc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/odelacruzc/32/48992_2.png) [@odelacruzc](https://discuss.elastic.co/u/odelacruzc)\
**Post date:** [August 11, 2022, 7:43pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/6 "2022-08-11T19:43:53Z")

</div>

Hi Lucas,  
We want to generate synthetic monitors for different clients, so each client should have an index with different ILMs, as the client requires.

Do you need another information? Tell me please!

---

<div class="post-metadata">

**Author:** ![odelacruzc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/odelacruzc/32/48992_2.png) [@odelacruzc](https://discuss.elastic.co/u/odelacruzc)\
**Post date:** [August 12, 2022, 8:36pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/7 "2022-08-12T20:36:18Z")

</div>

Lucas,  
In addition to this,

1. Is it possible to alter the format of the data Stream index? for example .ds-synthetics-browser-default-2022.08.05-000001, I want to remove the date. That is, what things can I work or customize on the data stream synthetics-_-_.
2. When we use push command to send monitor project to kibana, we have two options in --project =\> id | name, how do I send a value for the id and another for the name?

---

<div class="post-metadata">

**Author:** ![emilioalvap](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/emilioalvap/32/99310_2.png) [@emilioalvap](https://discuss.elastic.co/u/emilioalvap)\
**Post date:** [August 16, 2022, 10:09pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/8 "2022-08-16T22:09:50Z")

</div>

Hi @odelacruzc,

Thanks for providing information on your use case.

It should be possible to have multiple monitors write to different data streams with the use of spaces. You can use the `--space` option with the `push` command to achieve this effect, specifying an existing [Kibana space](https://www.elastic.co/guide/en/kibana/master/xpack-spaces.html). When monitors are pushed with a different space, a new data stream is generated with the format `synthetics-<monitor type>.<data type>-<space>`.

Once you have separate data streams, you can follow [this tutorial](https://www.elastic.co/guide/en/fleet/current/data-streams.html#data-streams-ilm-tutorial) to set custom ILM policies for them. You'll need to do so for each of the data streams in which synthetics data gets segmented into. We do recommend against editing existing managed policies for synthetics integrations.

About your other questions:

1. Backing indices for data streams are generated automatically, there's no actual way of changing how this [name is generated](https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html#data-streams-generation).
2. Cli log is not very clear on this, `--project` is used to group monitors from a same project and it only takes a single value. There's a more detailed explanation [here](https://www.elastic.co/guide/en/observability/current/synthetics-command-reference.html#elastic-synthetics-push-command).

Hope this helps.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 9, 2022, 10:10pm UTC](https://discuss.elastic.co/t/i-want-to-write-in-another-index-with-project-monitor-synthetic-monitor-its-possible/311232/9 "2022-09-09T22:10:45Z")

</div>

This topic was automatically closed 24 days after the last reply. New replies are no longer allowed.
