# Reread the Flows file when I refreshed the page

**URL:** <https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536>\
**Category:** General\
**Created:** [22 July 2019 06:06 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536 "2019-07-22T06:06:34Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![TomY](https://avatars.discourse-cdn.com/v4/letter/t/9dc877/32.png) [@TomY](https://discourse.nodered.org/u/TomY)\
**Post date:** [22 July 2019 06:06 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/1 "2019-07-22T06:06:34Z")

</div>

Hi Guys！  
I just started learning node-red recently.  
I want to modify the parameters in the Flows file in the background while the Node-RED is running, and when the page of browser is refreshed I can see the update on the workbench.  
Please tell me what should I edit my codes !  
Thanks!  
TomY

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [22 July 2019 06:24 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/2 "2019-07-22T06:24:48Z")

</div>

To get it to re read the flows file you will need it to restart node red.  
Please explain why you need to change the file, it may be that there is a better way of solving your problem.

---

<div class="post-metadata">

**Author:** ![TomY](https://avatars.discourse-cdn.com/v4/letter/t/9dc877/32.png) [@TomY](https://discourse.nodered.org/u/TomY)\
**Post date:** [22 July 2019 06:36 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/3 "2019-07-22T06:36:36Z")

</div>

Thanks for your Reply！  
I want to store the flows files of different users. When someone uses it, I can read his json file from the database and display the flow he made. And node red is running all time.  
If this doesn't work, I will try to modify logic of it.

---

<div class="post-metadata">

**Author:** ![bakman2](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bakman2/32/6207_2.png) [@bakman2](https://discourse.nodered.org/u/bakman2)\
**Post date:** [22 July 2019 14:02 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/4 "2019-07-22T14:02:25Z")

</div>

You could use the [runtime api](https://nodered.org/docs/api/admin/methods/post/flows/) to post a flow to node-red.

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [22 July 2019 17:30 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/5 "2019-07-22T17:30:34Z")

</div>

The Node-RED runtime only runs one set of flows at a time.

For the scenario you describe, the runtime will be running User A's flows, then User B will login and the runtime will stop User A's flows and start User B's flows. That probably isn't what you want to happen.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [22 July 2019 20:04 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/6 "2019-07-22T20:04:28Z")

</div>

Are the individual users logging on to the computer before going to the page? If so then you could include code in the logon scripts (how you do this will depend on the OS you are running) that stops node red and re-starts it pointing to that users flows file. Alternatively you could have multiple versions of node-red running at the same time, one running each user's flows, with different port numbers for each user.

---

<div class="post-metadata">

**Author:** ![TomY](https://avatars.discourse-cdn.com/v4/letter/t/9dc877/32.png) [@TomY](https://discourse.nodered.org/u/TomY)\
**Post date:** [23 July 2019 05:13 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/7 "2019-07-23T05:13:43Z")

</div>

I have understood, I will try to use different ports for each user. Thanks!

---

<div class="post-metadata">

**Author:** ![TomY](https://avatars.discourse-cdn.com/v4/letter/t/9dc877/32.png) [@TomY](https://discourse.nodered.org/u/TomY)\
**Post date:** [23 July 2019 05:15 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/8 "2019-07-23T05:15:23Z")

</div>

This suggestion sounds good, I will try to use it. Thanks again!

---

<div class="post-metadata">

**Author:** ![TomY](https://avatars.discourse-cdn.com/v4/letter/t/9dc877/32.png) [@TomY](https://discourse.nodered.org/u/TomY)\
**Post date:** [23 July 2019 05:19 UTC](https://discourse.nodered.org/t/reread-the-flows-file-when-i-refreshed-the-page/13536/9 "2019-07-23T05:19:43Z")

</div>

I have not learned this aspect yet and I will try to read sth about it .Thanks!
