ElasticsearchExporter implements Exporter { @Override public void configure(final Context context) { log = context.getLogger(); configuration = context.getConfiguration().instantiate(ElasticsearchExporterConfiguration.class); log.debug("Exporter configured with {}", configuration); validate(configuration); context.setFilter(new ElasticsearchRecordFilter(configuration)); }  @Override void configure(final Context context); @Override void open(final Controller controller); @Override void close(); @Override void export(final Record<?> record); static final String ZEEBE_RECORD_TEMPLATE_JSON; }
@Test public void shouldFailOnWrongPrefix() { config.index.prefix = "prefix_withunderscore"; createExporterAndTestHarness(); assertThatThrownBy(() -> testHarness.configure("els", config)) .isInstanceOf(ExporterException.class) .withFailMessage( "Elasticsearch prefix must not contain underscore. Current value: " + config.index.prefix); }