Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tjws removal #928

Merged
merged 25 commits into from
Sep 8, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
527afd8
Removing commented out lines
asoldano Sep 6, 2016
2a75d67
Replace use of deprecated apis in UndertowJaxrsServer
asoldano Sep 6, 2016
07172e0
Remove test commented out since 2013, dropped two dependencies in pom
asoldano Sep 6, 2016
d4c359b
Remove resteasy-jettison dependency on resteasy-testsuite just becase…
asoldano Sep 6, 2016
66cc6c1
resteasy-netty4 / resteasy-undertow: change underlying server impleme…
asoldano Sep 6, 2016
0ece264
resteasy-links tests: replace tjws embedded server with netty4 server
asoldano Sep 6, 2016
3aae46f
resteasy-guice: replace tjws with netty4
asoldano Sep 6, 2016
b71e0d4
resteasy-cache-core: replace tjws with netty4
asoldano Sep 6, 2016
ff7596b
keystone-core: replace tjws with netty4
asoldano Sep 6, 2016
8ff185d
resteasy-yaml-provider: remove useless dependencies
asoldano Sep 6, 2016
dcfb079
resteasy-yaml-provider: adding missing file
asoldano Sep 6, 2016
6f7250f
skeleton-key-core: removed useless dependencies
asoldano Sep 6, 2016
b0b119c
skeleton-key-idp: replace tjws with netty4
asoldano Sep 6, 2016
506f5d3
resteasy-crypto: replace tjws with netty4
asoldano Sep 6, 2016
763406e
resteasy-spring: deprecate implementation relying on TJWS and simplif…
asoldano Sep 7, 2016
3f2bfb3
resteasy-profiling-tests: removed useless dependency to tjws
asoldano Sep 7, 2016
53ffde1
fastinfoset provider: removed useless dependencies
asoldano Sep 7, 2016
9994b35
resteasy-atom-provider: removed useless dependencies
asoldano Sep 7, 2016
385a607
resteasy-html: dependencies cleanup
asoldano Sep 7, 2016
6195c97
resteasy-multipart-provider / resteasy-validator-provider-11: useless…
asoldano Sep 7, 2016
9fae8e2
resteasy-keystone-as7 / resteasy-keystone-as7 / resteasy-jose-jwt / r…
asoldano Sep 7, 2016
eeeebd6
resteasy-netty / resteasy-servlet-initializer / resteasy-cdi: remove …
asoldano Sep 7, 2016
1153950
Move WADLUndertowContainerTests to resteasy-wadl-undertow connector w…
asoldano Sep 7, 2016
7b40165
Moved WADL tests to resteasy-wadl module and fixed/refactored them to…
asoldano Sep 7, 2016
c93439f
Remove resteasy-jaxrs-testsuite module which is not needed anymore
asoldano Sep 7, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions integration-tests/profiling-tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,6 @@
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.1_spec</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>tjws</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
</dependencies>


Expand Down
3 changes: 0 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,6 @@
<module>resteasy-test-data</module>
<module>resteasy-jaxrs</module>
<module>resteasy-client</module>
<module>resteasy-jaxrs-testsuite</module>
<module>providers</module>
<module>resteasy-bom</module>
<module>resteasy-cache</module>
Expand Down Expand Up @@ -198,7 +197,6 @@
<module>resteasy-test-data</module>
<module>resteasy-jaxrs</module>
<module>resteasy-client</module>
<module>resteasy-jaxrs-testsuite</module>
<module>providers</module>
<module>resteasy-bom</module>
<module>resteasy-cache</module>
Expand Down Expand Up @@ -227,7 +225,6 @@
<module>resteasy-test-data</module>
<module>resteasy-jaxrs</module>
<module>resteasy-client</module>
<module>resteasy-jaxrs-testsuite</module>
<module>providers</module>
<module>resteasy-bom</module>
<module>resteasy-cache</module>
Expand Down
30 changes: 0 additions & 30 deletions providers/fastinfoset/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@
<description/>

<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs</artifactId>
Expand All @@ -33,23 +29,6 @@
<groupId>com.sun.xml.fastinfoset</groupId>
<artifactId>FastInfoset</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.1_spec</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>tjws</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<!--
<dependency>
<groupId>tjws</groupId>
<artifactId>webserver</artifactId>
<scope>test</scope>
</dependency>
-->
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
Expand All @@ -62,17 +41,8 @@
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-processor</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs-testsuite</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>

</dependencies>



<profiles>
<profile>
<id>i18n</id>
Expand Down
6 changes: 0 additions & 6 deletions providers/jettison/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,6 @@
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-processor</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs-testsuite</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import org.junit.Assert;

import org.jboss.resteasy.plugins.providers.jaxb.json.i18n.Messages;
import org.jboss.resteasy.test.resteasy_jaxrs.i18n.TestMessagesParent;
import org.junit.Test;

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.jboss.resteasy.test.resteasy_jaxrs.i18n;
package org.jboss.resteasy.test.i18n;

import java.io.InputStream;
import java.util.Locale;
Expand Down
18 changes: 0 additions & 18 deletions providers/multipart/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,6 @@
<artifactId>jboss-servlet-api_3.1_spec</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>tjws</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jboss.weld.se</groupId>
<artifactId>weld-se</artifactId>
<version>2.1.0.Final</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
</dependency>
Expand All @@ -64,12 +52,6 @@
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-processor</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs-testsuite</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
Expand Down
25 changes: 0 additions & 25 deletions providers/resteasy-atom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,6 @@
<artifactId>resteasy-jaxb-provider</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.1_spec</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs-testsuite</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>tjws</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.spec.javax.annotation</groupId>
<artifactId>jboss-annotations-api_1.2_spec</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-annotations</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import org.junit.Assert;

import org.jboss.resteasy.plugins.providers.resteasy_atom.i18n.Messages;
import org.jboss.resteasy.test.resteasy_jaxrs.i18n.TestMessagesParent;
import org.junit.Test;

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
package org.jboss.resteasy.test.i18n;

import java.io.InputStream;
import java.util.Locale;
import java.util.Properties;

import org.junit.AfterClass;
import org.junit.BeforeClass;

/**
*
* @author <a href="ron.sigal@jboss.com">Ron Sigal</a>
* @version $Revision: 1.1 $
*
* Copyright Oct 8, 2014
*/
abstract public class TestMessagesParent
{
static protected Locale savedLocale;
protected Properties properties = new Properties();

@BeforeClass
static public void beforeClass()
{
savedLocale = Locale.getDefault();
}

@AfterClass
static public void afterClass()
{
Locale.setDefault(savedLocale);
System.out.println("Reset default locale to: " + savedLocale);
}

public boolean before(Locale locale, String filename) throws Exception
{
System.out.println("default locale: " + Locale.getDefault());
Locale.setDefault(locale);
System.out.println("Set default locale to: " + locale);
System.out.println("Messages file: " + filename);
InputStream is = getClass().getClassLoader().getResourceAsStream(filename);
if (is == null)
{
return false;
}
properties.load(is);
return getExpectedNumberOfMethods() == properties.size();
}

protected String getExpected(String id, String message, Object... args)
{
String expected = "RESTEASY" + id + ": " + String.format(replacePositionalSpecifiers(String.class.cast(properties.get(message))), args);
System.out.println("expected: " + expected);
return expected;
}

protected String replacePositionalSpecifiers(String s)
{
// System.out.println("before: " + s);
int pos0 = s.indexOf("{0}");
if (pos0 > -1)
{
s = s.substring(0, pos0) + "%1$s" + (pos0 + 3 >= s.length() ? "" : s.substring(pos0 + 3));
}
int pos1 = s.indexOf("{1}");
if (pos1 > -1)
{
s = s.substring(0, pos1) + "%2$s" + (pos1 + 3 >= s.length() ? "" : s.substring(pos1 + 3));
}
int pos2 = s.indexOf("{2}");
if (pos2 > -1)
{
s = s.substring(0, pos2) + "%3$s" + (pos2 + 3 >= s.length() ? "" : s.substring(pos2 + 3));
}
// System.out.println("after: " + s);
return s;
}

abstract protected int getExpectedNumberOfMethods();
abstract protected Locale getLocale();
}
15 changes: 1 addition & 14 deletions providers/resteasy-html/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,11 @@
<artifactId>resteasy-jaxrs</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<dependency>
<groupId>org.jboss.spec.javax.servlet</groupId>
<artifactId>jboss-servlet-api_3.1_spec</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>tjws</artifactId>
<version>${project.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
</dependency>
Expand All @@ -41,12 +34,6 @@
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging-processor</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.resteasy</groupId>
<artifactId>resteasy-jaxrs-testsuite</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import org.junit.Assert;

import org.jboss.resteasy.plugins.providers.html.i18n.Messages;
import org.jboss.resteasy.test.resteasy_jaxrs.i18n.TestMessagesParent;
import org.junit.Test;

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
package org.jboss.resteasy.test.i18n;

import java.io.InputStream;
import java.util.Locale;
import java.util.Properties;

import org.junit.AfterClass;
import org.junit.BeforeClass;

/**
*
* @author <a href="ron.sigal@jboss.com">Ron Sigal</a>
* @version $Revision: 1.1 $
*
* Copyright Oct 8, 2014
*/
abstract public class TestMessagesParent
{
static protected Locale savedLocale;
protected Properties properties = new Properties();

@BeforeClass
static public void beforeClass()
{
savedLocale = Locale.getDefault();
}

@AfterClass
static public void afterClass()
{
Locale.setDefault(savedLocale);
System.out.println("Reset default locale to: " + savedLocale);
}

public boolean before(Locale locale, String filename) throws Exception
{
System.out.println("default locale: " + Locale.getDefault());
Locale.setDefault(locale);
System.out.println("Set default locale to: " + locale);
System.out.println("Messages file: " + filename);
InputStream is = getClass().getClassLoader().getResourceAsStream(filename);
if (is == null)
{
return false;
}
properties.load(is);
return getExpectedNumberOfMethods() == properties.size();
}

protected String getExpected(String id, String message, Object... args)
{
String expected = "RESTEASY" + id + ": " + String.format(replacePositionalSpecifiers(String.class.cast(properties.get(message))), args);
System.out.println("expected: " + expected);
return expected;
}

protected String replacePositionalSpecifiers(String s)
{
// System.out.println("before: " + s);
int pos0 = s.indexOf("{0}");
if (pos0 > -1)
{
s = s.substring(0, pos0) + "%1$s" + (pos0 + 3 >= s.length() ? "" : s.substring(pos0 + 3));
}
int pos1 = s.indexOf("{1}");
if (pos1 > -1)
{
s = s.substring(0, pos1) + "%2$s" + (pos1 + 3 >= s.length() ? "" : s.substring(pos1 + 3));
}
int pos2 = s.indexOf("{2}");
if (pos2 > -1)
{
s = s.substring(0, pos2) + "%3$s" + (pos2 + 3 >= s.length() ? "" : s.substring(pos2 + 3));
}
// System.out.println("after: " + s);
return s;
}

abstract protected int getExpectedNumberOfMethods();
abstract protected Locale getLocale();
}
Loading