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

Fixed PostgreSQL transport example #55

Merged
merged 1 commit into from
Mar 1, 2020
Merged
Changes from all commits
Commits
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
12 changes: 6 additions & 6 deletions packages/bus-postgres/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ Once installed, load the `BusPostgresModiule` to your inversify container alongs
```typescript
import { Container } from 'inversify'
import { LoggerModule } from '@node-ts/logger-core'
import { BusModule } from '@node-ts/bus-core'
import { WorkflowModule } from '@node-ts/bus-workflow'
import { BUS_POSTGRES_SYMBOLS, BusPostgresModule } from '@node-ts/bus-postgres'
import { BUS_SYMBOLS, BusModule, ApplicationBootstrap } from '@node-ts/bus-core'
import { BUS_WORKFLOW_SYMBOLS, WorkflowRegistry } from '@node-ts/bus-workflow'
import { BUS_POSTGRES_SYMBOLS, BusPostgresModule, PostgresConfiguration } from '@node-ts/bus-postgres'

const container = new Container()
container.load(new LoggerModule())
Expand All @@ -37,11 +37,11 @@ container.bind(BUS_POSTGRES_SYMBOLS.PostgresConfiguration).toConstantValue(confi

// Run the application
const application = async () => {
workflows = container.get<WorkflowRegistry>(BUS_WORKFLOW_SYMBOLS.WorkflowRegistry)
const workflows = container.get<WorkflowRegistry>(BUS_WORKFLOW_SYMBOLS.WorkflowRegistry)
workflows.register(TestWorkflow, TestWorkflowData) // Register all workflows here
await workflows.initializeWorkflows()

bootstrap = container.get<ApplicationBootstrap>(BUS_SYMBOLS.ApplicationBootstrap)
const bootstrap = container.get<ApplicationBootstrap>(BUS_SYMBOLS.ApplicationBootstrap)
await bootstrap.initialize(container)
}
application
Expand All @@ -54,4 +54,4 @@ Local development can be done with the aid of docker to run the required infrast

```bash
docker run --name bus-postgres -e POSTGRES_PASSWORD=password -p 5432:5432 -d postgres
```
```