mbc-net/mbc-cqrs-serverless/mbc-migrate

Claude Code and agent skill by mbc-net/mbc-cqrs-serverless

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Guide version migrations for MBC CQRS Serverless framework. Use this when upgrading framework versions, migrating from deprecated APIs, or understanding breaking changes between versions.

Install

npx vskill@latest install mbc-net/mbc-cqrs-serverless/mbc-migrate

SKILL.md

Pre-flight Check (Version Update)

Before executing this skill, check for updates:

  1. Run mbc install-skills --check to check if a newer version is available
  2. If the output shows "Update available: X.Y.Z → A.B.C", ask the user:
  • "A newer version of MBC skills is available (X.Y.Z → A.B.C). Would you like to update before proceeding?"
  1. If the user agrees, run mbc install-skills --force to update
  2. If the user declines or skills are up-to-date, proceed with the skill

Note: Skip this check if the user explicitly says to skip updates or if you've already checked in this session.


MBC CQRS Serverless Migration Guide

This skill helps migrate MBC CQRS Serverless projects between versions.

Version Migration Matrix

From VersionTo VersionMigration ComplexityKey Changes
v1.0.16v1.0.17LowMasterDataService.search() fix
v1.0.17v1.0.18LowImportStatusHandler.sendTaskFailure()
v1.0.18v1.0.19LowImportQueueEventHandler error handling
v1.0.19v1.0.20LowCsvImportSfnEventHandler status fix
v1.0.20v1.0.21MediumZIP Finalization Hooks
v1.0.21v1.0.22LowDynamoDB export filter fix
v1.0.22v1.0.23LowsendInlineTemplateEmail()
v1.0.xv1.1.0HighTENANT_COMMON → lowercase; publish() removed
v1.1.xv1.1.4LowpublishSync audit trail (transparent)
v1.1.xv1.1.5MediumCSV import v2 batch architecture
v1.1.xv1.2.0HighpublishSync null return; genNewSequence() removed
v1.2.0v1.2.1LowSqsService added (new feature)
v1.2.1v1.2.2LowCsvBatchProcessor Poison Pill fix (transparent)
v1.2.xv1.2.4MediumTaskModule.register() must be in AppModule
v1.2.4v1.2.5LowZIP import refactor (transparent); MCP AP016–AP020 added
v1.2.5v1.2.6LowRepository RYW improvements (transparent); getVersion API
v1.2.7v1.3.0LowAppSync Events API support (opt-in, no breaking changes)
v1.3.0v1.3.1LowGroup-based roles (@GroupRoleResolver, custom:groups); UserContext.tenantRoles/tenantGroupIds added (opt-in, no breaking changes)
v1.3.2v1.3.3LowATTRIBUTE_LIMIT_SIZE default lowered 389120 → 102400 for Step Functions payload limit (transparent unless overridden)
v1.3.5v1.4.0LowConfigurable DynamoDB table names (opt-in) + registerAsync on domain modules; prismaService now always required; MasterModule+SettingModule shared-table alias warns
v1.4.0v1.5.0LowLocal dev only: LocalStack → Floci as the local S3 emulator; bucket CORS must be applied locally for presigned URLs (no application code changes)
v1.5.0v1.6.0MediumNode.js 22.23.4+ required (Node2Shell, CVE-2026-111497): runtime, Lambda (nodejs22.x), Docker and CI; nodemailer 10 types (only if you import nodemailer directly)
v1.6.0v1.7.0LowOpt-in atomic command admission (getCommandAdmissionConditions, CommandAdmissionRejectedException / CommandAdmissionContentionException); unit-test mocks of DynamoDbService used with the real CommandService need putItemWithConditions; dynamodb:ConditionCheckItem only if you adopt the hook
v1.7.0v1.8.0Mediummaster only, behaviour changes for every app using master: setting/data codes and user/group ids reject # and @ (400), rows stored with @ in their key can no longer be updated, deleted or read by getSetting; master copy fixes; POST /api/master-bulk upserts settings before data; opt-in controllerAuth, systemId + @MasterAccessResolver() (RDS system_id column + handler change, invokeContext required), MySQL search (databaseProvider)
v1.8.0v1.8.1MediumSecurity (cli template): app client may write only name (users could rewrite custom:roles); ECS task role gets Cognito admin actions; existing projects must edit infra-stack.ts and audit custom:roles / custom:tenant / custom:groups

Migration Guides

v1.0.16 → v1.0.17

Breaking Change: MasterDataService.search() settingCode behavior

Before (v1.0.16):

typescript
// settingCode was incorrectly using partial match
const results = await masterDataService.search({
settingCode: 'CONFIG', // Matched 'CONFIG', 'CONFIG_A', 'CONFIG_B'
});

After (v1.0.17):

typescript
// settingCode now uses exact match
const results = await masterDataService.search({
settingCode: 'CONFIG', // Only matches 'CONFIG' exactly
});

Migration Steps:

  1. Review all MasterDataService.search() calls
  2. If you relied on partial matching, update to explicit searches:

``typescript // If you need multiple settings const configs = await Promise.all([ masterDataService.search({ settingCode: 'CONFIG_A' }), masterDataService.search({ settingCode: 'CONFIG_B' }), ]); ``


v1.0.17 → v1.0.18

New Feature: ImportStatusHandler.sendTaskFailure()

Addition:

typescript
// New method available for explicit failure signaling
await importStatusHandler.sendTaskFailure({
taskToken: event.taskToken,
error: 'ValidationError',
cause: 'Invalid CSV format',
});

Migration Steps:

  1. No breaking changes
  2. Optional: Use sendTaskFailure() for better Step Functions integration

v1.0.18 → v1.0.19

Bug Fix: ImportQueueEventHandler error handling

Before (v1.0.18):

  • Parent job status not updated correctly on child failures

After (v1.0.19):

  • Parent job status properly reflects child job failures

Migration Steps:

  1. No code changes required
  2. Verify existing import workflows work correctly

v1.0.19 → v1.0.20

Bug Fix: CsvImportSfnEventHandler status determination

Before (v1.0.19):

  • Incorrect status when all rows failed

After (v1.0.20):

  • Correct FAILURE status when processedRows === 0

Migration Steps:

  1. No code changes required
  2. Review error handling in import workflows

v1.0.20 → v1.0.21

New Feature: ZIP Finalization Hooks

Addition:

typescript
// New interface for ZIP import finalization
interface IZipFinalizationHook {
afterFinalize(context: ZipFinalizationContext): Promise<void>;
}
// Module registration
@Module({
imports: [
ImportModule.register({
zipFinalizationHooks: [MyCustomFinalizationHook],
}),
],
})
export class AppModule {}

Migration Steps:

  1. No breaking changes
  2. Optional: Implement custom finalization hooks for post-import processing

Example Implementation:

typescript
@Injectable()
export class NotificationFinalizationHook implements IZipFinalizationHook {
constructor(private readonly notificationService: NotificationService) {}
async afterFinalize(context: ZipFinalizationContext): Promise<void> {
const { results, status } = context;
if (status === ImportStatusEnum.SUCCESS) {
await this.notificationService.sendSuccess({
message: `Import completed: ${results.processedRows} rows processed`,
});
} else {
await this.notificationService.sendFailure({
message: `Import failed: ${results.failedRows} rows failed`,
});
}
}
}

v1.0.21 → v1.0.22

Bug Fix: DynamoDB export S3 filter

Before (v1.0.21):

  • Export filter not applied correctly

After (v1.0.22):

  • S3 export filter works as expected

Migration Steps:

  1. No code changes required

v1.0.22 → v1.0.23

New Feature: sendInlineTemplateEmail()

Addition:

typescript
// New method for inline email templates
await notificationService.sendInlineTemplateEmail({
to: ['user@example.com'],
subject: 'Order Confirmation - {{orderId}}',
htmlBody: '<h1>Thank you for your order!</h1><p>Order ID: {{orderId}}</p>',
textBody: 'Thank you for your order! Order ID: {{orderId}}',
templateData: {
orderId: 'ORD-12345',
},
});

Migration Steps:

  1. No breaking changes
  2. Optional: Use inline templates instead of SES templates for simple emails


v1.1.0 — Breaking Changes (data migration required)

1. TENANT_COMMON renamed to lowercase

typescript
// Before (v1.0.x)
const pk = `MASTER_SETTING#COMMON#${settingCode}`
// After (v1.1.0+)
const pk = `MASTER_SETTING#common#${settingCode}`
  • All DynamoDB keys using #COMMON must be migrated to #common
  • New utilities: normalizeTenantCode(), isCommonTenant()

2. `publish()` and `publishPartialUpdate()` removed

typescript
// Removed — compilation error in v1.1.0+
this.commandService.publish(...)
this.commandService.publishPartialUpdate(...)
// Use instead
this.commandService.publishAsync(...)
this.commandService.publishPartialUpdateAsync(...)

v1.1.4 — publishSync audit trail (no code changes required)

publishSync now writes a full audit trail to Command and History tables (parity with async pipeline). No migration required; behavior is transparent.


v1.1.5 — CSV Import v2 batch architecture

Step Functions state machine changes required:

  • finalize_parent_job state is now required
  • Row-level progress tracking via import_tmp table is removed
  • Counters (processedRows, succeededRows, failedRows) are aggregated at completion

v1.2.0 — Breaking Changes

1. publishSync / publishPartialUpdateSync return type change

typescript
// Before (v1.1.x) — always returned CommandModel
const result = await commandService.publishSync(entity, options)
console.log(result.pk) // safe
// After (v1.2.0+) — returns null when command is not dirty (no-op)
const result = await commandService.publishSync(entity, options)
if (!result) return // no-op
console.log(result.pk) // safe after null check

2. SequenceService.genNewSequence() removed

typescript
// Removed — compilation error in v1.2.0+
await sequenceService.genNewSequence(...)
// Use instead
await sequenceService.generateSequenceItem(...)
// or
await sequenceService.generateSequenceItemWithProvideSetting(...)

3. Read-Your-Writes (RYW) consistency (new optional feature)

typescript
import { DetailKey, Repository } from '@mbc-cqrs-serverless/core'
// Enable: set RYW_SESSION_TTL_MINUTES env var (e.g. "5")
// Session table {NODE_ENV}-{APP_NAME}-session must be created
// No effect if unset — zero impact on existing projects

v1.2.2 — Bug fixes (no code changes required)
  • CsvBatchProcessor Poison Pill fix: Per-row try/catch now prevents Head-of-Line Blocking in SQS batches
  • ImportQueueEventHandler: singleImportProcessor.process() now receives event.importEvent instead of event.payload

Both fixes are transparent — no migration steps needed.


v1.2.4 — TaskModule global registration

Breaking for apps using `@mbc-cqrs-serverless/master`

TaskModule.register() is now global (global: true) and must be called exactly once in the host AppModule. MasterModule no longer registers TaskModule internally.

typescript
// Before (v1.2.3 and earlier) — worked automatically
@Module({
imports: [MasterModule.register({ enableController: true, prismaService: PrismaService })],
})
export class AppModule {}
// After (v1.2.4+) — must register explicitly
import { TaskModule, TaskQueueEventFactory } from '@mbc-cqrs-serverless/master'
@Module({
imports: [
TaskModule.register({ taskQueueEventFactory: MyTaskQueueEventFactory }),
MasterModule.register({ enableController: true, prismaService: PrismaService }),
],
})
export class AppModule {}

Migration steps:

  1. Create a factory extending TaskQueueEventFactory from @mbc-cqrs-serverless/master
  2. Call TaskModule.register() once in AppModule
  3. Remove TaskModule.register() from all feature modules

Symptom if skipped: App crashes at startup with Nest can't resolve dependencies of MyTaskService (?).


This is the start of the file. Read the full SKILL.md on GitHub.

Security

  • Security scanPassed, 95 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

Repository stars
30
Repository forks
6
7-day trend score
17

Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 21 Mar 2026, 8 months ago.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/mbc-net/mbc-cqrs-serverless/mbc-migrate/badge)](https://verified-skill.com/skills/mbc-net/mbc-cqrs-serverless/mbc-migrate)

Something wrong with this skill or its page? Tell us.