Skip to content

Commit 662cb8d

Browse files
OmerHarellBlokhr4zendevalonp99Omer Harel
authored
Bullmq alon rebased (#3401)
* feat: webhooks implementation & queue system * fix * wip worker * wip fixes * worker is up * finalized impl * fix circular * env.example * fix rebase conflicts * fix bug caused by rebase * trigger CI * add customer feature flag for opt-in queue system * fix: env schema * wip merge conflicts * fixes * lockfile * env example * Add Docker, Helm, and GitHub workflows for combined deployment * feat(metrics): add BullMQ metrics integration and dashboards - Introduce Prometheus metrics for BullMQ job states and integrate with OpenTelemetry - Set up Grafana dashboards for visualizing BullMQ performance metrics - Implement alerts and queuing system for better monitoring and job processing * refactor(workflows-service): clean up shutdown logic and remove unused types - Remove commented-out code related to graceful shutdown - Delete unused type declaration file for BullMQ OpenTelemetry integration * fix(monitoring): handle absence of BullMQ queues in Prometheus metrics export - Add a check for the existence of BullMQ queue before exporting metrics - Return a placeholder message if no queues are available - Remove the unused OpenTelemetry initialization module from the project * feat(workflows): improve configuration and queue management - Introduce specific environment configuration for worker module - Update Redis client configuration with max retries per request - Enhance job scheduler with job ID configuration to avoid multiple tasks in the cron queue * feat(monitoring): enhance metrics collection and docker configuration - Add Prometheus metrics endpoint for BullMQ queues - Configure Docker Compose for monitoring with Grafana and Prometheus - Register BullMQ queues in Prometheus service for comprehensive metrics tracking * refactor(env): change getEnvFilePath to an arrow function - Convert function declaration to arrow function syntax - Maintain existing functionality in retrieving environment file path * fix(queue): initialize Redis connection conditionally - Check if QUEUE_SYSTEM_ENABLED environment variable is set - Only initialize Redis connection when enabled * Revert "fix(queue): initialize Redis connection conditionally" This reverts commit 67a1997. * fix(queue): initialize Redis connection conditionally - Check if QUEUE_SYSTEM_ENABLED environment variable is set - Initialize Redis connection only when the feature is enabled * chore(docs): remove outdated BullMQ metrics and monorepo navigation documentation - Delete deprecated documentation files for BullMQ metrics implementation - Remove outdated monorepo navigation and command execution guidelines * fix(prometheus): remove public decorator from getMetrics endpoint - Eliminate the public decorator for enhanced security - Ensure metrics are accessible without public exposure * chore(metrics): remove obsolete Grafana dashboard configuration - Delete grafana-dashboard.json file as it is no longer needed - Streamline application code for clarity and maintainability fix(middleware): update request authorization checks for admin users - Ensure middleware correctly accesses user type from session - Improve security by preventing unauthorized access feat(metrics): add metrics endpoint for Prometheus status - Implement /prometheus endpoint to check metrics collection status - Enhance team visibility into system health with descriptive messaging * feat(middlewares): add metrics authentication middleware - Implement middleware to validate metrics token from request headers - Set up entity for metrics access if authentication is successful * refactor(queue): improve queue initialization logic and metrics handling - Rename and remove unnecessary metrics middleware from routes - Update Redis client configuration to allow unlimited retries per request - Enhance logging and setup checks for the queue system in relevant services * fix(workflows-service): correct alwaysApply setting in rules - Update alwaysApply to true for the workflows service rules - Ensure proper application of rules during service execution * update pnpm lock file --------- Co-authored-by: blokh <[email protected]> Co-authored-by: Sasha Mysak <[email protected]> Co-authored-by: Alon Peretz <[email protected]> Co-authored-by: Omer Harel <[email protected]>
1 parent 9baee0c commit 662cb8d

File tree

55 files changed

+2689
-573
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+2689
-573
lines changed

.cursor/rules/workflows-service.mdc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
description: Workflow Service Rules
33
globs: ["services/workflows-service/**/*.{ts}"]
4+
45
---
56
### Code Organization & Structure
67

.vscode/extensions.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"bradlc.vscode-tailwindcss",
99
"github.vscode-github-actions",
1010
"streetsidesoftware.code-spell-checker",
11-
"orta.vscode-jest"
11+
"orta.vscode-jest",
12+
"alefragnani.bookmarks"
1213
]
1314
}

.vscode/settings.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,7 @@
1313
"**/data-migrations": false
1414
},
1515
"search.followSymlinks": true,
16-
"search.useIgnoreFiles": false
16+
"search.useIgnoreFiles": false,
17+
"bookmarks.saveBookmarksInProject": true,
18+
"bookmarks.saveBookmarksInProjectFilePath": ".vscode/bookmarks.json"
1719
}

apps/backoffice-v2/src/pages/MerchantMonitoring/components/MerchantMonitoringReportStatus/fetchers.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { z } from 'zod';
2-
import { UpdateableReportStatus } from '@ballerine/common';
2+
import type { UpdateableReportStatus } from '@ballerine/common';
33

44
import { Method } from '@/common/enums';
55
import { apiClient } from '@/common/api-client/api-client';

deploy/.env

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,4 @@ VITE_KYB_DEFINITION_ID="kyb_parent_kyc_session_example"
5050

5151
##Workflow-Dashboard
5252
MODE=development
53-
VITE_IMAGE_LOGO_URL=
53+
VITE_IMAGE_LOGO_URL=

0 commit comments

Comments
 (0)