diff --git a/rest-backend/pom.xml b/rest-backend/pom.xml index 78a0fad43..70e435186 100644 --- a/rest-backend/pom.xml +++ b/rest-backend/pom.xml @@ -265,7 +265,7 @@ com.h2database h2 - 1.4.200 test diff --git a/rest-backend/src/main/java/org/eclipse/steady/backend/repo/AffectedLibraryRepository.java b/rest-backend/src/main/java/org/eclipse/steady/backend/repo/AffectedLibraryRepository.java index 1d32c4402..08de9725f 100644 --- a/rest-backend/src/main/java/org/eclipse/steady/backend/repo/AffectedLibraryRepository.java +++ b/rest-backend/src/main/java/org/eclipse/steady/backend/repo/AffectedLibraryRepository.java @@ -114,7 +114,7 @@ List findByBugAndSource( */ @Query( "SELECT afflib FROM AffectedLibrary AS afflib JOIN afflib.libraryId lid, Library l " - + "WHERE l.libraryId=lid AND l.wellknownDigest='true' AND" + + "WHERE l.libraryId=lid AND l.wellknownDigest=true AND" + " afflib.bugId = :bug AND afflib.source = :source") List findWellKnownByBugAndSource( @Param("bug") Bug bug, @Param("source") AffectedVersionSource source); @@ -181,7 +181,7 @@ List findByBugAndLibIdAndSource( */ @Query( "SELECT afflib FROM AffectedLibrary AS afflib JOIN afflib.libraryId lid, Library l " - + "WHERE l.libraryId=lid AND l.wellknownDigest='true' AND" + + "WHERE l.libraryId=lid AND l.wellknownDigest=true AND" + " afflib.bugId = :bug") List findWellKnownByBug(@Param("bug") Bug bug); diff --git a/rest-backend/src/main/java/org/eclipse/steady/backend/repo/LibraryRepository.java b/rest-backend/src/main/java/org/eclipse/steady/backend/repo/LibraryRepository.java index e1a78d6c6..463cd801d 100644 --- a/rest-backend/src/main/java/org/eclipse/steady/backend/repo/LibraryRepository.java +++ b/rest-backend/src/main/java/org/eclipse/steady/backend/repo/LibraryRepository.java @@ -326,7 +326,7 @@ List findAffCCs( + " l1.id=bl.library_id inner join library_id lid2 on" + " bl.bundled_library_ids_id=lid2.id inner join lib l2 on" + " bl.bundled_library_ids_id=l2.library_id_id where d.app=:app and not l1.id =" - + " l2.id and l2.wellknown_digest='true' and not lid1.id=lid2.id", + + " l2.id and l2.wellknown_digest=true and not lid1.id=lid2.id", nativeQuery = true) List findBundledLibByApp(@Param("app") Application app); } diff --git a/rest-backend/src/main/resources/application-docker.properties b/rest-backend/src/main/resources/application-docker.properties index dcf7a85c7..07ee1aa05 100755 --- a/rest-backend/src/main/resources/application-docker.properties +++ b/rest-backend/src/main/resources/application-docker.properties @@ -17,7 +17,7 @@ # SPDX-FileCopyrightText: Copyright (c) 2018-2020 SAP SE or an SAP affiliate company and Eclipse Steady contributors # -spring.profiles=docker +spring.config.activate.on-profile=docker #server.contextPath=/backend diff --git a/rest-backend/src/main/resources/application-localhost.properties b/rest-backend/src/main/resources/application-localhost.properties index e56e2d559..19e56a35b 100755 --- a/rest-backend/src/main/resources/application-localhost.properties +++ b/rest-backend/src/main/resources/application-localhost.properties @@ -17,7 +17,7 @@ # SPDX-FileCopyrightText: Copyright (c) 2018-2020 SAP SE or an SAP affiliate company and Eclipse Steady contributors # -spring.profiles=localhost +spring.config.activate.on-profile=localhost spring.datasource.url= jdbc:postgresql://localhost:5432/vulas diff --git a/rest-backend/src/main/resources/application-test.properties b/rest-backend/src/main/resources/application-test.properties index 0acac8bb5..3260952fa 100755 --- a/rest-backend/src/main/resources/application-test.properties +++ b/rest-backend/src/main/resources/application-test.properties @@ -17,7 +17,8 @@ # SPDX-FileCopyrightText: Copyright (c) 2018-2020 SAP SE or an SAP affiliate company and Eclipse Steady contributors # -spring.profiles=test +spring.config.activate.on-profile=test +spring.datasource.url=jdbc:h2:mem:test;MODE=LEGACY server.port = 8091