Package com.sequenceiq.cloudbreak.service.stack.event

Examples of com.sequenceiq.cloudbreak.service.stack.event.ProvisionComplete


            stack = stackUpdater.updateStackCreateComplete(stack.getId());
            LOGGER.info("CloudFormation stack creation completed.");
            LOGGER.info("Publishing {} event.", ReactorConfig.PROVISION_COMPLETE_EVENT);
            Set<Resource> resourceSet = new HashSet<>();
            resourceSet.add(new Resource(ResourceType.CLOUDFORMATION_STACK, cfMessage.get("StackName"), stack));
            reactor.notify(ReactorConfig.PROVISION_COMPLETE_EVENT, Event.wrap(new ProvisionComplete(CloudPlatform.AWS, stack.getId(), resourceSet)));
        }
    }
View Full Code Here


                    if (exception != null) {
                        throw new BuildStackFailureException(exception.getMessage(), exception, resourceSet);
                    }

                    LOGGER.info("Publishing {} event [StackId: '{}']", ReactorConfig.PROVISION_COMPLETE_EVENT, stack.getId());
                    reactor.notify(ReactorConfig.PROVISION_COMPLETE_EVENT, Event.wrap(new ProvisionComplete(cloudPlatform, stack.getId(), resourceSet)));
                } else {
                    CloudPlatformConnector cloudPlatformConnector = cloudPlatformConnectors.get(cloudPlatform);
                    cloudPlatformConnector.buildStack(stack, userDataBuilder.build(cloudPlatform, stack.getHash(), userDataParams), setupProperties);
                }
            } else {
View Full Code Here

        verify(cloudbreakEventService, times(1)).fireCloudbreakEvent(anyLong(), anyString(), anyString());
    }


    private Event<ProvisionComplete> createEvent() {
        return new Event<>(new ProvisionComplete(CloudPlatform.AWS, 1L, resourceSet));
    }
View Full Code Here

    @Autowired
    private CloudbreakEventService cloudbreakEventService;

    @Override
    public void accept(Event<ProvisionComplete> event) {
        ProvisionComplete stackCreateComplete = event.getData();
        CloudPlatform cloudPlatform = stackCreateComplete.getCloudPlatform();
        Long stackId = stackCreateComplete.getStackId();
        Stack stack = stackRepository.findById(stackId);
        MDCBuilder.buildMdcContext(stack);
        LOGGER.info("Accepted {} event on stack.", ReactorConfig.PROVISION_COMPLETE_EVENT);
        Set<Resource> resourcesSet = event.getData().getResources();
        retryingStackUpdater.updateStackResources(stackId, resourcesSet);
View Full Code Here

TOP

Related Classes of com.sequenceiq.cloudbreak.service.stack.event.ProvisionComplete

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.