click here for details... Sakai Executive Director Position Search now open
Issue Details (XML | Word | Printable)

Key: SAK-7408
Type: Task Task
Status: Closed Closed
Resolution: Fixed
Priority: Blocker Blocker
Assignee: Andrew Poland
Reporter: Josh Holtzman
Votes: 0
Watchers: 3
Operations

If you were logged in you would be able to see more operations.
Sakai

Remove dependencies on tomcat 1.4 compatibility pack

Created: 15-Dec-2006 11:15   Updated: 23-Oct-2008 10:47
Component/s: Global
Affects Version/s: 2.4.0
Fix Version/s: 2.4.0

Time Tracking:
Not Specified

Issue Links:
Incorporate
 
Relate
 

2.6.x Status: None
2.5.x Status: None
2.4.x Status: None


 Description  « Hide
Now that we require java 1.5, we should remove the dependencies on the tomcat 1.4 compatibility pack from our code.

The first step in removing this dependency is to rename all org.apache.foo xml api imports to use com.sun.org.apache.foo.internal and remove maven dependencies on xalan and xerces.

Once the code builds and runs properly, we need to migrate away from these sun-specific imports to use the generic javax.xml packages. This will be the responsibility of each tool/service developer.

------------------------------------------------------------------

To-Do List:



 All   Comments   Work Log   Change History   Subversion Commits   git Commits      Sort Order: Ascending order - Click to sort in descending order
Josh Holtzman added a comment - 15-Dec-2006 15:41
Step 1 complete as of r19623

Beth Kirschner added a comment - 08-Jan-2007 10:22
Step 2 completed for calendar tool in revision 20159 (removing sun-specific imports).

Beth Kirschner added a comment - 08-Jan-2007 13:52
Step 2 completed for OSP in revision 20182 (removing sun-specific imports)

Peter A. Knoop added a comment - 12-Mar-2007 10:24
This issue is currently scheduled to be addressed for the 2.4 release. There are only 3 days left until code freeze. If know already that this issue will not be addressed for 2.4, please updated the Fix Version with a new estimate of when it will be addressed. Thanks.

Josh Holtzman added a comment - 16-Mar-2007 09:34
Peter, so what you're saying is that 2.4 will only compile and run on the sun JDK. Is the foundation OK with this?

Josh Holtzman added a comment - 16-Mar-2007 09:43
The following eclipse projects import com.sun.org.apache packages. These must be fixed before 2.4 if we want to remain jdk vendor agnostic.

web-impl
util-util
syllabus
sam
rwiki-util
rwiki-impl
podcasts
osid
news-impl
messageforums
help
content-impl
archive-impl

Peter A. Knoop added a comment - 16-Mar-2007 12:10
Hi Josh, the comment above as bulk-added to all Tasks that are scheduled for 2.4 but have not been addressed yet, so that their fix version could be updated to more accurately reflect when they will get addressed... or, to raise a red-flag so that someone in the know can do something about the issue. This sounds like something that needs to be brought up on sakai-dev so that all the remaining projects have a chance to fix things for 2.4. (I've also bumped the priority on this to Blocker.)

Josh Holtzman added a comment - 16-Mar-2007 15:19
Updated help to use javax.xml APIs.

Ian Boston added a comment - 18-Mar-2007 07:45
Fixed rwiki-util and rwiki-impl

Still need Xerces and Xalan in its own classloader as it does custom serialization.



Karen Tsao added a comment - 28-Mar-2007 09:56
Fixed sam.

Jim Eng added a comment - 06-Apr-2007 07:42
Could somebody provide specifics about how Base64 encoding/decoding should be handled? That seems to be the part that is at issue in content-impl. Also, is Peter's description of step one ("rename all org.apache.foo xml api imports to use com.sun.org.apache.foo.internal") correct? Other comments seem to say the opposite.

Josh Holtzman added a comment - 06-Apr-2007 08:07
Step one was completed a while ago... this is what allowed us to remove the compat pack quickly. Removing the com.sun.* imports is the "clean up" needed from to deal with our quick-and-dirty removal of the compat pack.

As for base64 encoding / decoding, can you use commons-codec?

Peter A. Knoop added a comment - 06-Apr-2007 12:30
Removed osid from the to-do list.

Megan May added a comment - 06-Apr-2007 12:58
Perhaps we should have subtasks for each component?

Ian Boston added a comment - 09-Apr-2007 07:56
Fixed Conent Impl

Steve Smail added a comment - 11-Apr-2007 06:41
This issue also applied to the web2bridge OSID implementation in the citations tree.

The web2bridge implementation has been corrected.

Andrew Poland added a comment - 11-Apr-2007 10:40
fixed podcasts, r28654

Ian Boston added a comment - 11-Apr-2007 10:46
Here is a list of all the remaining locations of classes in the JVM.

One addtion is the blog tool which uses JPEG classes from within the JVM

The only dificult ones are

import com.sun.image.codec.jpeg.JPEGCodec;
import com.sun.image.codec.jpeg.JPEGEncodeParam;
import com.sun.image.codec.jpeg.JPEGImageEncoder;
./blog/tool/src/java/uk/ac/lancs/e_science/sakai/tools/blogger/util/JpegTransformer.java

and
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
import com.sun.org.apache.xml.internal.serialize.OutputFormat;
import com.sun.org.apache.xml.internal.serialize.XMLSerializer;
./util/util-util/util/src/java/org/sakaiproject/util/Xml.java

this is as of r28540 (ie before the podcast fix)

import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./archive/archive-impl/impl/src/java/org/sakaiproject/archive/impl/BasicArchiveService.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./archive/archive-impl/impl2/src/java/org/sakaiproject/archive/impl/ArchiveService2Impl.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./archive/archive-impl/impl2/src/java/org/sakaiproject/archive/impl/SiteMerger.java
import com.sun.image.codec.jpeg.JPEGCodec;
import com.sun.image.codec.jpeg.JPEGEncodeParam;
import com.sun.image.codec.jpeg.JPEGImageEncoder;
./blog/tool/src/java/uk/ac/lancs/e_science/sakai/tools/blogger/util/JpegTransformer.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./msgcntr/messageforums-component-impl/src/java/org/sakaiproject/component/app/messageforums/DiscussionForumServiceImpl.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./podcasts/podcasts/src/java/org/sakaiproject/tool/podcasts/RSSPodfeedServlet.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./syllabus/syllabus-impl/src/java/org/sakaiproject/component/app/syllabus/SyllabusServiceImpl.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
import com.sun.org.apache.xml.internal.serialize.OutputFormat;
import com.sun.org.apache.xml.internal.serialize.XMLSerializer;
./util/util-util/util/src/java/org/sakaiproject/util/Xml.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./web/news-impl/impl/src/java/org/sakaiproject/news/impl/BasicNewsService.java
import com.sun.org.apache.xerces.internal.impl.dv.util.Base64;
./web/web-impl/impl/src/java/org/sakaiproject/web/impl/WebServiceImpl.java

Andrew Poland added a comment - 11-Apr-2007 10:54
fixed message center, r28656

Josh Holtzman added a comment - 11-Apr-2007 11:02
commons-codec's base64 utility (see http://jakarta.apache.org/commons/codec/api-release/org/apache/commons/codec/binary/Base64.html) should be able to replace the xerces base64 imports. And javax.xml.Transformer should be able to replace XMLSerializer:

Transformer transformer = TransformerFactory.newInstance().newTransformer();
transformer.transform( new DOMSource(node), new StreamResult(out) );

As for the JPEG encoding, is there something in the javax.imageio package that would work? See http://java.sun.com/j2se/1.4.2/docs/api/javax/imageio/package-summary.html

Peter A. Knoop added a comment - 11-Apr-2007 11:05
SAK-9433 and SAK-9434 address Podcast and Message Center pieces.

Ian Boston added a comment - 11-Apr-2007 13:27
Fixed archive

Peter A. Knoop added a comment - 11-Apr-2007 13:30
I"ve emailed Adrian and asked him to look at the Blog-related part of this issue.

Ian Boston added a comment - 11-Apr-2007 13:37
Fixed sylabus

Ian Boston added a comment - 11-Apr-2007 13:54
Fixed news and web

Ian Boston added a comment - 11-Apr-2007 14:17
Fixed xml

Andrew Poland added a comment - 11-Apr-2007 16:21
merged osid to 2-4-x r28694

Andrew Poland added a comment - 11-Apr-2007 16:35
merged content to 2-4-x r28695
merged citations to 2-4-x r28696
merged podcasts to 2-4-x r28697
merged search to 2-4-x r28698
merged msgcntr to 2-4-x r28699
merged archive to 2-4-x r28700
merged syllabus to 2-4-x r28701
merged web to 2-4-x r28703
merged util to 2-4-x r28704

Steve Smail added a comment - 17-Apr-2007 07:39
I wanted to note that I have verified the citations/web2bridge changes in the QA-010 release.

Megan May added a comment - 17-Apr-2007 16:05
Adding .011 tag as fix version as this item is up for discussion at the release meeting tomorrow. Issues not included will be set back to solely have a nightly2 fix version and will contain a note with reasoning for not including it.

Peter A. Knoop added a comment - 18-Apr-2007 14:26
Resolving to cover changes made to-date. Reamining jvm-idenpendence issues will be catpured in a new issue. Please include current revisions in 011.

Andrew Poland added a comment - 18-Apr-2007 15:30
merged to 2-4-x r29108

Andrew Poland added a comment - 18-Apr-2007 15:30
merged to 2-4-x r29109

Peter A. Knoop added a comment - 20-Apr-2007 07:35
All of the dependencies have been removed, as originally described in the task. Please open a new bug issue for any problems encountered or a new task for any other dependencies.