Bug 973224

Summary: resteasy-base must be split into subpackages to simplify dependencies
Product: Red Hat Enterprise Linux 7 Reporter: Stanislav Ochotnicky <sochotni>
Component: resteasy-baseAssignee: Ade Lee <alee>
Status: CLOSED CURRENTRELEASE QA Contact: Asha Akkiangady <aakkiang>
Severity: urgent Docs Contact:
Priority: high    
Version: 7.0CC: alee, edewata, jgalipea, mizdebsk, nkinder, rpattath
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-13 09:17:45 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
srpm for phase 1
none
new spec file
none
srpm for phase 2
none
new spec file for phase 2
none
diff for pki-core spec file none

Description Stanislav Ochotnicky 2013-06-11 13:41:58 UTC
Description of problem:
Currently resteasy-base pulls in following list of java packages:
apache-commons-cli
apache-commons-codec
apache-commons-collections
apache-commons-lang
apache-commons-logging
apache-mime4j >= 0.7.2-2
bea-stax
bouncycastle
bouncycastle-mail
cglib
dnsjava
geronimo-annotation
glassfish-fastinfoset
glassfish-jaxb >= 2.2.5-2
glassfish-jaxb-api
google-guice
httpcomponents-client
httpcomponents-core
httpunit
jackson
jakarta-commons-httpclient
java
javamail
javassist
jboss-servlet-2.5-api
jboss-servlet-3.0-api
jcip-annotations
jettison
jpackage-utils
scannotation
slf4j
snakeyaml
tomcat-el-2.2-api
ws-jaxme
xerces-j2

This dependency chain is *huge* for single package. Resteasy-base contains 28 jar files (half of which are -jandex.jar so I guess we can say 14). That means at least 14 subpackages should be created each with separate set of requires. 

That way pki-server would not pull in whole java stack into base repository/composes

Version-Release number of selected component (if applicable):
resteasy-base-0:2.3.2-11.el7.noarch

How reproducible:
always

Steps to Reproduce:
1. rpm -q --requires resteasy-base


Additional info:
Package currently uses old Maven packaging style. By using XMvn/%mvn_build/%mvn_install macro with singleton packaging it would be possible to automatically generate subpackage file listing and requires. Good example is maven-surefire spec file http://pkgs.devel.redhat.com/cgit/rpms/maven-surefire/tree/maven-surefire.spec?h=rhel-7.0 (see lines 138-140)

Comment 2 Ade Lee 2013-07-03 15:58:19 UTC
We are going to do this in two phases.  In this first phase, I am going to trim down the list of dependencies by reducing the number of modules built to just those used by pki-core, seeing as pki-core is the only project that uses resteasy-base.

This reduces the number of jars considerably to 7 jar files (14 if you count jandex) and drops the Requires list to:

apache-commons-logging
bea-stax
geronimo-annotation
glassfish-jaxb >= 0:2.2.5-2
glassfish-jaxb-api
httpcomponents-client
httpcomponents-core
jackson
jakarta-commons-httpclient
java
javamail
javassist
jboss-servlet-2.5-api
jboss-servlet-3.0-api
jettison
jpackage-utils
scannotation
slf4j
ws-jaxme
xerces-j2

At tis point, I'm not sure its worthwhile splitting into different subpackages, but we will change to use the new build commands nonetheless.

Comment 3 Ade Lee 2013-07-03 16:03:41 UTC
Created attachment 768323 [details]
srpm for phase 1

srpm for phase 1

Comment 4 Ade Lee 2013-07-03 16:05:28 UTC
Created attachment 768325 [details]
new spec file

Comment 5 Ade Lee 2013-07-09 16:08:48 UTC
Created attachment 771103 [details]
srpm for phase 2

With help from msrb, here is a new srpm which uses the new packaging style and splits everything into separate sub packages.

Comment 6 Ade Lee 2013-07-09 16:09:33 UTC
Created attachment 771104 [details]
new spec file for phase 2

Comment 7 Ade Lee 2013-07-09 16:22:31 UTC
Created attachment 771110 [details]
diff for pki-core spec file

Comment 8 Ade Lee 2013-07-10 20:18:57 UTC
Committed as above.

Comment 10 Jenny Severance 2014-01-29 21:56:20 UTC
# rpm -q resteasy-base
resteasy-base-2.3.5-2.el7.noarch


]# cat /etc/redhat-release 
Red Hat Enterprise Linux Server release 7.0 Beta (Maipo)

Is this the expected list??

# rpm -q --requires resteasy-base
resteasy-base-atom-provider = 2.3.5-2.el7
resteasy-base-jackson-provider = 2.3.5-2.el7
resteasy-base-jaxb-provider = 2.3.5-2.el7
resteasy-base-jaxrs = 2.3.5-2.el7
resteasy-base-jaxrs-all = 2.3.5-2.el7
resteasy-base-jaxrs-api = 2.3.5-2.el7
resteasy-base-jettison-provider = 2.3.5-2.el7
resteasy-base-providers-pom = 2.3.5-2.el7
resteasy-base-tjws = 2.3.5-2.el7
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1

Comment 11 Ade Lee 2014-02-26 15:18:14 UTC
Looks ok to me.  There is also a javadoc rpm, but of course thats not required for runtime.

resteasy-base-javadoc-2.3.5-2.el7.noarch.rpm

Comment 12 Roshni 2014-02-26 15:45:01 UTC
Verified on resteasy-base-2.3.5-2.el7.noarch

Comment 13 Ludek Smid 2014-06-13 09:17:45 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.