APISonar


fish.payara.nucleus.notification.configuration.NotifierType.LOG

> fish > payara > nucleus > notification > configuration > NotifierType > LOG
fish APIs payara APIs nucleus APIs notification APIs configuration APIs NotifierType APIs LOG APIs

Example 1
public void configureService() {
        executionOptions.setEnabled(false);
        executionOptions.setSampleRate(1.0);
        executionOptions.setSampleRateFirstEnabled(false);
        executionOptions.setThresholdValue(1000L);
        executionOptions.setThresholdUnit(TimeUnit.MILLISECONDS);
        executionOptions.setHistoricTraceStoreEnabled(false);
        LogNotifierExecutionOptions logNotifierExecutionOptions = new LogNotifierExecutionOptions();
        logNotifierExecutionOptions.setEnabled(true);
        executionOptions.getNotifierExecutionOptionsList().put(NotifierType.LOG, logNotifierExecutionOptions);
    }
Example 2
public void notifierConfigurationExecutionOptionBuildsSuccessfullyForLog() {
        LogNotifierConfiguration logNotifierConfiguration = mock(LogNotifierConfiguration.class);
        when(logNotifierConfiguration.getEnabled()).thenReturn("true");

        LogNotifierConfigurationExecutionOptions executionOptions = factory.build(logNotifierConfiguration);

        assertThat(executionOptions.getNotifierType(), is(NotifierType.LOG));
        assertThat(executionOptions.isEnabled(), is(true));
    }