Perspective - system.util.getGlobals() - help required

I have a project that I use to set some lists throught the system.util.getGlobals(). I want to be able to use that lists in other projects. Is there a way to do that ?

I want to be able to share lists with all my projects.

Should work in the gateway, if that’s what you mean. Probably with Perspective, too, as those scripts also run in the gateway. Definitely not in a Vision client.

I have an inheritable project to share all my scripts. My other projects are herited of that script project.

I have a second project that run GATEWAY EVENT TAG CHANGE SCRIPT and that event build some lists of tags (ex. my config tags). I want that project build all lists for my other projects as main tags manager and I use a wildcard (*) for all tags of all providers, and each providers has his own list of config tags.

In my other project à have a CONFIG MANAGER that SAVE/LOAD config to a database. For performance reason I want to use the list of tags builded by my second project.

My second project build lists correctly but when I try to reach a list from other projects I got that list doesn’t exist. It seems that the list is scoped to the second project and other projects can’t reach them.

I search a way to pass list between projects, I thingked that syste.util.getGlobals() was abled to do that but I can’t figure how actually.

I just tested this by setting a global equal to the current timestamp every second in a perspective page, and then in another project trying to pull that global every second and show it on a label.
I opened both pages (both in separate projects) and it looks like the second one cant see the global from my first one.

I am not sure if the isolation to one specific project is intended or not (Documentation doesnt say)

One thing that you could do, albeit maybe not as neat as the global property, is create a memory tag with the type Document. A Document memory tag is essentially just a JSON, just like perspective properties. So you could write your list to an array object in that document tag, just like you would a perspective property. Then you could treat them “like session properties” but across the entire gateway.

However I will note that I have had a few bugs with that memory tag type, in that its wrapped in a DocumentWrapper that makes it not work exactly like a dictionary. So when you need it, you should do a document = system.util.jsonDecode(str(documentTag.value)) to cast it as a python dictionary, then read/write whatever you want. When you want to write it back do a system.util.jsonEncode(document) to convert it back into a string and then write it to your tag.

Thanks, will use that solution.