Insert record in MongoDB directly

Good morning,
I’m using GenieACS 1.1.3 an all work’s fine but I’ve seen some strange and unattended behavior, then I’m asking if insert or edit directly presets into MongoDB from my intranet, can destabilize GenieACS.

It seem that some preset, created and next edited, stay cached in some place in different version and cause me provisioning problems.

Really thanks if someone can give me information about.
Regards

Daniele Callari

You can create less complex preset, like productclass only, and had more condition in javascript on the provisionning template.

Do not insert records into mongo directly. Genie caches data. Use the API to create/update/delete your presets.

1 Like

Owwww, you confirm my theory, really thanks for your reply!
I supposing that this cache is part of the GenieACS engine’s performance, but someone know if this
cache can be regenerated programmatically? …and… this cache is a MongoDB feature or Genie?

The caching is done in Genie, and yes its for performance.

GenieACS has extensive APIs for you to do everything you need to do. In fact, the GUI uses the APIs exclusively and does not perform CRUD operations in Mongo at all.

Also, why do you need to create presets programatically? Are you doing one preset per subscriber? This will cause significant performance issues with Genie as on every interaction with a CPE every preset has to be checked to see if it applies to the CPE. See the wiki entry Example of a Provisioning Flow, Sergio wrote up the wiki entry using example code I sent to him.

I provision all of our subscribers using this process and a total of 20 presets. And only 2-3 of those presets actually run for each CPE (depending on the state of the CPE), and several of the presets we have a purely diagnostic/logging in nature (log when a CPE was bootstrapped, rebooted, performs a diagnostic event).

-dan

Ok, i’ve finally found the time for upgrade GenieACS and migrate from “presets templates” mode to native provision style.
Effectively with 6 tags and 8 presets I can manage all my CPE. After all test, I’ve been putted new server in production.
Great and thanks at all.