parse-community / parse-community/parse-server
Support wildcard classname in cloud triggers
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 21.4k
- Forks
- 4.8k
- Avg merge
- 7h 45m
- Merged PRs (30d)
- 11
Description
New Feature / Enhancement Checklist
- I am not disclosing a vulnerability.
- I am not just asking a question.
- I have searched through existing issues.
Current Limitation
Currently user have to define cloud triggers one by one. If we have a recurring logic inside of cloud trigger, defining triggers become too hard.
Feature / Enhancement Description
We should be able to define one trigger that applies to all class. Unless that class has its own triggers.
Example Use Case
Parse.Cloud.beforeSave("Test", (request) => {
//this trigger will be executed for only Test class
});
Parse.Cloud.beforeSave("*", (request) => {
//this trigger will be executed for every class except Test class
});
Alternatives / Workarounds
No known workaround or alternative.
3rd Party References
Its similar to setting SSL sertificates to multiple subdomains.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Parse.Cloud.beforeSave registration and the cloud-trigger dispatch path, then inspect how class-specific triggers are stored and selected. Review the existing cloud-trigger tests and add coverage for a wildcard trigger, an overriding class-specific trigger, and the expected behavior for other classes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100