Working on AECtech mongodb in realtime

I am currently working on a project that involves using Dynamo Revit with a package called AECTech to load data into dynamo using a MongoDB database in real time. However, I am facing an issue where the “Automatic” feature in Dynamo does not seem to work. Dynamo fails to automatically add new values to the database, requiring me to manually configure MongoDB settings and rerun the process in order to view the updated values. This inconvenience prompts me to seek a solution that enables automatic updates of values in the database.

Likely Dynamo isn’t picking up that the DB has updated. Likely you could set a trigger an update via boolean or other UI toggle into a WaitFor method, but that would be an on-demand update.

Can you post your graph as it stands so we can see where another trigger with an automatic mode could be inserted?

1 Like


This is the graph I am currently working on. As you can see, there is a 163 value in the database shown here but in reality there is more . I need to rerun it as I mentioned earlier.
I didn’t fully grasp how to implement a trigger. If you could provide further explanation, I would greatly appreciate it.

Because the AECtech package doesn’t have any input in the GetDB node this gets tricky.

See if you can convert that to design script by selecting it, then right clicking on the background and choosing ‘Node to code’. I’ll assume that if it works it returns something like database = MongoDB.GetDB();

Set that line to something like this:
database = test? MongoDB.GetDB() : MongoDB.GetDB();, and wire a True/False input into that. Now each time you toggle the true false value the database should update, which will update all subsequent nodes allowing you to call for updates on demand.

If the node can’t be converted to design script, the we’re back at square one…

Further to what @jacob.small has indicated it might be better to utilise the following IronPython2 code in a separate node then add " *Force " to the start of the node you want to force a re-run on.

thank you so much it worked i added the code and “*Force” to Mongodb.GetDB @jacob.small @Brendan_Cassidy