diff options
3 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java b/src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java index bc1888f..d0c528f 100644 --- a/src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java +++ b/src/main/java/io/swagger/api/impl/DcaeServicesApiServiceImpl.java @@ -136,7 +136,7 @@ public class DcaeServicesApiServiceImpl extends DcaeServicesApiService { String componentType, Boolean shareable, DateTime created, Integer offset, UriInfo uriInfo, SecurityContext securityContext) { List<DCAEServiceObject> serviceObjects = new ArrayList<>(); - DateTime createdCutoff = (created == null ? DateTime.now(DateTimeZone.UTC) : created); + DateTime createdCutoff = created == null ? DateTime.now(DateTimeZone.UTC) : created; LOG.info(String.format("Create time upper bound cutoff: %s", createdCutoff.toString())); @@ -211,7 +211,7 @@ public class DcaeServicesApiServiceImpl extends DcaeServicesApiService { if (shareable != null) { // NOTE: That the shareable field in the database is actually an integer. - query.bind("shareable", (shareable ? 1 : 0)); + query.bind("shareable", shareable ? 1 : 0); } query.bind("createdCutoff", createdCutoff); diff --git a/src/main/java/org/onap/dcae/inventory/clients/DatabusControllerClient.java b/src/main/java/org/onap/dcae/inventory/clients/DatabusControllerClient.java index 29330b0..b2429d9 100644 --- a/src/main/java/org/onap/dcae/inventory/clients/DatabusControllerClient.java +++ b/src/main/java/org/onap/dcae/inventory/clients/DatabusControllerClient.java @@ -48,7 +48,7 @@ public class DatabusControllerClient { resourcePath = (new StringBuilder("/")).append(resourcePath).toString(); } - return UriBuilder.fromPath(resourcePath.toString()).scheme("https").host(this.connectionConfiguration.getHost()) + return UriBuilder.fromPath(resourcePath).scheme("https").host(this.connectionConfiguration.getHost()) .port(this.connectionConfiguration.getPort()).build(); } diff --git a/src/main/java/org/onap/dcae/inventory/daos/DCAEServicesComponentsMapsDAO.java b/src/main/java/org/onap/dcae/inventory/daos/DCAEServicesComponentsMapsDAO.java index 68ed59c..c9eaa99 100644 --- a/src/main/java/org/onap/dcae/inventory/daos/DCAEServicesComponentsMapsDAO.java +++ b/src/main/java/org/onap/dcae/inventory/daos/DCAEServicesComponentsMapsDAO.java @@ -36,6 +36,7 @@ public interface DCAEServicesComponentsMapsDAO extends InventoryDAO { @SqlQuery("select exists (select * from information_schema.tables where table_name = \'dcae_services_components_maps\')") Boolean checkIfTableExists(); + @Override @SqlUpdate("create table dcae_services_components_maps (service_id varchar not null references dcae_services (service_id), " + "component_id varchar not null references dcae_service_components (component_id), " + "created timestamp not null, primary key (service_id, component_id))") |