test_class.declarator: configuration = new Configuration()
test_class.modifier: static
test_class.original_string: static Configuration configuration = new Configuration();
test_class.type: Configuration
test_class.var_name: configuration
test_class.declarator: complexEventProcessor
test_class.modifier: @Mock
      public
test_class.original_string: @Mock
      public ComplexEventProcessor complexEventProcessor;
test_class.type: ComplexEventProcessor
test_class.var_name: complexEventProcessor
test_class.declarator: persistence
test_class.modifier: @Mock
      public
test_class.original_string: @Mock
      public Persistence persistence;
test_class.type: Persistence
test_class.var_name: persistence
test_class.declarator: subscriptionManager
test_class.modifier: @Mock
      public
test_class.original_string: @Mock
      public SubscriptionManager subscriptionManager;
test_class.type: SubscriptionManager
test_class.var_name: subscriptionManager
test_class.declarator: eventMapper
test_class.modifier: @Mock
      public
test_class.original_string: @Mock
      public EventMapper eventMapper;
test_class.type: EventMapper
test_class.var_name: eventMapper
test_class.declarator: init
test_class.modifier: @Autowired
      @InjectMocks
      public
test_class.original_string: @Autowired
      @InjectMocks
      public Init init;
test_class.type: Init
test_class.var_name: init
test_class.file: cepheus-cep/src/test/java/com/orange/cepheus/cep/InitTest.java
test_class.identifier: InitTest
test_case.body: @Test
      public void checkConfOk() throws ConfigurationException, PersistenceException {
          when(persistence.configurationExists(TenantFilter.DEFAULT_TENANTID)).thenReturn(true);
          when(persistence.loadConfiguration(TenantFilter.DEFAULT_TENANTID)).thenReturn(configuration);
  
          init.loadConfigurationOnStartup();
  
          verify(complexEventProcessor).setConfiguration(eq(configuration));
          verify(subscriptionManager).setConfiguration(eq(configuration));
          verify(eventMapper).setConfiguration(configuration);
      }
test_case.class_method_signature: InitTest.checkConfOk()
test_case.full_signature: @Test public void checkConfOk()
test_case.identifier: checkConfOk
test_case.invocations: thenReturn when configurationExists thenReturn when loadConfiguration loadConfigurationOnStartup setConfiguration verify eq setConfiguration verify eq setConfiguration verify
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void checkConfOk()
focal_class.declarator: logger = LoggerFactory.getLogger(Init.class)
focal_class.modifier: private static
focal_class.original_string: private static Logger logger = LoggerFactory.getLogger(Init.class);
focal_class.type: Logger
focal_class.var_name: logger
focal_class.declarator: applicationContext
focal_class.modifier: @Autowired
      protected
focal_class.original_string: @Autowired
      protected ApplicationContext applicationContext;
focal_class.type: ApplicationContext
focal_class.var_name: applicationContext
focal_class.declarator: persistence
focal_class.modifier: @Autowired
      protected
focal_class.original_string: @Autowired
      protected Persistence persistence;
focal_class.type: Persistence
focal_class.var_name: persistence
focal_class.declarator: complexEventProcessor
focal_class.modifier: @Autowired
      protected
focal_class.original_string: @Autowired
      protected ComplexEventProcessor complexEventProcessor;
focal_class.type: ComplexEventProcessor
focal_class.var_name: complexEventProcessor
focal_class.declarator: subscriptionManager
focal_class.modifier: @Autowired
      protected
focal_class.original_string: @Autowired
      protected SubscriptionManager subscriptionManager;
focal_class.type: SubscriptionManager
focal_class.var_name: subscriptionManager
focal_class.declarator: eventMapper
focal_class.modifier: @Autowired
      protected
focal_class.original_string: @Autowired
      protected EventMapper eventMapper;
focal_class.type: EventMapper
focal_class.var_name: eventMapper
focal_class.file: cepheus-cep/src/main/java/com/orange/cepheus/cep/Init.java
focal_class.identifier: Init
focal_class.class_method_signature: Init.loadConfigurationOnStartup()
focal_class.full_signature: @PostConstruct protected void loadConfigurationOnStartup()
focal_class.identifier: loadConfigurationOnStartup
focal_class.modifiers: @PostConstruct protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void loadConfigurationOnStartup()
focal_method.body: @PostConstruct
      protected void loadConfigurationOnStartup() {
          // Try restoring the persisted configuration if any
          try {
              if (persistence.configurationExists(TenantFilter.DEFAULT_TENANTID)) {
                  Configuration configuration = persistence.loadConfiguration(TenantFilter.DEFAULT_TENANTID);
                  eventMapper.setConfiguration(configuration);
                  complexEventProcessor.setConfiguration(configuration);
                  subscriptionManager.setConfiguration(configuration);
              }
          } catch (PersistenceException | ConfigurationException e) {
              logger.error("Failed to load or apply persisted configuration", e);
          }
      }
focal_method.class_method_signature: Init.loadConfigurationOnStartup()
focal_method.full_signature: @PostConstruct protected void loadConfigurationOnStartup()
focal_method.identifier: loadConfigurationOnStartup
focal_method.invocations: configurationExists loadConfiguration setConfiguration setConfiguration setConfiguration error
focal_method.modifiers: @PostConstruct protected
focal_method.parameters: ()
focal_method.return: void
focal_method.signature: void loadConfigurationOnStartup()