Skip to content

Commit

Permalink
fix javax annotation version conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
Zhihang Yao committed Jul 4, 2024
1 parent 9a8cb6c commit deb4a07
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
3 changes: 1 addition & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ subprojects {
exports('org.apache.tomcat.jdbc.pool')
}
automaticModule("javax.inject-1.jar", "javax.inject")
module('swagger-ui-5.13.0.jar', 'org.webjars', '5.13.0') {
}
module('swagger-ui-5.13.0.jar', 'org.webjars', '5.13.0')
module("javax.servlet-api-3.1.0.jar", "javax.servlet", '3.1.0')
module("picocli-spring-boot-starter-4.7.5.jar", "picocli.spring", '4.7.5') {
requires('info.picocli')
Expand Down
1 change: 1 addition & 0 deletions citydb-web/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ dependencies {
implementation project(':citydb-operation')
implementation project(':citydb-database-postgres')
implementation project(':citydb-plugin')
implementation project(':citydb-query')
implementation('org.springframework.boot:spring-boot-starter-web') {
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-tomcat'
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-logging'
Expand Down
1 change: 1 addition & 0 deletions citydb-web/src/main/java/module-info.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
requires org.citydb.operation;
requires org.citydb.cli;
requires org.citydb.database.postgres;
requires org.citydb.query;

requires spring.context;
requires spring.beans;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
import org.apache.logging.log4j.Logger;
import org.citydb.cli.ExecutionException;
import org.citydb.cli.util.CommandHelper;
import org.citydb.cli.util.QueryExecutor;
import org.citydb.cli.util.QueryResult;
import org.citydb.core.file.OutputFile;
import org.citydb.database.DatabaseManager;
import org.citydb.database.adapter.DatabaseAdapter;
Expand All @@ -24,6 +22,9 @@
import org.citydb.operation.exporter.ExportOptions;
import org.citydb.operation.exporter.Exporter;
import org.citydb.operation.util.FeatureStatistics;
import org.citydb.query.executor.QueryExecutor;
import org.citydb.query.executor.QueryResult;
import org.citydb.query.util.QueryHelper;
import org.citydb.web.config.Constants;
import org.citydb.web.config.WebOptions;
import org.citydb.web.exception.ServiceException;
Expand Down Expand Up @@ -105,14 +106,14 @@ private void doExport(String type, FeatureWriter writer) throws ServiceException
throw new ServiceException(HttpStatus.NOT_FOUND, "Feature type '" + type + "' is not supported.");
}

String query = "select id from " + adapter.getConnectionDetails().getSchema() + ".feature " +
"where objectclass_id = " + featureType.getId() + " and termination_date is null";
Exporter exporter = Exporter.newInstance();
AtomicBoolean shouldRun = new AtomicBoolean(true);
QueryExecutor executor = QueryExecutor.of(adapter);
FeatureStatistics statistics = new FeatureStatistics(adapter);
try {
try (QueryResult result = executor.executeQuery(query)) {
QueryExecutor executor = helper.getQueryExecutor(QueryHelper.getNonTerminatedTopLevelFeatures(),
databaseManager.getAdapter());

try (QueryResult result = executor.executeQuery()) {
exporter.startSession(adapter, new ExportOptions());
while (shouldRun.get() && result.hasNext()) {
long id = result.getId();
Expand Down

0 comments on commit deb4a07

Please sign in to comment.