public virtual async Task DeleteRouteConfigAsync(AggregateReRouteConfigGetByKeyInputDto input)
        {
            var routeId        = long.Parse(input.RouteId);
            var aggregateRoute = await _aggregateReRouteRepository.GetByRouteIdAsync(routeId);

            aggregateRoute.RemoveReRouteConfig(input.ReRouteKey);

            await _aggregateReRouteRepository.UpdateAsync(aggregateRoute);

            await DistributedEventBus.PublishAsync(new ApigatewayConfigChangeEventData(aggregateRoute.AppId, "AggregateRoute", "DeleteRouteConfig"));
        }
Esempio n. 2
0
        public virtual async Task DeleteRouteConfigAsync(AggregateReRouteConfigGetByKeyInputDto aggregateReRouteConfigGetByKey)
        {
            var routeId        = long.Parse(aggregateReRouteConfigGetByKey.RouteId);
            var aggregateRoute = await _aggregateReRouteRepository.GetByRouteIdAsync(routeId);

            aggregateRoute.RemoveReRouteConfig(aggregateReRouteConfigGetByKey.ReRouteKey);

            await _aggregateReRouteRepository.UpdateAsync(aggregateRoute);

            await _eventPublisher.PublishAsync(ApigatewayConfigChangeCommand.EventName,
                                               new ApigatewayConfigChangeCommand("AggregateRoute", "DeleteRouteConfig"));
        }
Esempio n. 3
0
 public async Task DeleteRouteConfigAsync(AggregateReRouteConfigGetByKeyInputDto aggregateReRouteConfigGetByKey)
 {
     await AggregateReRouteAppService.DeleteRouteConfigAsync(aggregateReRouteConfigGetByKey);
 }