~singpolyma/sgx-jmp

ref: 045da39f25b74034e7bba44cb5f1db48a935ba84 sgx-jmp/sgx_jmp.rb -rw-r--r-- 15.8 KiB
Hotfix: can't create this until REDIS exists now
Merge branch 'finish-btc'

* finish-btc:
  No more legacy session for BTC
  Do not lose WebRegisterManager on retart
Do not lose WebRegisterManager on retart

Store web registrations in redis.  Set an expiry so they don't grow in RAM
forever as they previously would have without a restart.
Allow Next on Picker Form

Execute works, but next is more right
Need node for spec compliance

And also so Gajim works
Customer Info

This should allow us, the admins, to query information about a customer
without having to dive in and run a couple redis queries and some
database queries before getting the full picture of who we're talking
to.

It also allows the users to request some data about themselves. Balance and
phone number are already visible in other places, but their expiry is currently
not, and people have been asking about it.
Invite Codes is a Result Form

If we don't do this, the ad-hoc bot won't format the table properly.
Merge branch 'invite-codes'

* invite-codes:
  Command to list unused invite codes
Command to list unused invite codes

Instructions also provide details about how the program works.
Check for going over 500 every time

Don't fill redis with keys for users who did not go over
Check config against schema when loading

So we know very quickly why it's not working.
Customer always has a JID
There might be no customer
Merge branch 'low-balance-auto-top-up'

* low-balance-auto-top-up:
  Some people have exactly 5 who don't need to be told
  On low balance, top-up or notify
  ExpiringLock helper
Some people have exactly 5 who don't need to be told
On low balance, top-up or notify

On start up, check for users with low balance and NOTIFY about them.  LISTEN for
such notifications and process by either sending a low-balance warning message
or else attempting an auto-top-up as configured.

Using NOTIFY/LISTEN because then we can NOTIFY after any INSERT that leaves the
balance too low (using a trigger).  Doing the sync on start-up in case we missed
a NOTIFY during any downtime.  Using the Redis lock to prevent spamming a
low-balance user in case of many restarts or if they have many small
transactions happen in one day.
ExpiringLock helper

For things we want to do only so often, set up a helper to push expiring keys to
Redis and check for them.
Merge branch 'cancel-timeout'

* cancel-timeout:
  Timeout is not a fatal error
  When user cancels the command, respond with canceled
Next