Skip to content

Commit

Permalink
Use version from ContextListener
Browse files Browse the repository at this point in the history
  • Loading branch information
VictorHarbo committed Aug 5, 2024
1 parent 612227c commit 01b1ba8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
public class InitializationContextListener implements ServletContextListener {

private static final Logger log = LoggerFactory.getLogger(InitializationContextListener.class);
private static String version;
public static String version;

// this is called by the web-container before opening up for requests.(defined in web.xml)
public void contextInitialized(ServletContextEvent event) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import java.util.stream.Collectors;
import java.util.stream.Stream;

import dk.kb.netarchivesuite.solrwayback.listeners.InitializationContextListener;
import io.swagger.v3.jaxrs2.integration.JaxrsOpenApiContextBuilder;
import io.swagger.v3.jaxrs2.integration.resources.OpenApiResource;

Expand Down Expand Up @@ -39,7 +40,7 @@ public SolrWaybackApplication(@Context ServletConfig servletConfig) {
OpenAPI oas = new OpenAPI();
Info info = new Info()
.title("SolrWayback")
.version("5.1.2")
.version(InitializationContextListener.version)
.summary("Description of the SolrWayback API.")
.description("SolrWayback is a web application for browsing historical harvested ARC/WARC files similar to the Internet Archive Wayback Machine. " +
"SolrWayback runs on a Solr server containing ARC/WARC files indexed using the warc-indexer")
Expand Down

0 comments on commit 01b1ba8

Please sign in to comment.