Open gocandra opened 2 years ago
so the issue seems to be that
import { RedisTransport, RedisTransportConfiguration } from '@node-ts/bus-redis'
RedisTransport does not seem to be exported. i've cloned the new project at https://github.com/node-ts/bus.git
but redis is not there, i'll try and add it myself and see if i can get it going.
where can i find the package @node-ts/bus-test?
i'm trying to connect to redis but i keep hitting this error message:
TypeError: Cannot read property 'sadd' of undefined at /bus-starter/node_modules/@node-ts/bus-redis/dist/redis-transport.js:101:40
here is how i'm using it `import { Container } from 'inversify' import { BusModule } from '@node-ts/bus-core' import { LoggerModule } from '@node-ts/logger-core' import { WinstonModule } from '@node-ts/logger-winston' import { HandlersModule } from './handlers/handlers-module' import { BusWorkflowModule } from '@node-ts/bus-workflow' import { BUS_REDIS_SYMBOLS, BusRedisModule, RedisTransportConfiguration } from '@node-ts/bus-redis' import { BUS_POSTGRES_SYMBOLS, BusPostgresModule, PostgresConfiguration } from '@node-ts/bus-postgres'
const redisConfiguration: RedisTransportConfiguration = { queueName: 'accounts-application-queue', connectionString: 'redis://127.0.0.1:6379', maxRetries: 3, }
const postgresConfiguration: PostgresConfiguration = { connection: { connectionString: 'postgres://xxxxxxxxxxxxxxxxxxxx/postgres' }, schemaName: 'workflows' }
const container = new Container() container.load(new LoggerModule()) container.load(new BusModule()) container.load(new WinstonModule()) container.load(new BusWorkflowModule()) container.load(new HandlersModule()) container.load(new BusRedisModule()) container.load(new BusPostgresModule())
container .bind(BUS_REDIS_SYMBOLS.TransportConfiguration) .toConstantValue(redisConfiguration)
container .bind(BUS_POSTGRES_SYMBOLS.PostgresConfiguration) .toConstantValue(postgresConfiguration)
export default container`
what am i doing wrong? I can connect to the redis instance, and it works for a bullmq implementation i have laying around. any guidance is appreciated!