pg-boss v1.0.0 Release Notes
-
- ⬇️ Dropped support for node 0.10 and 0.12
- ➕ Added new publish option called
singletonKey
was added in order to make sure only 1 job of a certain type is active, queued or in a retry state - ➕ Added new publish option called
singletonNextSlot
was added in order to make sure a job is processed eventually, even if it was throttled down (not accepted). Basically, this is debouncing with a lousy name, because I'm not very good at naming things and didn't realize it at time - ➕ Added
newJobCheckInterval
andnewJobCheckIntervalSeconds
tosubscribe()
instead of just in the constructor - ➕ Added
poolSize
constructor option to explicitly control the maximum number of connections that can be used against the specified database - 👷 0.x had a data management bug which caused expired jobs to not be archived and remain in the job table. 👷 I also added a fix to the migration script so if you had any old expired jobs they should be automatically archived.
- Error handling in subscriber functions!
Previously I've encouraged folks to handle their own errors with try catch and be as defensive as possible in
callback functions passed to
subscribe()
. However, it was too easy to miss that at times and if an error occurred that wasn't caught, 👷 it had the pretty lousy side effect of halting all job processing. 1.0.0 now wraps all subscriber functions in try catch blocks and emits the 'error' event if one is encountered.