Class DareApplication


  • @EnableAutoConfiguration
    @SpringBootConfiguration
    @EnableTransactionManagement
    @EntityScan(basePackages={"org.marketcetera","com.marketcetera"})
    @SpringBootApplication(scanBasePackages={"org.marketcetera","com.marketcetera"})
    @EnableJpaRepositories(basePackages={"org.marketcetera","com.marketcetera"})
    public class DareApplication
    extends Object
    Application entry point for the community DARE application.
    Since:
    $Release$
    Version:
    $Id$
    Author:
    Colin DuPlantis
    • Field Detail

      • useSsl

        @Value("${metc.security.use.ssl:false}")
        private boolean useSsl
        indicates whether to use SSL or not
      • publicKeyPath

        @Value("${metc.security.ssl.public.key.path:#{null}}")
        private String publicKeyPath
        public key path for SSL cert
      • privateKeyPath

        @Value("${metc.security.ssl.private.key.path:#{null}}")
        private String privateKeyPath
        private key path for SSL cert
      • webServerPort

        @Value("${server.port}")
        private int webServerPort
        web services port
      • serverHostname

        @Value("${metc.ws.hostname:0.0.0.0}")
        private String serverHostname
        server hostname
      • rpcPort

        @Value("${metc.rpc.port}")
        private int rpcPort
        RPC services port
      • metricServiceLogReporterInterval

        @Value("${metc.metric.service.log.reporter.interval:10}")
        private int metricServiceLogReporterInterval
        interval at which to report metrics
      • contextPathClasses

        @Value("${metc.xml.context.path.classes}")
        private List<String> contextPathClasses
        context path classes used to marshal and unmarshal XML values
      • provisioningDirectory

        @Value("${metc.provisioning.directory:./instances/provisioning}")
        private String provisioningDirectory
        provisioning directory base
    • Constructor Detail

      • DareApplication

        public DareApplication()
    • Method Detail

      • main

        public static void main​(String[] inArgs)
        Main application entry.
        Parameters:
        inArgs - a String[] value
      • start

        @PostConstruct
        public void start()
        Validate and start the object.
      • getPasswordService

        @Bean
        public PasswordService getPasswordService()
        Get the password service value.
        Returns:
        a PasswordService value
      • getStrategyService

        @Bean
        public StrategyService getStrategyService()
        Get the strategy service bean.
        Returns:
        a StrategyService value
      • getProvisioningAgent

        @Bean
        public ProvisioningAgent getProvisioningAgent()
        Get the provisioning agent bean.
        Returns:
        a ProvisioningAgent value
      • getStrategyClientFactory

        @Bean
        public DirectStrategyClientFactory getStrategyClientFactory()
        Get the strategy client factory value.
        Returns:
        a DirectStrategyClientFactory value
      • getMarketDataClient

        @Bean
        public DirectMarketDataClient getMarketDataClient()
        Get the market data client value.
        Returns:
        a DirectMarketDataClient value
      • getTradeClient

        @Bean
        public DirectTradeClient getTradeClient()
        Get the trade client value.
        Returns:
        a DirectTradeClient value
      • getStrategyMessageFactory

        @Bean
        public PersistentStrategyMessageFactory getStrategyMessageFactory()
        Get the strategy message factory value.
        Returns:
        a PersistentStrategyMessageFactory value
      • getStrategyInstanceFactory

        @Bean
        public PersistentStrategyInstanceFactory getStrategyInstanceFactory()
        Get the strategy instance factory value.
        Returns:
        a StrategyInstanceFactory value
      • getAverageFillPriceFactory

        @Bean
        public AverageFillPriceFactory getAverageFillPriceFactory()
        Get the average fill price factory value.
        Returns:
        an AverageFillPriceFactory value
      • getMessageStoreConfiguration

        @Bean
        public HibernateMessageStoreConfiguration getMessageStoreConfiguration()
        Get the message store configuration value.
        Returns:
        a HibernateMessageStoreConfiguration value
      • getUserService

        @Bean
        public UserService getUserService()
        Get the user service bean.
        Returns:
        a UserService value
      • getFixSessionProvider

        @Bean
        public FixSessionProvider getFixSessionProvider()
        Get the FIX session provider bean.
        Returns:
        a FixSessionProvider value
      • getMessageFactory

        @Bean
        public quickfix.MessageFactory getMessageFactory()
        Get the message factory bean.
        Returns:
        a quickfix.MessageFactory value
      • getClusterDataFactory

        @Bean
        public ClusterDataFactory getClusterDataFactory()
        Get the cluster data factory bean.
        Returns:
        a ClusterDataFactory value
      • getMutableFixSessionFactory

        @Bean
        public MutableFixSessionFactory getMutableFixSessionFactory()
        Get the mutable FIX session factory bean.
        Returns:
        a MutableFixSessionFactory value
      • getMutableActiveFixSessionFactory

        @Bean
        public MutableActiveFixSessionFactory getMutableActiveFixSessionFactory()
        Get the mutable active FIX session factory bean.
        Returns:
        a MutableActiveFixSessionFactory value
      • getServerFixSessionFactory

        @Bean
        public ServerFixSessionFactory getServerFixSessionFactory()
        Get the server FIX session factory bean.
        Returns:
        a ServerFixSessionFactory value
      • getMessageOwnerService

        @Bean
        public MessageOwnerService getMessageOwnerService()
        Get the message owner service value.
        Returns:
        a MessageOwnerService value
      • getQuickFixSender

        @Bean
        public QuickFIXSender getQuickFixSender()
        Get the QFJ sender implementation for DARE.
        Returns:
        a QuickFIXSender value
      • getMetricServiceReporter

        @Bean
        public MetricServiceDbReporter getMetricServiceReporter()
        Get the metric service reporter value.
        Returns:
        a MetricServiceDbReporter value
      • api

        @Bean
        public springfox.documentation.spring.web.plugins.Docket api()
        Create the Swagger API component.
        Returns:
        a Docket value
      • getEmbeddedWebServerPortUserProxy

        @Bean
        public org.marketcetera.util.ws.stateful.PortUserProxy getEmbeddedWebServerPortUserProxy()
        Get the port user proxy for the embedded web server.
        Returns:
        a PortUserProxy value
      • getRpcServer

        @Bean
        public org.marketcetera.rpc.server.RpcServer getRpcServer​(@Autowired(required=false)
                                                                  List<io.grpc.BindableService> inServiceSpecs)
                                                           throws Exception
        Get the RPC server value.
        Parameters:
        inServiceSpecs - a List<BindableService> value
        Returns:
        an RpcServer value
        Throws:
        Exception - if the server cannot be created
      • getAdminRpcService

        @Bean
        public AdminRpcService<javax.jms.ServerSession> getAdminRpcService​(@Autowired
                                                                           org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                           @Autowired
                                                                           org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the admin RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        an AdminRpcService<ServerSession> value
      • getTradeRpcService

        @Bean
        public TradeRpcService<javax.jms.ServerSession> getTradeRpcService​(@Autowired
                                                                           org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                           @Autowired
                                                                           org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Trade RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        a TradeRpcService<ServerSession> value
      • getStrategyRpcService

        @Bean
        public StrategyRpcServer<javax.jms.ServerSession> getStrategyRpcService​(@Autowired
                                                                                org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                                @Autowired
                                                                                org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Strategy RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionbManager<ServerSession> value
        Returns:
        a TradeRpcService<ServerSession> value
      • getFixAdminRpcService

        @Bean
        public FixAdminRpcService<javax.jms.ServerSession> getFixAdminRpcService​(@Autowired
                                                                                 org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                                 @Autowired
                                                                                 org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Fix Admin RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        a FixAdminRpcService<ServerSession> value
      • getDataFlowRpcService

        @Bean
        public DataFlowRpcService<javax.jms.ServerSession> getDataFlowRpcService​(@Autowired
                                                                                 org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                                 @Autowired
                                                                                 org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Data Flow RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        a DataFlowRpcService<ServerSession> value
      • getMarketDataRpcService

        @Bean
        public MarketDataRpcService<javax.jms.ServerSession> getMarketDataRpcService​(@Autowired
                                                                                     org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                                     @Autowired
                                                                                     org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Market Data RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        a MarketDataRpcService<ServerSession> value
      • getClusterRpcService

        @Bean
        public ClusterRpcService<javax.jms.ServerSession> getClusterRpcService​(@Autowired
                                                                               org.marketcetera.util.ws.stateful.Authenticator inAuthenticator,
                                                                               @Autowired
                                                                               org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> inSessionManager)
        Get the Cluster RPC service.
        Parameters:
        inAuthenticator - an Authenticator value
        inSessionManager - a SessionManager<ServerSession> value
        Returns:
        a ClusterRpcService<ServerSession> value
      • getModuleManager

        @Bean
        public ModuleManager getModuleManager()
        Get the module manager value.
        Returns:
        a ModuleManager value
      • getSymbolResolverService

        @Bean
        public SymbolResolverService getSymbolResolverService()
        Get the symbol resolver service value.
        Returns:
        a SymbolResolverService value
      • getAuthenticator

        @Bean
        public org.marketcetera.util.ws.stateful.Authenticator getAuthenticator()
        Get the authenticator service.
        Returns:
        an Authenticator value
      • getSessionManager

        @Bean
        public org.marketcetera.util.ws.stateful.SessionManager<javax.jms.ServerSession> getSessionManager()
        Get the session manager service.
        Returns:
        a SessionManager<ServerSession> value
      • getUserAttributeFactory

        @Bean
        public UserAttributeFactory getUserAttributeFactory()
        Get the user attribute factory value.
        Returns:
        a UserAttribute value
      • getUserAttributeService

        @Bean
        public UserAttributeService getUserAttributeService()
        Get the user attribute service value.
        Returns:
        a UserAttributeService value
      • getBrokerSelector

        @Bean
        public BrokerSelector getBrokerSelector()
        Get the default broker selector to use.
        Returns:
        a Selector value
      • getOrderConverterConnector

        @Bean
        public OrderConverterConnector getOrderConverterConnector()
        Get the order converter connector value.
        Returns:
        an OrderConverterConnector value
      • getOutgoingMessageCachingConnector

        @Bean
        public OutgoingMessageCachingConnector getOutgoingMessageCachingConnector()
        Get the outgoing message caching connector value.
        Returns:
        an OutgoingMessageCachingConnector value
      • getOutgoingMessagePersistenceConnector

        @Bean
        public OutgoingMessagePersistenceConnector getOutgoingMessagePersistenceConnector()
        Get the outgoing message persistence connector value.
        Returns:
        an OutgoingMessagePersistenceConnector value
      • getIncomingTradeMessageConverterConnector

        @Bean
        public IncomingTradeMessageConverterConnector getIncomingTradeMessageConverterConnector()
        Get the incoming trade message converter connector value.
        Returns:
        an IncomingTradeMessageConverterConnector value
      • getIncomingTradeMessagePersistenceConnector

        @Bean
        public IncomingTradeMessagePersistenceConnector getIncomingTradeMessagePersistenceConnector()
        Get the incoming trade message persistence connector value.
        Returns:
        an IncomingTradeMessagePersistenceConnector value
      • getIncomingTradeMessageBroadcastConnector

        @Bean
        public IncomingTradeMessageBroadcastConnector getIncomingTradeMessageBroadcastConnector()
        Get the IncomingTradeMessageBroadcastConnector value.
        Returns:
        an IncomingTradeMessageBroadcastConnector value
      • getEsperEngine

        @Bean
        public EsperEngine getEsperEngine()
        Get the Esper engine value.
        Returns:
        an EsperEngine value
      • getEventBusEsperConnector

        @Bean
        public EventBusEsperConnector getEventBusEsperConnector()
        Get the Event Bus <-> Esper connector value.
        Returns:
        an EventBusEsperConnector value
      • getPermissionFactory

        @Bean
        public PermissionFactory getPermissionFactory()
        Get the permission factory value.
        Returns:
        a PermissionFactory value
      • getRoleFactory

        @Bean
        public RoleFactory getRoleFactory()
        Get the role factory value.
        Returns:
        a RoleFactory value
      • getUserFactory

        @Bean
        public UserFactory getUserFactory()
        Get the user factory value.
        Returns:
        a UserFactory value
      • apiInfo

        private springfox.documentation.service.ApiInfo apiInfo()
        Get the API info (REST Swagger) for DARE.
        Returns:
        an ApiInfo value