Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Hudson-ci/Planning/Library Cleanup"

Line 24: Line 24:
  
 
<br>  
 
<br>  
 +
 +
DataContentHandler.java
  
 
{| width="100%" border="1" cellpadding="1" cellspacing="1" summary="Codebase Diffs"
 
{| width="100%" border="1" cellpadding="1" cellspacing="1" summary="Codebase Diffs"
Line 112: Line 114:
 
|-
 
|-
 
|  
 
|  
com.sun.<br>activation.viewers
+
com.sun.<br>activation.viewers  
  
 
| <strike>ImageViewer.java</strike>  
 
| <strike>ImageViewer.java</strike>  
Line 141: Line 143:
 
|  
 
|  
 
|-
 
|-
|  
+
| javax.activation
|  
+
| ActivationDataFlavor.java
|  
+
| 1
|  
+
| public boolean isMimeTypeEqual(String mimeType)
|  
+
| } catch (MimeTypeParseException e) {}
|  
+
| } catch (MimeTypeParseException e) {<br> '''// something didn't parse, do a crude comparison<br> return this.mimeType.equalsIgnoreCase(mimeType);'''<br> }
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>CommandInfo.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 156: Line 158:
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>CommandMap.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 163: Line 165:
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>CommandObject.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 170: Line 172:
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>DataContentHandler.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 177: Line 179:
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>DataContentHandlerFactory.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 184: Line 186:
 
|-
 
|-
 
|  
 
|  
|  
+
| DataHandler.java
|  
+
| 1
|  
+
| public DataFlavor[] getTransferDataFlavors()
|  
+
| public DataFlavor[] getTransferDataFlavors()
|  
+
| public '''synchronized '''DataFlavor[] getTransferDataFlavors()
 
|-
 
|-
 
|  
 
|  
 
|  
 
|  
|  
+
| 2
|  
+
| Object getTransferData(DataFlavor df, DataSource ds)
|  
+
| else if (df.equals(transferFlavors[0])) // only have one now
|  
+
| else if (df.equals('''getTransferDataFlavors()'''[0])) // only have one now
 
|-
 
|-
 
|  
 
|  
 
|  
 
|  
|  
+
| 3
|  
+
| public void writeTo(Object obj, String mimeType, OutputStream os)
|  
+
| if (dch != null)<br> dch.writeTo(obj, mimeType, os);<br> else<br> throw new UnsupportedDataTypeException(
|  
+
| if (dch != null)<br> dch.writeTo(obj, mimeType, os);<br> '''else if (obj instanceof byte[])<br> os.write((byte[])obj);<br> else if (obj instanceof String) {<br> OutputStreamWriter osw = new OutputStreamWriter(os);<br> osw.write((String)obj);<br> osw.flush();'''<br> } else<br> throw new UnsupportedDataTypeException(
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>DataSource.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 212: Line 214:
 
|-
 
|-
 
|  
 
|  
|  
+
| <strike>FileDataSource.java</strike>
 
|  
 
|  
 
|  
 
|  
Line 219: Line 221:
 
|-
 
|-
 
|  
 
|  
 +
| <strike>FileTypeMap.java</strike>
 
|  
 
|  
 
|  
 
|  
 
|  
 
|  
|  
+
| <br>
|
+
 
|-
 
|-
 
|  
 
|  
|  
+
| MailcapCommandMap.java
|  
+
| 1
|  
+
| public synchronized CommandInfo[] getPreferredCommands(String mimeType)
|  
+
| mimeType = mimeType.toLowerCase();
|  
+
| mimeType = mimeType.toLowerCase('''Locale.ENGLISH''');
 
|}
 
|}
  

Revision as of 05:32, 29 November 2011

Hudson Continuous Integration Server
Website
Download
Community
Mailing ListForumsIRCmattermost
Issues
OpenHelp WantedBug Day
Contribute
Browse Source
Hudson-bust.png Library Cleanup Project











Introduction

One of the major problems with the original Hudson code-base was the use of several of forked / patched 3rd party libraries. It's in no-one's interest to have to maintain separate code-bases in these cases and so we need to look at contributing any patches back to the original projects and removing the dependency on the patched versions This page tracks the libraries that we need to concentrate on as part of this process

JavaBeans Activation Framework

Hudson uses a patched version of activation.jar derived from git://github.com/kohsuke/javax.activation.git

The home of the base project is now the GlassFish Project: https://svn.java.net/svn/glassfish~svn/trunk/external/modules/activation

Tracking

This project is related to CQ: 5774

This project is tracked by BugZilla: 364988

Diffs

By package / source file:

Strikethrough indicates no significant diffs apart from comments / copyright. Bold used to indicate simple code change within a statement.


DataContentHandler.java

Package Class Diff Function Origional (1.1 JAF) Hudson
com.sun.
activation.registries
LogSupport.java
MailcapFile.java 1 public String[] getNativeCommands(String mime_type) List v = (List)native_commands.get(
mime_type.toLowerCase());
List v =
(List)native_commands.get(
mime_type.toLowerCase(Locale.ENGLISH));
2 protected void parseLine(String mailcapEntry) String primaryType = tokenizer.getCurrentTokenValue().toLowerCase(); String primaryType =
tokenizer.getCurrentTokenValue().toLowerCase(Locale.ENGLISH);
3 subType = tokenizer.getCurrentTokenValue().toLowerCase(); subType =
tokenizer.getCurrentTokenValue().toLowerCase(Locale.ENGLISH);
String paramName =
tokenizer.getCurrentTokenValue().toLowerCase();
String paramName = tokenizer.getCurrentTokenValue().
toLowerCase(Locale.ENGLISH);
MailcapParseException.java
MailcapTokenizer.java 1 public void setAutoquoteChar(char value)
Function Not Present
2 public int nextToken() if (isAutoquoting) {
if (!isAutoquoteSpecialChar(c)) {
processAutoquoteToken();
} else if ((c == ';') || (c == '=')) {
currentToken = c;
currentTokenValue = new Character(c).toString();
++dataIndex;
} else {
currentToken = UNKNOWN_TOKEN;
currentTokenValue = new Character(c).toString();
++dataIndex;
}
if (isAutoquoting) {
if (c == ';' || c == '=') {
currentToken = c;
currentTokenValue = new Character(c).toString();
++dataIndex;
} else {
processAutoquoteToken();
}
3 public static boolean isAutoquoteSpecialChar(char c) Function Not Present
MimeTypeEntry.java
MimeTypeFile.java

com.sun.
activation.viewers

ImageViewer.java
ImageViewerCanvas.java
TextEditor.java 1 public void setInputStream(InputStream ins) // make sure we got one
if(fos == null) {
System.out.println("Invalid outputstream in TextEditor!");
System.out.println("not saving!");
}
// make sure we got one
if(fos == null) {
System.out.println("Invalid outputstream in TextEditor!");
System.out.println("not saving!");
return;
}
TextViewer.java
javax.activation ActivationDataFlavor.java 1 public boolean isMimeTypeEqual(String mimeType) } catch (MimeTypeParseException e) {} } catch (MimeTypeParseException e) {
// something didn't parse, do a crude comparison
return this.mimeType.equalsIgnoreCase(mimeType);

}
CommandInfo.java
CommandMap.java
CommandObject.java
DataContentHandler.java
DataContentHandlerFactory.java
DataHandler.java 1 public DataFlavor[] getTransferDataFlavors() public DataFlavor[] getTransferDataFlavors() public synchronized DataFlavor[] getTransferDataFlavors()
2 Object getTransferData(DataFlavor df, DataSource ds) else if (df.equals(transferFlavors[0])) // only have one now else if (df.equals(getTransferDataFlavors()[0])) // only have one now
3 public void writeTo(Object obj, String mimeType, OutputStream os) if (dch != null)
dch.writeTo(obj, mimeType, os);
else
throw new UnsupportedDataTypeException(
if (dch != null)
dch.writeTo(obj, mimeType, os);
else if (obj instanceof byte[])
os.write((byte[])obj);
else if (obj instanceof String) {
OutputStreamWriter osw = new OutputStreamWriter(os);
osw.write((String)obj);
osw.flush();

} else
throw new UnsupportedDataTypeException(
DataSource.java
FileDataSource.java
FileTypeMap.java
MailcapCommandMap.java 1 public synchronized CommandInfo[] getPreferredCommands(String mimeType) mimeType = mimeType.toLowerCase(); mimeType = mimeType.toLowerCase(Locale.ENGLISH);

Xstream XML Parser

Husdon uses a patched version of xstream:

The home of the base project is on Codehaus: http://svn.codehaus.org/xstream/trunk/

Tracking

This project is related to CQ: 5771

This project is tracked by BugZilla:

Diffs

The issues tracking the diffs on Codehaus are: http://jira.codehaus.org/browse/XSTR-676 http://jira.codehaus.org/browse/XSTR-675 http://jira.codehaus.org/browse/XSTR-674

Back to the top