Class AlfrescoEventsAutoConfiguration


  • @Configuration
    @AutoConfigureAfter({org.springframework.boot.autoconfigure.integration.IntegrationAutoConfiguration.class,org.springframework.boot.autoconfigure.jms.activemq.ActiveMQAutoConfiguration.class,org.springframework.boot.autoconfigure.jms.JmsAutoConfiguration.class})
    @ConditionalOnClass(org.alfresco.event.sdk.model.v1.model.RepoEvent.class)
    @EnableConfigurationProperties(AlfrescoEventsProperties.class)
    public class AlfrescoEventsAutoConfiguration
    extends Object
    Auto-configuration for Alfresco Event Java API.

    This auto-configuration defines the beans required to read the Alfresco JSON events from an ActiveMQ topic, transform that event from JSON to RepoEvent making use of the EventGenericTransformer and do up to two things:

    • Forward a Spring Integration Message to a publish-subscribe channel
    • Invoke the list of EventHandler registered to handle the specific event type consumed from the topic

    This way the integrator can configure the Alfresco Java Event API to consume the events using Spring Integration or plain Java event handlers.

    • Constructor Detail

      • AlfrescoEventsAutoConfiguration

        public AlfrescoEventsAutoConfiguration()
    • Method Detail

      • acsEventsListeningFlow

        @Bean
        public org.springframework.integration.dsl.IntegrationFlow acsEventsListeningFlow​(org.apache.activemq.ActiveMQConnectionFactory activeMQConnectionFactory)
      • acsEventsTopic

        @Bean
        public javax.jms.Topic acsEventsTopic()
      • acsEventErrorChannel

        @Bean(name="alfresco.events.error.channel")
        public org.springframework.integration.channel.DirectChannel acsEventErrorChannel()
      • acsEventObjectMapper

        @Bean
        public com.fasterxml.jackson.databind.ObjectMapper acsEventObjectMapper()
      • acsEventsSpringIntegrationFlow

        @Bean
        public org.springframework.integration.dsl.IntegrationFlow acsEventsSpringIntegrationFlow()
      • acsEventChannel

        @Bean(name="alfresco.events.main.channel")
        public org.springframework.integration.channel.PublishSubscribeChannel acsEventChannel()
      • acsEventsHandlersFlow

        @Bean
        public org.springframework.integration.dsl.IntegrationFlow acsEventsHandlersFlow()