Merged from patches

This commit is contained in:
Fabio Sinibaldi 2022-05-27 15:13:35 +02:00
parent 4d52bf7123
commit 5f28029db1
1 changed files with 5 additions and 6 deletions

View File

@ -1,14 +1,13 @@
package org.gcube.application.geoportal.service.engine.postgis;
import lombok.Synchronized;
import lombok.extern.slf4j.Slf4j;
import org.gcube.application.cms.implementations.ISInterface;
import org.gcube.application.cms.implementations.ImplementationProvider;
import org.gcube.application.geoportal.common.model.legacy.BBOX;
import org.gcube.application.geoportal.common.model.rest.ConfigurationException;
import org.gcube.application.geoportal.common.model.rest.DatabaseConnection;
import org.gcube.application.geoportal.service.engine.ImplementationProvider;
import org.gcube.application.geoportal.service.model.internal.db.PostgisTable;
import org.gcube.application.geoportal.service.model.internal.faults.ConfigurationException;
import org.gcube.application.geoportal.service.model.internal.faults.DataParsingException;
import org.gcube.application.geoportal.service.utils.ISUtils;
import java.sql.*;
import java.util.regex.Matcher;
@ -40,8 +39,8 @@ public class PostgisDBManager implements PostgisDBManagerI {
}
private static PostgisDBManagerI get(boolean autocommit) throws SQLException, ConfigurationException {
DatabaseConnection config=
ImplementationProvider.get().getIsProvider().getIS().queryForDB("postgis", "Concessioni");
DatabaseConnection config = ImplementationProvider.get().getProvidedObjectByClass(ISInterface.class)
.queryForDatabase("Database","postgis", "GNA_DB","Concessioni");
log.debug("Found configuration : "+config);
PostgisDBManager toReturn=new PostgisDBManager(config);
toReturn.conn.setAutoCommit(autocommit);