How to use the @node-ts/bus-workflow.BUS_WORKFLOW_SYMBOLS.WorkflowRegistry function in @node-ts/bus-workflow

To help you get started, we’ve selected a few @node-ts/bus-workflow examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github node-ts / bus-starter / src / index.ts View on Github external
async function initialize (): Promise {
  const workflowRegistry = container.get(BUS_WORKFLOW_SYMBOLS.WorkflowRegistry)
  workflowRegistry.register(SirenTestWorkflow, SirenTestWorkflowData)
  await workflowRegistry.initializeWorkflows()

  const bootstrap = container.get(BUS_SYMBOLS.ApplicationBootstrap)
  bootstrap.registerHandler(StartSirenTestHandler)
  bootstrap.registerHandler(EmailMaintenanceTeamHandler)

  await bootstrap.initialize(container)
}
github node-ts / bus / packages / bus-postgres / src / postgres-persistence.integration.ts View on Github external
beforeAll(async () => {
    container = new TestContainer()
    container.bind(BUS_POSTGRES_SYMBOLS.PostgresConfiguration).toConstantValue(configuration)
    bus = container.get(BUS_SYMBOLS.Bus)
    sut = container.get(BUS_WORKFLOW_SYMBOLS.Persistence)
    postgres = container.get(BUS_POSTGRES_INTERNAL_SYMBOLS.PostgresPool)

    workflows = container.get(BUS_WORKFLOW_SYMBOLS.WorkflowRegistry)
    workflows.register(TestWorkflow, TestWorkflowData)
    await workflows.initializeWorkflows()

    bootstrap = container.get(BUS_SYMBOLS.ApplicationBootstrap)
    await bootstrap.initialize(container)
  })