Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

notifications scheduler #174

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
6f25fcb
feat: :sparkles: start scheduler work
ignazio-bovo Aug 24, 2023
9d1d603
test: :white_check_mark: add test setup
ignazio-bovo Aug 24, 2023
1d6eb10
feat: :art: review data model
ignazio-bovo Aug 25, 2023
2b1fe5e
feat: :art: setup tests and refactor data model
ignazio-bovo Aug 25, 2023
1675e0f
test: :art: add extra seed data
ignazio-bovo Aug 26, 2023
1fe7bbd
feat: :art: EmailDelivey.status success status changed on sendNew
ignazio-bovo Aug 26, 2023
602bfd1
feat: :art: report entities generated on sendNew
ignazio-bovo Aug 26, 2023
1ba12cd
feat: :art: add support for error status
ignazio-bovo Aug 26, 2023
73f9bd7
fix: :bug: avoid rewriting failedDlivery field on EmailDelivery with …
ignazio-bovo Aug 26, 2023
ec6fb7b
fix: :art: add fk for inApp and email delivery no notification entity
ignazio-bovo Aug 27, 2023
2b5bef3
feat: :art: add max attempt config variable
ignazio-bovo Aug 28, 2023
22f1607
feat: :art: seed data for config variable
ignazio-bovo Aug 28, 2023
7795da3
fix: :art: refactor after rebase
ignazio-bovo Sep 28, 2023
92549a4
feat: :white_check_mark: start adding test boilerplate code
ignazio-bovo Sep 29, 2023
d38ee12
feat: :rewind: rebase to orion_notifications
ignazio-bovo Sep 29, 2023
6104701
Add an MJML template for email notifications
thesan Oct 4, 2023
65fa546
Update the links
thesan Oct 5, 2023
c523cc0
Adjust the template after testing it
thesan Oct 5, 2023
35f91de
Update email links, texts, and icons
thesan Oct 11, 2023
d677a96
Add avatars in email notifications
thesan Oct 11, 2023
03c586a
Format amounts of JOYs in the notifications
thesan Oct 12, 2023
6b6039c
Have notification nft links open the nft widget
thesan Oct 12, 2023
248825a
Point icon links to GH for now
thesan Oct 12, 2023
b580bda
Fix the `formatJOY` function
thesan Oct 13, 2023
0f5b930
Add the missing email data
thesan Oct 13, 2023
85bc7a6
Update the template for png icons
thesan Oct 13, 2023
d23fdd8
Improve avatar code
thesan Oct 14, 2023
e6b252d
Remove unnecessary change
thesan Oct 16, 2023
dbb8928
Merge pull request #3 from thesan/feature/notification-emails
ignazio-bovo Oct 17, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ COOKIE_SECRET=this-is-not-so-secret-change-it

# Notification related variables
APP_ROOT_DOMAIN=gleev.xyz
NOTIFICATION_CENTER_PATH=notification-center # https://${APP_ROOT_DOMAIN}/${NOTIFICATION_CENTER_PATH}

TRUST_PROXY=uniquelocal

Expand All @@ -64,3 +63,6 @@ SENDGRID_FROM_EMAIL=gateway@example.com
# Debug settings
SQD_DEBUG=api:*
OPENAPI_PLAYGROUND=true

# max number of attempts to deliver email notification
EMAIL_NOTIFICATION_DELIVERY_MAX_ATTEMPTS=5
19 changes: 19 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,3 +62,22 @@ jobs:
run: make prepare
- name: Run tests
run: npm run tests:notifications
mail-scheduler:
name: Mail scheduler tests
needs: [migrations]
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
node-version: [16.x]
fail-fast: true
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{matrix.node-version}}
uses: actions/setup-node@v1
with:
node-version: ${{matrix.node-version}}
- name: Prepare workspace
run: make prepare
- name: Run tests
run: npm run tests:mail-scheduler
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
/.vscode
/.idea
src/model/generated
src/auth-server/emails/templates/*.mst
src/auth-server/emails/templates/preview
/schema.graphql
/db/persisted
/scripts/orion-v1-migration/data
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions db/migrations/2000000000000-Views.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ module.exports = class Views2000000000000 {
token: ['FALSE'],
nft_featuring_request: ['FALSE'],
gateway_config: ['FALSE'],
email_delivery_attempt: ['FALSE'],
// TODO (notifications v2): make this part of the admin schema with appropriate resolver for queries
// notification: ['FALSE'],
}
Expand Down
Loading
Loading