Comments (3)
It would be nice if this could be relatively generic. I can see a couple more use cases for us.
On a first thought, perhaps it could have a configuration system that allows to set multiple of listening queue, message template, destination email.
What do you think?
from sda-pipeline.
Yes I think genericism is good too.
Since we start with 2 separate notifications (one for errors and one for everything is complete) we have a good base to start from for figuring out how it should be generic.
I see there are at least 3 things you want to be able to configure:
- Email template (fairly simple)
- MQ to listen too (very simple)
- Some criteria that should be fulfilled for an email to be sent when a message arrives in the MQ (quite difficult)
For the criteria a first step could be to just give a reference to a function that should be called to evaluate? The config could be something like (example only, might not work):
- template: error.template
mq: v1.errors
trigger_function: always
- template: done.template
mq: v1.ready
trigger_function: check_all_done
But I suggest that step one is to just implement the two use-cases separately. And then as step 2 look at them and see if they can be abstracted and configured in some good way (for example like I suggested above, some other method might be better). Usually it's not until the second or third rewrite that these things start to work out.
from sda-pipeline.
Perhaps there could be a simpler solution for implementing the trigger.
What about matching a regex? So the config file would be:
- template: error.template
mq: v1.errors
trigger_regex: /.*/
- template: done.template
mq: v1.ready
trigger_regex: /Done/
from sda-pipeline.
Related Issues (20)
- Listen to the error queue and send an email to the submitter for errors [notify service]
- Listen to the mq queue that gets "ready" messages and send out an email once the final ready message for a submission is recieved.
- Writing to database problem HOT 2
- Add SFTP support to backup service
- support for multiple s3 buckets HOT 2
- Authentication for submission API
- Queues hang when there is no permission to publish HOT 2
- Broker configuration ignores the exchange
- Create a suggestion list on how to deal with "cancel messages"
- Consistent handling of messages
- Move logging to functions HOT 1
- cancel message presentation
- incorrectly mounted volumes
- Rewrite orchestrator in go HOT 1
- Add new messages from CEGA
- Document go based orchestrator according to the standard HOT 1
- Add integration test workflow for the orchestrator case
- integration test for allowed characters HOT 1
- Add authentication to API service HOT 1
- Ensure that services do not retrieve more messages than they can handle
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 sda-pipeline.