UI-State-Trail persistence data help

Can you tag people @hotNipi ??

I'm struggling with the persistence setup on this node. I assume if I correctly set the setting.js (below) then the node should store its own data? if this is the case I dont understand why I am seeing "Store: N/A" (below2)

image
image

Help would be greatly appreciated

Settings seems to be correct.
Do you have any other node, using the persistent storage? Do they work correctly?
How (where) are you running the node red? Locally? Cloud?

its a local box (running in one of many docker containers)

I've changed my config to be same as seen in the example so now it looks like this.


done a restart and still not grafting.
Going to look at storing some manual data now see if that works..

I'm not an expert of docker installations but it seems that Node-RED can't access the file system.

not sure how to word this in one question

should the node be saving to to context regardless of persistence settings?
should I be able to view node data in the node context once its running?

Node uses same storage options as if you can use in function node - context.set('data',data)
Yes you can see it - navigate to .node-red folder and see if there is context folder, inside that you'll find folders with sort of id's
image
and one of them should have JSON file inside with interested node's id as the name of file.
And it is pretty simple json with your states in it.
image

If you are using projects, the context folder is moved to project space. Do search ...

should I be able to view data here?

image

Yes, that should show also.
image

ok, saves me digger through the docker containers to find the file.

I would assume that even with persistence setup that node conext should fill for the session but it isnt.

I'm going to spin up a container with the latest node-red to see if that solves it

No. Node holds live data in local object and does not even try to use context if persistence is not available.

Balls.

Back to digging

Fettled it.
image
For reference if anyone else finds this.

Docker systems contains two settings.js files I was editing the one under

/usr/src/node0red/node_modules/node-red/settings.js

the actually settings file is located

/data/settings.js
1 Like

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