class ConerCoreApplication extends Application<ConerCoreConfiguration> {

    @Override
    public void run(
            ConerCoreConfiguration conerCoreConfiguration,
            Environment environment
    ) throws Exception {
        initComponents(conerCoreConfiguration);
        JerseyEnvironment jersey = environment.jersey();
        jersey.register(components.eventsResource());
        jersey.register(components.eventRegistrationsResource());
        jersey.register(components.eventRunsResource());
        jersey.register(components.eventResultsResource());
        jersey.register(components.handicapGroupsResource());
        jersey.register(components.handicapGroupSetsResource());
        jersey.register(components.competitionGroupsResource());
        jersey.register(components.competitionGroupSetsResource());
        jersey.register(components.domainServiceExceptionMapper());
        jersey.register(components.runtimeExceptionUnwrappingMapper());

        optionallyRegisterHsqlDatabaseManagerSwingTask(environment, conerCoreConfiguration);
    }

}