| Node.js Version | ABI Version (NODE_MODULE_VERSION) |
|---|---|
| 16.x | 93 |
| 18.x | 108 |
| 20.x | 115 |
| 21.x | 124 |
| 22.x | 131 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: "3.8" | |
| services: | |
| kafka: | |
| image: apache/kafka:4.0.1-rc2 | |
| container_name: kafka | |
| ports: | |
| - "9092:9092" | |
| environment: | |
| CLUSTER_ID: mkqv8X5vRla7PzR8bKqfHk |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: '3.8' | |
| services: | |
| elasticsearch: | |
| image: docker.elastic.co/elasticsearch/elasticsearch:9.0.3 | |
| container_name: elasticsearch | |
| environment: | |
| - node.name=es-node | |
| - discovery.type=single-node | |
| - cluster.name=es-cluster |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export function setupProcessHandlers(options?: { | |
| exitOnError?: boolean; | |
| onError?: (type: 'uncaughtException' | 'unhandledRejection', error: any) => void; | |
| }) { | |
| const exit = options?.exitOnError ?? true; | |
| const onError = options?.onError; | |
| process.on('uncaughtException', (err) => { | |
| console.error('[🔥 Uncaught Exception]:', err); | |
| onError?.('uncaughtException', err); |
| ✅ Do | ❌ Don’t |
|---|---|
| Log full stack traces and context (request IDs, payloads, etc.) | Continue running as if nothing happened |
| Report to external error‑tracking services (Sentry, Datadog, etc.) | Swallow errors or leave handlers empty |
| Gracefully shut down: close DB, stop accepting new requests | Call process.exit(0) (signals success) |
| Use a supervisor (e.g., PM2, Docker restart policy) | Believe you can recover 100% safely in‑process |
Convert unhandled rejections into exceptions (throw reason) |
Ignore Node.js v15+ default behavior—explicit is better |
| Label | Threshold | Action |
|---|---|---|
| Adult Nudity | >90% | Reject |
| Violence | >80% | Quarantine |
| Self-Harm | >70% | Manual Review |
| Feature | jose |
jsonwebtoken |
|---|---|---|
| TypeScript Support | ✅ Native | ☑️ Partial |
| ESM Support | ✅ Yes | ❌ No |
| Browser Compatibility | ✅ Yes | ❌ No |
| Algorithm Support | ✅ Broad (EdDSA, ES, PS, etc.) | |
| Maintenance | ✅ Active (Panva) | 💤 Slow |
| Crypto Security | ✅ Uses native Web Crypto API | |
| API Style | ✅ Promise-based, functional | ❌ Callback/Sync |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { unwrap } from "#app/config/db/global"; | |
| import { rawRedis, redis } from "#app/config/db/redis/redis.config"; | |
| import type { Request } from "express"; | |
| import type { RedisKey } from "ioredis"; | |
| import hash from "object-hash"; | |
| import type { RedisSetOptions } from "#app/config/db/redis/types"; | |
| import type { CommandResult } from "#app/config/db/global"; | |
| import { logger } from "#app/common/utils/logger.util"; | |
| function buildRedisSetArgs(options: RedisSetOptions): (string | number)[] { |
🧪 Email Testing Tools (Dev & QA)
| Tool | Type | Description |
|---|---|---|
| MailHog | Self-hosted | Open-source email testing tool for local dev. Provides a local SMTP + UI. |
| Mailtrap | Cloud | Cloud-based service for capturing and inspecting emails. Great UI & team features. |
| Papercut SMTP | Self-hosted | Windows-friendly, lightweight desktop email testing tool. |
| FakeSMTP | Self-hosted | Java-based email testing server with GUI. Captures SMTP traffic. |
| MailCatcher | Self-hosted | Ruby-based local email testing with web UI. Simple and effective. |
| Ethereal Email | Cloud | Free fake SMTP service by Nodemailer. No real delivery — inspect via URL. |
NewerOlder