updating internal dependencies
This commit is contained in:
parent
fe7d948fd1
commit
64c5a3690a
File diff suppressed because it is too large
Load Diff
|
@ -40,8 +40,8 @@
|
||||||
"@grpc/grpc-js": "^1.8.14",
|
"@grpc/grpc-js": "^1.8.14",
|
||||||
"@grpc/proto-loader": "^0.7.6",
|
"@grpc/proto-loader": "^0.7.6",
|
||||||
"@liaoliaots/nestjs-redis": "^9.0.5",
|
"@liaoliaots/nestjs-redis": "^9.0.5",
|
||||||
"@mobicoop/configuration-module": "^1.1.0",
|
"@mobicoop/configuration-module": "^1.2.0",
|
||||||
"@mobicoop/message-broker-module": "^1.0.5",
|
"@mobicoop/message-broker-module": "^1.2.0",
|
||||||
"@nestjs/common": "^9.0.0",
|
"@nestjs/common": "^9.0.0",
|
||||||
"@nestjs/config": "^2.3.1",
|
"@nestjs/config": "^2.3.1",
|
||||||
"@nestjs/core": "^9.0.0",
|
"@nestjs/core": "^9.0.0",
|
||||||
|
|
|
@ -17,8 +17,7 @@ import {
|
||||||
imports: [
|
imports: [
|
||||||
ConfigModule.forRoot({ isGlobal: true }),
|
ConfigModule.forRoot({ isGlobal: true }),
|
||||||
AutomapperModule.forRoot({ strategyInitializer: classes() }),
|
AutomapperModule.forRoot({ strategyInitializer: classes() }),
|
||||||
MessageBrokerModule.forRootAsync(
|
MessageBrokerModule.forRootAsync({
|
||||||
{
|
|
||||||
imports: [ConfigModule],
|
imports: [ConfigModule],
|
||||||
inject: [ConfigService],
|
inject: [ConfigService],
|
||||||
useFactory: async (
|
useFactory: async (
|
||||||
|
@ -26,12 +25,10 @@ import {
|
||||||
): Promise<MessageBrokerModuleOptions> => ({
|
): Promise<MessageBrokerModuleOptions> => ({
|
||||||
uri: configService.get<string>('MESSAGE_BROKER_URI'),
|
uri: configService.get<string>('MESSAGE_BROKER_URI'),
|
||||||
exchange: configService.get<string>('MESSAGE_BROKER_EXCHANGE'),
|
exchange: configService.get<string>('MESSAGE_BROKER_EXCHANGE'),
|
||||||
|
name: 'ad',
|
||||||
}),
|
}),
|
||||||
},
|
}),
|
||||||
false,
|
ConfigurationModule.forRootAsync({
|
||||||
),
|
|
||||||
ConfigurationModule.forRootAsync(
|
|
||||||
{
|
|
||||||
imports: [ConfigModule],
|
imports: [ConfigModule],
|
||||||
inject: [ConfigService],
|
inject: [ConfigService],
|
||||||
useFactory: async (
|
useFactory: async (
|
||||||
|
@ -47,19 +44,13 @@ import {
|
||||||
password: configService.get<string>('REDIS_PASSWORD'),
|
password: configService.get<string>('REDIS_PASSWORD'),
|
||||||
port: configService.get<number>('REDIS_PORT'),
|
port: configService.get<number>('REDIS_PORT'),
|
||||||
},
|
},
|
||||||
setConfigurationBrokerRoutingKeys: [
|
|
||||||
'configuration.create',
|
|
||||||
'configuration.update',
|
|
||||||
],
|
|
||||||
deleteConfigurationRoutingKey: 'configuration.delete',
|
|
||||||
propagateConfigurationRoutingKey: 'configuration.propagate',
|
propagateConfigurationRoutingKey: 'configuration.propagate',
|
||||||
setConfigurationBrokerQueue: 'ad-configuration-create-update',
|
setConfigurationBrokerQueue: 'ad-configuration-create-update',
|
||||||
deleteConfigurationQueue: 'ad-configuration-delete',
|
deleteConfigurationQueue: 'ad-configuration-delete',
|
||||||
propagateConfigurationQueue: 'ad-configuration-propagate',
|
propagateConfigurationQueue: 'ad-configuration-propagate',
|
||||||
}),
|
}),
|
||||||
},
|
}),
|
||||||
true,
|
|
||||||
),
|
|
||||||
HealthModule,
|
HealthModule,
|
||||||
AdModule,
|
AdModule,
|
||||||
],
|
],
|
||||||
|
|
|
@ -41,6 +41,7 @@ export class AdController {
|
||||||
|
|
||||||
@GrpcMethod('AdsService', 'Create')
|
@GrpcMethod('AdsService', 'Create')
|
||||||
async createAd(data: CreateAdRequest): Promise<AdPresenter> {
|
async createAd(data: CreateAdRequest): Promise<AdPresenter> {
|
||||||
|
console.log('call');
|
||||||
try {
|
try {
|
||||||
const ad = await this.commandBus.execute(new CreateAdCommand(data));
|
const ad = await this.commandBus.execute(new CreateAdCommand(data));
|
||||||
return this.mapper.map(ad, Ad, AdPresenter);
|
return this.mapper.map(ad, Ad, AdPresenter);
|
||||||
|
|
Loading…
Reference in New Issue