[hibernate3] Enable jbosscache and infinispan modules (RHBZ#846658)
Andy Grimm
arg at fedoraproject.org
Fri Aug 10 14:50:03 UTC 2012
commit 15a90bd587eff34b92a8af05c05ea6bdd76c2d77
Author: Andy Grimm <agrimm at gmail.com>
Date: Fri Aug 10 10:49:50 2012 -0400
Enable jbosscache and infinispan modules (RHBZ#846658)
- Remove duplicate files from core package
hibernate-orm-infinispan-5-support.patch | 34 +++++++++++++++++++++
hibernate3.spec | 47 +++++++++++++++++++++++-------
2 files changed, 70 insertions(+), 11 deletions(-)
---
diff --git a/hibernate-orm-infinispan-5-support.patch b/hibernate-orm-infinispan-5-support.patch
new file mode 100644
index 0000000..104e53f
--- /dev/null
+++ b/hibernate-orm-infinispan-5-support.patch
@@ -0,0 +1,34 @@
+--- hibernate-orm-3.6.10.Final/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/impl/BaseRegion.java.orig 2012-08-08 12:41:44.619000123 +0200
++++ hibernate-orm-3.6.10.Final/hibernate-infinispan/src/main/java/org/hibernate/cache/infinispan/impl/BaseRegion.java 2012-08-08 12:45:57.434000123 +0200
+@@ -270,7 +270,7 @@
+
+ protected boolean handleEvictAllModification(CacheEntryModifiedEvent event) {
+ if (!event.isPre() && (replication || event.isOriginLocal()) && CacheHelper.isEvictAllNotification(event.getKey(), event.getValue())) {
+- if (log.isTraceEnabled()) log.trace("Set invalid state because marker cache entry was put: {0}", event);
++ if (log.isTraceEnabled()) log.trace("Set invalid state because marker cache entry was put");
+ invalidateState.set(InvalidateState.INVALID);
+ return true;
+ }
+@@ -279,13 +279,13 @@
+
+ @CacheEntryInvalidated
+ public void entryInvalidated(CacheEntryInvalidatedEvent event) {
+- if (log.isTraceEnabled()) log.trace("Cache entry invalidated: {0}", event);
++ if (log.isTraceEnabled()) log.trace("Cache entry invalidated");
+ handleEvictAllInvalidation(event);
+ }
+
+ protected boolean handleEvictAllInvalidation(CacheEntryInvalidatedEvent event) {
+ if (!event.isPre() && CacheHelper.isEvictAllNotification(event.getKey())) {
+- if (log.isTraceEnabled()) log.trace("Set invalid state because marker cache entry was invalidated: {0}", event);
++ if (log.isTraceEnabled()) log.trace("Set invalid state because marker cache entry was invalidated");
+ invalidateState.set(InvalidateState.INVALID);
+ return true;
+ }
+@@ -303,4 +303,4 @@
+ }
+ }
+
+-}
+\ No newline at end of file
++}
diff --git a/hibernate3.spec b/hibernate3.spec
index 2b537fa..488f578 100644
--- a/hibernate3.spec
+++ b/hibernate3.spec
@@ -4,7 +4,7 @@
Name: hibernate3
Version: 3.6.10
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: Relational persistence and query service
Group: Development/Libraries
@@ -19,6 +19,7 @@ Source0: hibernate-orm-3.6.10.Final.tar.xz
Patch0: hibernate-orm-fix-cglib-gid.patch
Patch1: hibernate-orm-fix-jacc-gid-aid.patch
Patch2: hibernate-orm-fix-ant-gid.patch
+Patch3: hibernate-orm-infinispan-5-support.patch
BuildArch: noarch
@@ -44,10 +45,9 @@ BuildRequires: proxool
BuildRequires: hibernate-commons-annotations
BuildRequires: jboss-servlet-3.0-api
BuildRequires: ehcache-core
-# Uncomment when BZ 844827 is done
-# BuildRequires: jbosscache-core
-# FIXME: Infinispan module build is failing
-# BuildRequires: infinispan
+BuildRequires: jbosscache-core
+BuildRequires: infinispan
+BuildRequires: rhq-plugin-annotations
Requires: java
Requires: jpackage-utils
@@ -99,16 +99,33 @@ Requires: %{name} = %{version}-%{release}
%package ehcache
Summary: Integration of Hibernate with Ehcache
+Requires: %{name} = %{version}-%{release}
Requires: ehcache-core
%description ehcache
%{summary}.
+%package jbosscache
+Summary: Integration of hibernate with jbosscache
+Requires: %{name} = %{version}-%{release}
+Requires: jbosscache-core
+
+%description jbosscache
+%{summary}.
+
+%package infinispan
+Summary: Integration of Hibernate with Infinispan
+Requires: infinispan
+
+%description infinispan
+%{summary}.
+
%prep
%setup -q -n %{oname}-%{namedversion}
%patch0 -p1
%patch1 -p1
%patch2 -p1
+%patch3 -p1
%pom_remove_plugin org.jboss.maven.plugins:maven-jdocbook-plugin hibernate-parent
%pom_remove_plugin org.jboss.maven.plugins:maven-jdocbook-style-plugin hibernate-parent
@@ -117,10 +134,6 @@ Requires: ehcache-core
%pom_disable_module hibernate-swarmcache
%pom_disable_module hibernate-envers
%pom_disable_module hibernate-jdbc3-testing
-# infinispan module doesn't build yet.
-%pom_disable_module hibernate-infinispan
-# Remove when BZ 844827 is done
-%pom_disable_module hibernate-jbosscache
%build
@@ -144,7 +157,8 @@ install -pm 644 hibernate-parent/pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name
# Jar files:
install -d -m 755 %{buildroot}%{_javadir}/%{name}
for module in hibernate-core hibernate-c3p0 hibernate-proxool \
- hibernate-entitymanager hibernate-ehcache ; do
+ hibernate-entitymanager hibernate-ehcache \
+ hibernate-jbosscache hibernate-infinispan; do
install -m 644 ${module}/target/${module}-%{namedversion}.jar %{buildroot}%{_javadir}/%{name}/${module}.jar
install -pm 644 ${module}/pom.xml %{buildroot}%{_mavenpomdir}/JPP.%{name}-${module}.pom
%add_maven_depmap JPP.%{name}-${module}.pom %{name}/${module}.jar
@@ -161,7 +175,6 @@ cp -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
%{_mavenpomdir}/JPP-%{name}-parent.pom
%{_mavenpomdir}/JPP.%{name}-hibernate-core.pom
%{_mavendepmapfragdir}/%{name}
-%{_javadir}/%{name}
%files javadoc
%doc lgpl.txt
@@ -179,11 +192,23 @@ cp -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
%{_javadir}/%{name}/hibernate-ehcache.jar
%{_mavenpomdir}/JPP.%{name}-hibernate-ehcache.pom
+%files infinispan
+%{_javadir}/%{name}/hibernate-infinispan.jar
+%{_mavenpomdir}/JPP.%{name}-hibernate-infinispan.pom
+
%files proxool
%{_javadir}/%{name}/hibernate-proxool.jar
%{_mavenpomdir}/JPP.%{name}-hibernate-proxool.pom
+%files jbosscache
+%{_javadir}/%{name}/hibernate-jbosscache.jar
+%{_mavenpomdir}/JPP.%{name}-hibernate-jbosscache.pom
+
%changelog
+* Fri Aug 10 2012 Andy Grimm <agrimm at gmail.com> - 3.6.10-4
+- Enable jbosscache and infinispan modules (RHBZ#846658)
+- Remove duplicate files from core package
+
* Mon Aug 06 2012 Andy Grimm <agrimm at gmail.com> - 3.6.10-3
- Enable ehcache module (#845209)
- Use pom macros for module disablement
More information about the scm-commits
mailing list