You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by se...@apache.org on 2016/09/23 16:28:50 UTC

cxf git commit: [CXF-7069] Removing the direct refs to Hibernate annotations

Repository: cxf
Updated Branches:
  refs/heads/3.1.x-fixes 60cf6aa4f -> e982c5518


[CXF-7069] Removing the direct refs to Hibernate annotations


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/e982c551
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/e982c551
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/e982c551

Branch: refs/heads/3.1.x-fixes
Commit: e982c5518b8dec97813d4e1cc7045402d163a2c5
Parents: 60cf6aa
Author: Sergey Beryozkin <sb...@gmail.com>
Authored: Fri Sep 23 17:28:31 2016 +0100
Committer: Sergey Beryozkin <sb...@gmail.com>
Committed: Fri Sep 23 17:28:31 2016 +0100

----------------------------------------------------------------------
 rt/rs/security/oauth-parent/oauth2/pom.xml                  | 8 +++++---
 .../cxf/rs/security/oauth2/common/OAuthPermission.java      | 9 +--------
 .../cxf/rs/security/oauth2/common/ServerAccessToken.java    | 8 --------
 3 files changed, 6 insertions(+), 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/e982c551/rt/rs/security/oauth-parent/oauth2/pom.xml
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/pom.xml b/rt/rs/security/oauth-parent/oauth2/pom.xml
index 2be5542..8a9193d 100644
--- a/rt/rs/security/oauth-parent/oauth2/pom.xml
+++ b/rt/rs/security/oauth-parent/oauth2/pom.xml
@@ -119,23 +119,25 @@
       <groupId>org.apache.openjpa</groupId>
       <artifactId>openjpa</artifactId>
       <version>${cxf.openjpa.version}</version>
-      <scope>compile</scope>
+      <scope>test</scope>
       <optional>true</optional>
     </dependency>
+    
     <dependency>
       <groupId>org.hibernate</groupId>
       <artifactId>hibernate-entitymanager</artifactId>
       <version>${hibernate.em.version}</version>
-      <scope>compile</scope>
+      <scope>test</scope>
       <optional>true</optional>
     </dependency>
     <dependency>
       <groupId>org.hibernate</groupId>
       <artifactId>hibernate-ehcache</artifactId>
       <version>${hibernate.em.version}</version>
-      <scope>compile</scope>
+      <scope>test</scope>
       <optional>true</optional>
     </dependency>
+    
     <dependency>
       <groupId>org.slf4j</groupId>
       <artifactId>slf4j-nop</artifactId>

http://git-wip-us.apache.org/repos/asf/cxf/blob/e982c551/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthPermission.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthPermission.java b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthPermission.java
index e57a793..11d9ba2 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthPermission.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/OAuthPermission.java
@@ -20,6 +20,7 @@ package org.apache.cxf.rs.security.oauth2.common;
 
 import java.util.LinkedList;
 import java.util.List;
+
 import javax.persistence.Cacheable;
 import javax.persistence.ElementCollection;
 import javax.persistence.Entity;
@@ -27,10 +28,6 @@ import javax.persistence.FetchType;
 import javax.persistence.OrderColumn;
 import javax.xml.bind.annotation.XmlRootElement;
 
-import org.hibernate.annotations.Cache;
-import org.hibernate.annotations.CacheConcurrencyStrategy;
-import org.hibernate.annotations.FetchMode;
-
 /**
  * Provides the complete information about a given opaque permission.
  * For example, a scope parameter such as "read_calendar" will be
@@ -64,8 +61,6 @@ public class OAuthPermission extends Permission {
      */
     @ElementCollection(fetch = FetchType.EAGER)
     @OrderColumn
-    @org.hibernate.annotations.Fetch(FetchMode.SUBSELECT)
-    @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
     public List<String> getHttpVerbs() {
         return httpVerbs;
     }
@@ -85,8 +80,6 @@ public class OAuthPermission extends Permission {
      */
     @ElementCollection(fetch = FetchType.EAGER)
     @OrderColumn
-    @org.hibernate.annotations.Fetch(FetchMode.SUBSELECT)
-    @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
     public List<String> getUris() {
         return uris;
     }

http://git-wip-us.apache.org/repos/asf/cxf/blob/e982c551/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/ServerAccessToken.java
----------------------------------------------------------------------
diff --git a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/ServerAccessToken.java b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/ServerAccessToken.java
index 72c2311..f758aed 100644
--- a/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/ServerAccessToken.java
+++ b/rt/rs/security/oauth-parent/oauth2/src/main/java/org/apache/cxf/rs/security/oauth2/common/ServerAccessToken.java
@@ -34,10 +34,6 @@ import javax.persistence.OrderColumn;
 import org.apache.cxf.rs.security.oauth2.provider.OAuthServiceException;
 import org.apache.cxf.rs.security.oauth2.utils.OAuthConstants;
 import org.apache.cxf.rs.security.oauth2.utils.OAuthUtils;
-import org.hibernate.annotations.Cache;
-import org.hibernate.annotations.CacheConcurrencyStrategy;
-import org.hibernate.annotations.Fetch;
-import org.hibernate.annotations.FetchMode;
 
 
 /**
@@ -121,8 +117,6 @@ public abstract class ServerAccessToken extends AccessToken {
      * @return the scopes
      */
     @ManyToMany(fetch = FetchType.EAGER)
-    @Fetch(FetchMode.SUBSELECT)
-    @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
     public List<OAuthPermission> getScopes() {
         return scopes;
     }
@@ -190,7 +184,6 @@ public abstract class ServerAccessToken extends AccessToken {
 
     @ElementCollection(fetch = FetchType.EAGER)
     @OrderColumn
-    @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
     public List<String> getAudiences() {
         return audiences;
     }
@@ -217,7 +210,6 @@ public abstract class ServerAccessToken extends AccessToken {
 
     @ElementCollection(fetch = FetchType.EAGER)
     @MapKeyColumn(name = "extraPropName")
-    @Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
     public Map<String, String> getExtraProperties() {
         return extraProperties;
     }