-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
IDEMPIERE-3136:all stuff relate library of idempiere
update jetty to 9.3.10 work-around for: jetty/jetty.project#262 jetty/jetty.project#704
- Loading branch information
Showing
59 changed files
with
14,234 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<classpath> | ||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/> | ||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> | ||
<classpathentry kind="src" path="src/"/> | ||
<classpathentry kind="output" path="bin"/> | ||
</classpath> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>org.eclipse.jetty.http</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ManifestBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.SchemaBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.pde.ds.core.builder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.pde.PluginNature</nature> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
</natures> | ||
</projectDescription> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
Manifest-Version: 1.0 | ||
Archiver-Version: Plexus Archiver | ||
Created-By: Apache Maven Bundle Plugin | ||
Built-By: joakim | ||
Build-Jdk: 1.8.0_65 | ||
Implementation-Vendor: Eclipse.org - Jetty | ||
Implementation-Version: 9.3.10.v20160621 | ||
url: http://www.eclipse.org/jetty | ||
Bnd-LastModified: 1457969504223 | ||
Bundle-Classpath: . | ||
Bundle-Copyright: Copyright (c) 2008-2016 Mort Bay Consulting Pty. Ltd. | ||
Bundle-Description: Jetty module for Jetty :: Http Utility | ||
Bundle-DocURL: http://www.eclipse.org/jetty | ||
Bundle-License: http://www.apache.org/licenses/LICENSE-2.0, http://www | ||
.eclipse.org/org/documents/epl-v10.php | ||
Bundle-ManifestVersion: 2 | ||
Bundle-Name: Jetty :: Http Utility | ||
Bundle-RequiredExecutionEnvironment: JavaSE-1.8 | ||
Bundle-SymbolicName: org.eclipse.jetty.http | ||
Bundle-Vendor: Eclipse Jetty Project | ||
Bundle-Version: 9.3.10.v20160621 | ||
Export-Package: org.eclipse.jetty.http;version="9.3.10";uses:="org.ecl | ||
ipse.jetty.util,org.eclipse.jetty.util.log,org.eclipse.jetty.util.res | ||
ource",org.eclipse.jetty.http.pathmap;version="9.3.10";uses:="org.ecl | ||
ipse.jetty.util.annotation,org.eclipse.jetty.util.component",org.ecli | ||
pse.jetty.http2.hpack;version="9.3.10";uses:="org.eclipse.jetty.http, | ||
org.eclipse.jetty.util.log" | ||
Import-Package: org.eclipse.jetty.util;version="[9.3.10,9.3.11)",org.e | ||
clipse.jetty.util.annotation;version="[9.3.10,9.3.11)",org.eclipse.je | ||
tty.util.component;version="[9.3.10,9.3.11)",org.eclipse.jetty.util.l | ||
og;version="[9.3.10,9.3.11)",org.eclipse.jetty.util.resource;version= | ||
"[9.3.10,9.3.11)" | ||
Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.8))" | ||
Tool: Bnd-2.4.1.201501161923 | ||
|
2 changes: 2 additions & 0 deletions
2
org.eclipse.jetty.http/META-INF/services/org.eclipse.jetty.http.HttpFieldPreEncoder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
org.eclipse.jetty.http.Http1FieldPreEncoder | ||
org.eclipse.jetty.http2.hpack.HpackFieldPreEncoder |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" | ||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | ||
<html xmlns="http://www.w3.org/1999/xhtml"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> | ||
<title>About</title> | ||
</head> | ||
<body lang="EN-US"> | ||
<h2>About This Content</h2> | ||
|
||
<p>19 May, 2009</p> | ||
<h3>License</h3> | ||
|
||
<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). The Content is dual licensed and is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 ("EPL") as well as the Apache Software License Version 2.0. A copy of the EPL is available | ||
at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. A copy of the ASL is available at <a href="http://www.apache.org/licenses/LICENSE-2.0.html">http://www.apache.org/licenses/LICENSE-2.0.html</a>. For purposes of the EPL, "Program" will mean the Content.</p> | ||
|
||
<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is being redistributed by another party ("Redistributor") and different terms and conditions may apply to your use of any object code in the Content. Check the Redistributor's license that was provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise indicated below, the terms and conditions of the EPL still apply to any source code in the Content and such source code may be obtained at <a href="http://www.eclipse.org">http://www.eclipse.org</a>.</p> | ||
|
||
<p><b>jetty-util</b> artifact only:<br/><br/>The UnixCrypt.java code implements the one way cryptography used by | ||
Unix systems for simple password protection. Copyright 1996 Aki Yoshida, | ||
modified April 2001 by Iris Van den Broeke, Daniel Deville. | ||
Permission to use, copy, modify and distribute UnixCrypt | ||
for non-commercial or commercial purposes and without fee is | ||
granted provided that the copyright notice appears in all copies.</p> | ||
|
||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
source.. = src/ | ||
output.. = bin/ | ||
bin.includes = META-INF/,\ | ||
. |
71 changes: 71 additions & 0 deletions
71
org.eclipse.jetty.http/src/org/eclipse/jetty/http/BadMessageException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995-2016 Mort Bay Consulting Pty. Ltd. | ||
// ------------------------------------------------------------------------ | ||
// All rights reserved. This program and the accompanying materials | ||
// are made available under the terms of the Eclipse Public License v1.0 | ||
// and Apache License v2.0 which accompanies this distribution. | ||
// | ||
// The Eclipse Public License is available at | ||
// http://www.eclipse.org/legal/epl-v10.html | ||
// | ||
// The Apache License v2.0 is available at | ||
// http://www.opensource.org/licenses/apache2.0.php | ||
// | ||
// You may elect to redistribute this code under either of these licenses. | ||
// ======================================================================== | ||
// | ||
|
||
package org.eclipse.jetty.http; | ||
|
||
/* ------------------------------------------------------------------------------- */ | ||
/** | ||
* <p>Exception thrown to indicate a Bad HTTP Message has either been received | ||
* or attempted to be generated. Typically these are handled with either 400 | ||
* or 500 responses.</p> | ||
*/ | ||
@SuppressWarnings("serial") | ||
public class BadMessageException extends RuntimeException | ||
{ | ||
final int _code; | ||
final String _reason; | ||
|
||
public BadMessageException() | ||
{ | ||
this(400,null); | ||
} | ||
|
||
public BadMessageException(int code) | ||
{ | ||
this(code,null); | ||
} | ||
|
||
public BadMessageException(String reason) | ||
{ | ||
this(400,reason); | ||
} | ||
|
||
public BadMessageException(int code, String reason) | ||
{ | ||
super(code+": "+reason); | ||
_code=code; | ||
_reason=reason; | ||
} | ||
|
||
public BadMessageException(int code, String reason, Throwable cause) | ||
{ | ||
super(code+": "+reason, cause); | ||
_code=code; | ||
_reason=reason; | ||
} | ||
|
||
public int getCode() | ||
{ | ||
return _code; | ||
} | ||
|
||
public String getReason() | ||
{ | ||
return _reason; | ||
} | ||
} |
173 changes: 173 additions & 0 deletions
173
org.eclipse.jetty.http/src/org/eclipse/jetty/http/DateGenerator.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,173 @@ | ||
// | ||
// ======================================================================== | ||
// Copyright (c) 1995-2016 Mort Bay Consulting Pty. Ltd. | ||
// ------------------------------------------------------------------------ | ||
// All rights reserved. This program and the accompanying materials | ||
// are made available under the terms of the Eclipse Public License v1.0 | ||
// and Apache License v2.0 which accompanies this distribution. | ||
// | ||
// The Eclipse Public License is available at | ||
// http://www.eclipse.org/legal/epl-v10.html | ||
// | ||
// The Apache License v2.0 is available at | ||
// http://www.opensource.org/licenses/apache2.0.php | ||
// | ||
// You may elect to redistribute this code under either of these licenses. | ||
// ======================================================================== | ||
// | ||
|
||
package org.eclipse.jetty.http; | ||
|
||
import java.util.Calendar; | ||
import java.util.GregorianCalendar; | ||
import java.util.TimeZone; | ||
|
||
import org.eclipse.jetty.util.StringUtil; | ||
|
||
/** | ||
* ThreadLocal Date formatters for HTTP style dates. | ||
*/ | ||
public class DateGenerator | ||
{ | ||
private static final TimeZone __GMT = TimeZone.getTimeZone("GMT"); | ||
static | ||
{ | ||
__GMT.setID("GMT"); | ||
} | ||
|
||
static final String[] DAYS = | ||
{ "Sat", "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"}; | ||
static final String[] MONTHS = | ||
{ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "Jan"}; | ||
|
||
|
||
private static final ThreadLocal<DateGenerator> __dateGenerator =new ThreadLocal<DateGenerator>() | ||
{ | ||
@Override | ||
protected DateGenerator initialValue() | ||
{ | ||
return new DateGenerator(); | ||
} | ||
}; | ||
|
||
|
||
public final static String __01Jan1970=DateGenerator.formatDate(0); | ||
|
||
/** | ||
* Format HTTP date "EEE, dd MMM yyyy HH:mm:ss 'GMT'" | ||
* @param date the date in milliseconds | ||
* @return the formatted date | ||
*/ | ||
public static String formatDate(long date) | ||
{ | ||
return __dateGenerator.get().doFormatDate(date); | ||
} | ||
|
||
/** | ||
* Format "EEE, dd-MMM-yyyy HH:mm:ss 'GMT'" for cookies | ||
* @param buf the buffer to put the formatted date into | ||
* @param date the date in milliseconds | ||
*/ | ||
public static void formatCookieDate(StringBuilder buf, long date) | ||
{ | ||
__dateGenerator.get().doFormatCookieDate(buf,date); | ||
} | ||
|
||
/** | ||
* Format "EEE, dd-MMM-yyyy HH:mm:ss 'GMT'" for cookies | ||
* @param date the date in milliseconds | ||
* @return the formatted date | ||
*/ | ||
public static String formatCookieDate(long date) | ||
{ | ||
StringBuilder buf = new StringBuilder(28); | ||
formatCookieDate(buf, date); | ||
return buf.toString(); | ||
} | ||
|
||
private final StringBuilder buf = new StringBuilder(32); | ||
private final GregorianCalendar gc = new GregorianCalendar(__GMT); | ||
|
||
/** | ||
* Format HTTP date "EEE, dd MMM yyyy HH:mm:ss 'GMT'" | ||
* @param date the date in milliseconds | ||
* @return the formatted date | ||
*/ | ||
public String doFormatDate(long date) | ||
{ | ||
buf.setLength(0); | ||
gc.setTimeInMillis(date); | ||
|
||
int day_of_week = gc.get(Calendar.DAY_OF_WEEK); | ||
int day_of_month = gc.get(Calendar.DAY_OF_MONTH); | ||
int month = gc.get(Calendar.MONTH); | ||
int year = gc.get(Calendar.YEAR); | ||
int century = year / 100; | ||
year = year % 100; | ||
|
||
int hours = gc.get(Calendar.HOUR_OF_DAY); | ||
int minutes = gc.get(Calendar.MINUTE); | ||
int seconds = gc.get(Calendar.SECOND); | ||
|
||
buf.append(DAYS[day_of_week]); | ||
buf.append(','); | ||
buf.append(' '); | ||
StringUtil.append2digits(buf, day_of_month); | ||
|
||
buf.append(' '); | ||
buf.append(MONTHS[month]); | ||
buf.append(' '); | ||
StringUtil.append2digits(buf, century); | ||
StringUtil.append2digits(buf, year); | ||
|
||
buf.append(' '); | ||
StringUtil.append2digits(buf, hours); | ||
buf.append(':'); | ||
StringUtil.append2digits(buf, minutes); | ||
buf.append(':'); | ||
StringUtil.append2digits(buf, seconds); | ||
buf.append(" GMT"); | ||
return buf.toString(); | ||
} | ||
|
||
/** | ||
* Format "EEE, dd-MMM-yy HH:mm:ss 'GMT'" for cookies | ||
* @param buf the buffer to format the date into | ||
* @param date the date in milliseconds | ||
*/ | ||
public void doFormatCookieDate(StringBuilder buf, long date) | ||
{ | ||
gc.setTimeInMillis(date); | ||
|
||
int day_of_week = gc.get(Calendar.DAY_OF_WEEK); | ||
int day_of_month = gc.get(Calendar.DAY_OF_MONTH); | ||
int month = gc.get(Calendar.MONTH); | ||
int year = gc.get(Calendar.YEAR); | ||
year = year % 10000; | ||
|
||
int epoch = (int) ((date / 1000) % (60 * 60 * 24)); | ||
int seconds = epoch % 60; | ||
epoch = epoch / 60; | ||
int minutes = epoch % 60; | ||
int hours = epoch / 60; | ||
|
||
buf.append(DAYS[day_of_week]); | ||
buf.append(','); | ||
buf.append(' '); | ||
StringUtil.append2digits(buf, day_of_month); | ||
|
||
buf.append('-'); | ||
buf.append(MONTHS[month]); | ||
buf.append('-'); | ||
StringUtil.append2digits(buf, year/100); | ||
StringUtil.append2digits(buf, year%100); | ||
|
||
buf.append(' '); | ||
StringUtil.append2digits(buf, hours); | ||
buf.append(':'); | ||
StringUtil.append2digits(buf, minutes); | ||
buf.append(':'); | ||
StringUtil.append2digits(buf, seconds); | ||
buf.append(" GMT"); | ||
} | ||
} |
Oops, something went wrong.