diff options
author | a.sreekumar <ajith.sreekumar@bell.ca> | 2022-02-15 12:45:29 +0000 |
---|---|---|
committer | a.sreekumar <ajith.sreekumar@bell.ca> | 2022-02-15 12:46:08 +0000 |
commit | ce7b217261784bb4cd2edd44d482ce6a705c9232 (patch) | |
tree | f1b7853046b576effad96447f211ea9695e099d1 /main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java | |
parent | b1f5a9439f285e16c055e50ce12c65a6623f21a0 (diff) |
Fix issue with GeneratedValue in PfGeneratedIdKey
Change-Id: If244237e4aa39e1f3184cab04ae7d5ad7e85e5fa
Issue-ID: POLICY-3897
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
Diffstat (limited to 'main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java')
-rw-r--r-- | main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java b/main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java index f140fc6b..b0fcbfc0 100644 --- a/main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java +++ b/main/src/main/java/org/onap/policy/pap/main/repository/PolicyAuditRepository.java @@ -22,14 +22,13 @@ package org.onap.policy.pap.main.repository; import java.util.Date; import java.util.List; -import org.onap.policy.models.base.PfGeneratedIdKey; import org.onap.policy.models.pap.persistence.concepts.JpaPolicyAudit; import org.springframework.data.domain.Pageable; import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.stereotype.Repository; @Repository -public interface PolicyAuditRepository extends JpaRepository<JpaPolicyAudit, PfGeneratedIdKey> { +public interface PolicyAuditRepository extends JpaRepository<JpaPolicyAudit, Long> { List<JpaPolicyAudit> findByTimeStampBetween(Date startTime, Date endTime, Pageable topRecordsSize); @@ -48,26 +47,26 @@ public interface PolicyAuditRepository extends JpaRepository<JpaPolicyAudit, PfG List<JpaPolicyAudit> findByPdpGroupAndTimeStampBetween(String pdpGroup, Date startTime, Date endTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByPdpGroupAndKeyNameAndKeyVersion(String pdpGroup, String policyName, String policyVersion, + List<JpaPolicyAudit> findByPdpGroupAndNameAndVersion(String pdpGroup, String policyName, String policyVersion, Pageable topRecordsSize); - List<JpaPolicyAudit> findByPdpGroupAndKeyNameAndKeyVersionAndTimeStampGreaterThanEqual(String pdpGroup, + List<JpaPolicyAudit> findByPdpGroupAndNameAndVersionAndTimeStampGreaterThanEqual(String pdpGroup, String policyName, String policyVersion, Date startTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByPdpGroupAndKeyNameAndKeyVersionAndTimeStampLessThanEqual(String pdpGroup, + List<JpaPolicyAudit> findByPdpGroupAndNameAndVersionAndTimeStampLessThanEqual(String pdpGroup, String policyName, String policyVersion, Date endTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByPdpGroupAndKeyNameAndKeyVersionAndTimeStampBetween(String pdpGroup, String policyName, + List<JpaPolicyAudit> findByPdpGroupAndNameAndVersionAndTimeStampBetween(String pdpGroup, String policyName, String policyVersion, Date startTime, Date endTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByKeyNameAndKeyVersion(String policyName, String policyVersion, Pageable topRecordsSize); + List<JpaPolicyAudit> findByNameAndVersion(String policyName, String policyVersion, Pageable topRecordsSize); - List<JpaPolicyAudit> findByKeyNameAndKeyVersionAndTimeStampGreaterThanEqual(String policyName, String policyVersion, + List<JpaPolicyAudit> findByNameAndVersionAndTimeStampGreaterThanEqual(String policyName, String policyVersion, Date startTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByKeyNameAndKeyVersionAndTimeStampLessThanEqual(String policyName, String policyVersion, + List<JpaPolicyAudit> findByNameAndVersionAndTimeStampLessThanEqual(String policyName, String policyVersion, Date endTime, Pageable topRecordsSize); - List<JpaPolicyAudit> findByKeyNameAndKeyVersionAndTimeStampBetween(String policyName, String policyVersion, + List<JpaPolicyAudit> findByNameAndVersionAndTimeStampBetween(String policyName, String policyVersion, Date startTime, Date endTime, Pageable topRecordsSize); } |