Comments (7)
You can already do this using wildcards. Set all workers to a wildcard by default, such as icecream.*
, then, you can replace the wildcard with a specific flavor
from pg-boss.
Sorry, I don't get it.
Does the producer that send the message must know the consumer's queue in di case?
My target would be having a silly producer that does not know how many consumers the BE has
from pg-boss.
Queue patterns use the * character to match 0 or more characters. For example, a job from queue status-report-12345 would be fetched with pattern status-report-* or even stat*5.
For example, a producer would use the flavor as part of the queue name, such as icecream.vanilla
and icecream.chocolate
. A consumer using work('icecream.*')
would get both flavors, but another consumer using work('icecream.vanilla')
would not get chocolate.
from pg-boss.
The proposed solution assumes that I have control over the producer - it is not the case 😞
from pg-boss.
Would you mind to accept a PR with such a feature in case?
from pg-boss.
Yes, sounds good
from pg-boss.
This would be useful. I didn't see a test case for work('icecream.*.toppings.none')
sort of queue layouts.
from pg-boss.
Related Issues (20)
- Stopping pg-boss gracefully does not wait until stop timeouts HOT 9
- 'stopping' state missing in TypeScript Types HOT 1
- Easier observability for expired jobs HOT 1
- Is pg-boss actively maintained? HOT 2
- Scheduled jobs cannot run more than once per minute HOT 7
- Limiting Concurrent Active Jobs Across Multiple Queues HOT 2
- Scheduling many individual jobs for the same queue HOT 3
- Document onComplete option HOT 1
- Job heartbeat support HOT 4
- Silently rejecting jobs when the db is not connected HOT 1
- New UUIDv7 increased performance and indexes HOT 1
- Add a way to limit maximum retry delay for exponential backoff
- Should expire_in_seconds set the state to expired? HOT 1
- Documentation for PgBoss constructor db option.
- sub queues or queue groups
- Specify multiple host connections for PostgreSQL / Database Fail-Over
- Use of MD5 for Advisory Locks Crashes pg-boss on FIPS-Compliant Platforms HOT 1
- useSingletonQueue missing from JobInsert type
- Error: Jest has detected the following 1 open handle potentially keeping Jest from exiting HOT 2
- Typo in validation for Postgres names HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pg-boss.