Using memory jugglingdb adapter forces opt-in to re-registering on startup and deregistering on shutdown. no-dereg changed to force-dereg.
Samuel Day
Branch: samcday/atlassian-connect-express:feature/dev-registration-logic
Branch: atlassian/atlassian-connect-express:master
Merged
Merged pull request
Merged in sday_atlassian/atlassian-connect-express/feature/dev-registration-logic (pull request #38)
As a followup to the registration logic changes I made in #35, this PR fixes what I broke ;)
The issue is that if you're using the JugglingDB memory adapter, you most certainly want to be forcing registration and de-registration whenever the app starts up and shuts down. Once you use any kind of store that persists between restarts, you almost always want to use the logic I added in #35. This PR changes
no-dereg
AC_OPT to instead beforce-dereg
, and brute-force addsforce-dereg
+force-reg
to process.env.AC_OPTS, if the JugglingDB store is memory.FWIW, I looked into making the sqlite3 adapter the default for ACE apps, but I had to raise this PR as the sqlite3 adapter doesn't actually support Schema.JSON, which we're using. What a mess! Once that PR is merged upstream I'd like to propose that we make sqlite3 the default store for ACE apps.