JBoss Remoting SVN: r3645 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/startup.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 22:52:06 -0400 (Fri, 14 Mar 2008)
New Revision: 3645
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/startup/JNDIDetectorServer.java
Log:
JBREM-930: Uses value of System property "jrunit.bind_addr" instead of "localhost".
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/startup/JNDIDetectorServer.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/startup/JNDIDetectorServer.java 2008-03-15 02:44:40 UTC (rev 3644)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/startup/JNDIDetectorServer.java 2008-03-15 02:52:06 UTC (rev 3645)
@@ -77,7 +77,8 @@
port = TestUtil.getRandomPort();
System.out.println("port = " + port);
- InvokerLocator locator = new InvokerLocator("socket://localhost:" + port);
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ InvokerLocator locator = new InvokerLocator("socket://" + bindAddr + ":" + port);
System.out.println("Starting remoting server with locator uri of: " + locator.getLocatorURI());
connector = new Connector();
16 years, 9 months
JBoss Remoting SVN: r3644 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 22:44:40 -0400 (Fri, 14 Mar 2008)
New Revision: 3644
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest1.java
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest2.java
Log:
JBREM-930: Uses value of System property "jrunit.bind_addr" instead of "localhost".
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest1.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest1.java 2008-03-14 21:47:33 UTC (rev 3643)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest1.java 2008-03-15 02:44:40 UTC (rev 3644)
@@ -116,7 +116,9 @@
int port = TestUtil.getRandomPort();
System.out.println("port = " + port);
- InvokerLocator locator = new InvokerLocator("socket://localhost:" + port);
+ String host = InetAddress.getLocalHost().getHostAddress();
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ InvokerLocator locator = new InvokerLocator("socket://" + bindAddr + ":" + port);
System.out.println("Starting remoting server with locator uri of: " + locator.getLocatorURI());
connector = new Connector();
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest2.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest2.java 2008-03-14 21:47:33 UTC (rev 3643)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTest2.java 2008-03-15 02:44:40 UTC (rev 3644)
@@ -73,7 +73,9 @@
int port = TestUtil.getRandomPort();
System.out.println("port = " + port);
- InvokerLocator locator = new InvokerLocator("socket://localhost:" + port);
+ String host = InetAddress.getLocalHost().getHostAddress();
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ InvokerLocator locator = new InvokerLocator("socket://" + bindAddr + ":" + port);
System.out.println("Starting remoting server with locator uri of: " + locator.getLocatorURI());
connector = new Connector();
16 years, 9 months
JBoss Remoting SVN: r3643 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 17:47:33 -0400 (Fri, 14 Mar 2008)
New Revision: 3643
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingConnectorTestClient.java
Log:
JBREM-930: Uses value of System property "jrunit.bind_addr" instead of "localhost".
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingConnectorTestClient.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingConnectorTestClient.java 2008-03-14 21:42:49 UTC (rev 3642)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingConnectorTestClient.java 2008-03-14 21:47:33 UTC (rev 3643)
@@ -20,7 +20,7 @@
private static String host = "localhost";
private static int port = 5400;
- private String locatorURI = StreamingConnectorTestClient.transport + "://" + StreamingConnectorTestClient.host + ":" + StreamingConnectorTestClient.port;
+ private String locatorURI;
private Client remotingClient = null;
private File testFile = null;
private FileInputStream fileInput = null;
@@ -28,7 +28,7 @@
private boolean error = false;
private Connector connector = null;
- private String streamConnectorLocatorUri = transport + "://" + host + ":" + 5410;
+ private String streamConnectorLocatorUri;
public void testStream() throws Throwable
{
@@ -95,6 +95,8 @@
public void setUp() throws Exception
{
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ locatorURI = transport + "://" + bindAddr + ":" + port;
InvokerLocator locator = new InvokerLocator(locatorURI);
System.out.println("Calling remoting server with locator uri of: " + locatorURI);
@@ -105,6 +107,8 @@
private void setupServer() throws Exception
{
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ streamConnectorLocatorUri = transport + "://" + bindAddr + ":" + 5410;
connector = new Connector(streamConnectorLocatorUri);
connector.create();
connector.start();
16 years, 9 months
JBoss Remoting SVN: r3642 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 17:42:49 -0400 (Fri, 14 Mar 2008)
New Revision: 3642
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestClient.java
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestServer.java
Log:
JBREM-930: Uses value of System property "jrunit.bind_addr" instead of "localhost".
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestClient.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestClient.java 2008-03-14 20:39:08 UTC (rev 3641)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestClient.java 2008-03-14 21:42:49 UTC (rev 3642)
@@ -41,7 +41,7 @@
private static String host = "localhost";
private static int port = 5400;
- private String locatorURI = transport + "://" + host + ":" + port;
+ private String locatorURI;
private Client remotingClient = null;
private File testFile = null;
private FileInputStream fileInput = null;
@@ -117,6 +117,8 @@
public void setUp() throws Exception
{
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ locatorURI = transport + "://" + bindAddr + ":" + port;
InvokerLocator locator = new InvokerLocator(locatorURI);
System.out.println("Calling remoting server with locator uri of: " + locatorURI);
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestServer.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestServer.java 2008-03-14 20:39:08 UTC (rev 3641)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/stream/StreamingTestServer.java 2008-03-14 21:42:49 UTC (rev 3642)
@@ -46,11 +46,13 @@
private static String host = "localhost";
private static int port = 5400;
- private String locatorURI = transport + "://" + host + ":" + port;
+ private String locatorURI;
private Connector connector = null;
public void setupServer() throws Exception
{
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ locatorURI = transport + "://" + bindAddr + ":" + port;
InvokerLocator locator = new InvokerLocator(locatorURI);
System.out.println("Starting remoting server with locator uri of: " + locatorURI);
connector = new Connector();
16 years, 9 months
JBoss Remoting SVN: r3641 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/raw.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 16:39:08 -0400 (Fri, 14 Mar 2008)
New Revision: 3641
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestClient.java
Log:
JBREM-930: Uses value of System property "jrunit.bind_addr" instead of "localhost".
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestClient.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestClient.java 2008-03-14 20:32:29 UTC (rev 3640)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestClient.java 2008-03-14 20:39:08 UTC (rev 3641)
@@ -113,7 +113,9 @@
public String getLocatorURI()
{
- String locatorURI = transport + "://" + host + ":" + port;
+ String bindAddr = System.getProperty("jrunit.bind_addr", host);
+ String locatorURI = transport + "://" + bindAddr + ":" + port;
+
String metadata = System.getProperty(PerformanceTestCase.REMOTING_METADATA);
if(metadata != null && metadata.length() > 0)
{
16 years, 9 months
JBoss Remoting SVN: r3640 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 16:32:29 -0400 (Fri, 14 Mar 2008)
New Revision: 3640
Removed:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase.java
Log:
JBREM-930: Retired this test.
Deleted: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase.java 2008-03-14 20:31:59 UTC (rev 3639)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase.java 2008-03-14 20:32:29 UTC (rev 3640)
@@ -1,152 +0,0 @@
-/***************************************
- * *
- * JBoss: The OpenSource J2EE WebOS *
- * *
- * Distributable under LGPL license. *
- * See terms of license at gnu.org. *
- * *
- ***************************************/
-package org.jboss.test.remoting.transport.http.proxy;
-
-import junit.framework.TestCase;
-import org.jboss.remoting.Client;
-import org.jboss.remoting.InvokerLocator;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * This class is for testing http client invocations through
- * public proxy server. Is not a great tests as there is no way
- * to really prove went through the proxy. Best test can do
- * is indicate problem with config. Also, test may fail just due
- * to not being able to use proxy server (as is a public proxy server
- * in China and have no control over it. for more public proxy server
- * listings, can see http://www.publicproxyservers.com/page1.html).
- * Also, no gurantee the content on testUrl will never be changed.
- *
- * @author <a href="mailto:tom@jboss.org">Tom Elrod</a>
- */
-public class HTTPInvokerProxyTestCase extends TestCase
-{
- private Client client;
-// private String testUrl = "http://www.gnu.org/licenses/gpl.html";
- private String testUrl = "http://www.ietf.org/rfc/rfc1766.txt?number=1766";
-
- public void setUp()
- {
- init(testUrl);
- }
-
- public void init(String httpTargetURL)
- {
- try
- {
- InvokerLocator locator = new InvokerLocator(httpTargetURL);
- Map config = new HashMap();
- client = new Client(locator, config);
- client.connect();
- }
- catch (Exception e)
- {
- e.printStackTrace();
- }
- }
-
- public String makeInvocationCall(String payload, Map metadata) throws Throwable
- {
- Object obj = client.invoke(payload, metadata);
-
- System.out.println("invoke returned" + obj);
-
- return (String) obj;
- }
-
- public void testHTTPProxyInvocationViaSystemConfig() throws Throwable
- {
- Map metadata = new HashMap();
- metadata.put(Client.RAW, Boolean.TRUE);
- metadata.put("TYPE", "GET");
-
-
- // proxy info
- System.setProperty("proxySet", "true");
- System.setProperty("http.proxyHost", "84.19.177.62");
- System.setProperty("http.proxyPort", "8080");
-
- String result = makeInvocationCall(null, metadata);
-
- System.out.println("invoke returned" + result);
-
- assertEquals(getExpectedGETResult().substring(0, 50), result.substring(0, 50));
-
- }
-
- public void testHTTPProxyInvocationViaConfig() throws Throwable
- {
- // need to make sure is running jdk 1.5 or higher.
- // otherwise, no point in running this test method as will
- // not work with jdk 1.4.
- boolean isJDK15 = false;
-
- try
- {
- Class proxyClass = Class.forName("java.net.Proxy");
- isJDK15 = true;
- }
- catch (ClassNotFoundException e)
- {
- System.out.println("Not running jdk 1.5 or higher, so will bypass testHTTPProxyInvocationViaConfig test.");
- }
-
- if(isJDK15)
- {
- Map metadata = new HashMap();
- metadata.put(Client.RAW, Boolean.TRUE);
- metadata.put("TYPE", "GET");
-
-
- // proxy info
- metadata.put("http.proxyHost", "84.19.177.62");
- metadata.put("http.proxyPort", "8080");
-
- String result = makeInvocationCall(null, metadata);
-
- System.out.println("invoke returned" + result);
-
- assertEquals(getExpectedGETResult().substring(0, 50), result.substring(0, 50));
- }
- }
-
- private String getExpectedGETResult()
- {
- return "Network Working Group H. AlvestrandRequest for Comments: 1766 ";
- }
-
-/*
- private String getExpectedGETResult()
- {
- return "<!DOCTYPE html PUBLIC \"-//IETF//DTD HTML 2.0//EN\"><HTML><HEAD><TITLE>GNU General Public License - " +
- "GNU Project - Free Software Foundation (FSF)</TITLE><LINK REV=\"made\" " +
- "HREF=\"mailto:webmasters@www.gnu.org\"><link rel=\"stylesheet\" type=\"text/css\" href=\"/gnu.css\" />" +
- "</HEAD><BODY BGCOLOR=\"#FFFFFF\" TEXT=\"#000000\" LINK=\"#1F00FF\" ALINK=\"#FF0000\" VLINK=\"#9900DD\">" +
- "<H1>GNU General Public License</H1><A HREF=\"/graphics/philosophicalgnu.html\"><IMG SRC=\"/graphics/philosophical-gnu-sm.jpg\" " +
- "ALT=\" [image of a Philosophical GNU] \" WIDTH=\"160\" HEIGHT=\"200\"></A><!-- Please keep this list alphabetical -->" +
- "<!-- tower, gpl.ja.html is Japanese translation of THIS PAGE, --><!-- NOT translation of GPL itself(gpl.ja.html contains the original --> " +
- "<!-- English version). So please do not remove the following. --><!-- Thanks -mhatta -->" +
- "<!-- The same for the Czech page. The entire text of GPL is not --><!-- translated on this page. Thanks Sisao -->[ " +
- "<A HREF=\"/licenses/gpl.cs.html\">Czech</A>| <A HREF=\"/licenses/gpl.html\">English</A>| <A HREF=\"/licenses/gpl.ja.html\">Japanese</A>]" +
- "<!-- It is best to not enumerate the translations here in a menu bar, --><!-- It is best to have the users follow this link, so they have the FSF' -->" +
- "<!-- explanation about translations being unofficial, etc. --><P><UL> <LI>" +
- "<A HREF=\"/licenses/gpl-violation.html\"><EM>What to do if you see a possible GPL violation</EM></A> <LI>" +
- "<A HREF=\"/licenses/translations.html\"><EM>Translations of the GPL</EM></A> <LI><A HREF=\"/licenses/gpl-faq.html\"" +
- "><EM>GPL Frequently Asked Questions</EM></A> <LI>The GNU General Public License (GPL) " +
- "<A HREF=\"/licenses/gpl.txt\">in plain text format</A> <LI>The GNU General Public License (GPL) " +
- "<A HREF=\"/licenses/gpl.texi\">in Texinfo format</A> <LI>The GNU General Public License (GPL) " +
- "<A HREF=\"/licenses/gpl-2.0.tex\">in LaTeX format</A> <li>The GNU General Public License (GPL) " +
- "<a href=\"/licenses/gpl.dbk\">as an appendix in DocBook format</a></UL><P> <HR><P><H2>Table of Contents</H2><UL> " +
- "<LI><A NAME=\"TOC1\" HREF=\"gpl.html#SEC1\">GNU GENERAL PUBLIC LICENSE</A><UL><LI><A NAME=\"TOC2\" HREF=\"gpl.html#SEC2\">Preamble</A>";
- }
-*/
-
-}
\ No newline at end of file
16 years, 9 months
JBoss Remoting SVN: r3639 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 16:31:59 -0400 (Fri, 14 Mar 2008)
New Revision: 3639
Added:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase_Retired.java
Log:
JBREM-930: Retired this test.
Copied: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase_Retired.java (from rev 3593, remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase.java)
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase_Retired.java (rev 0)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/transport/http/proxy/HTTPInvokerProxyTestCase_Retired.java 2008-03-14 20:31:59 UTC (rev 3639)
@@ -0,0 +1,152 @@
+/***************************************
+ * *
+ * JBoss: The OpenSource J2EE WebOS *
+ * *
+ * Distributable under LGPL license. *
+ * See terms of license at gnu.org. *
+ * *
+ ***************************************/
+package org.jboss.test.remoting.transport.http.proxy;
+
+import junit.framework.TestCase;
+import org.jboss.remoting.Client;
+import org.jboss.remoting.InvokerLocator;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * This class is for testing http client invocations through
+ * public proxy server. Is not a great tests as there is no way
+ * to really prove went through the proxy. Best test can do
+ * is indicate problem with config. Also, test may fail just due
+ * to not being able to use proxy server (as is a public proxy server
+ * in China and have no control over it. for more public proxy server
+ * listings, can see http://www.publicproxyservers.com/page1.html).
+ * Also, no gurantee the content on testUrl will never be changed.
+ *
+ * @author <a href="mailto:tom@jboss.org">Tom Elrod</a>
+ */
+public class HTTPInvokerProxyTestCase_Retired extends TestCase
+{
+ private Client client;
+// private String testUrl = "http://www.gnu.org/licenses/gpl.html";
+ private String testUrl = "http://www.ietf.org/rfc/rfc1766.txt?number=1766";
+
+ public void setUp()
+ {
+ init(testUrl);
+ }
+
+ public void init(String httpTargetURL)
+ {
+ try
+ {
+ InvokerLocator locator = new InvokerLocator(httpTargetURL);
+ Map config = new HashMap();
+ client = new Client(locator, config);
+ client.connect();
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ public String makeInvocationCall(String payload, Map metadata) throws Throwable
+ {
+ Object obj = client.invoke(payload, metadata);
+
+ System.out.println("invoke returned" + obj);
+
+ return (String) obj;
+ }
+
+ public void testHTTPProxyInvocationViaSystemConfig() throws Throwable
+ {
+ Map metadata = new HashMap();
+ metadata.put(Client.RAW, Boolean.TRUE);
+ metadata.put("TYPE", "GET");
+
+
+ // proxy info
+ System.setProperty("proxySet", "true");
+ System.setProperty("http.proxyHost", "84.19.177.62");
+ System.setProperty("http.proxyPort", "8080");
+
+ String result = makeInvocationCall(null, metadata);
+
+ System.out.println("invoke returned" + result);
+
+ assertEquals(getExpectedGETResult().substring(0, 50), result.substring(0, 50));
+
+ }
+
+ public void testHTTPProxyInvocationViaConfig() throws Throwable
+ {
+ // need to make sure is running jdk 1.5 or higher.
+ // otherwise, no point in running this test method as will
+ // not work with jdk 1.4.
+ boolean isJDK15 = false;
+
+ try
+ {
+ Class proxyClass = Class.forName("java.net.Proxy");
+ isJDK15 = true;
+ }
+ catch (ClassNotFoundException e)
+ {
+ System.out.println("Not running jdk 1.5 or higher, so will bypass testHTTPProxyInvocationViaConfig test.");
+ }
+
+ if(isJDK15)
+ {
+ Map metadata = new HashMap();
+ metadata.put(Client.RAW, Boolean.TRUE);
+ metadata.put("TYPE", "GET");
+
+
+ // proxy info
+ metadata.put("http.proxyHost", "84.19.177.62");
+ metadata.put("http.proxyPort", "8080");
+
+ String result = makeInvocationCall(null, metadata);
+
+ System.out.println("invoke returned" + result);
+
+ assertEquals(getExpectedGETResult().substring(0, 50), result.substring(0, 50));
+ }
+ }
+
+ private String getExpectedGETResult()
+ {
+ return "Network Working Group H. AlvestrandRequest for Comments: 1766 ";
+ }
+
+/*
+ private String getExpectedGETResult()
+ {
+ return "<!DOCTYPE html PUBLIC \"-//IETF//DTD HTML 2.0//EN\"><HTML><HEAD><TITLE>GNU General Public License - " +
+ "GNU Project - Free Software Foundation (FSF)</TITLE><LINK REV=\"made\" " +
+ "HREF=\"mailto:webmasters@www.gnu.org\"><link rel=\"stylesheet\" type=\"text/css\" href=\"/gnu.css\" />" +
+ "</HEAD><BODY BGCOLOR=\"#FFFFFF\" TEXT=\"#000000\" LINK=\"#1F00FF\" ALINK=\"#FF0000\" VLINK=\"#9900DD\">" +
+ "<H1>GNU General Public License</H1><A HREF=\"/graphics/philosophicalgnu.html\"><IMG SRC=\"/graphics/philosophical-gnu-sm.jpg\" " +
+ "ALT=\" [image of a Philosophical GNU] \" WIDTH=\"160\" HEIGHT=\"200\"></A><!-- Please keep this list alphabetical -->" +
+ "<!-- tower, gpl.ja.html is Japanese translation of THIS PAGE, --><!-- NOT translation of GPL itself(gpl.ja.html contains the original --> " +
+ "<!-- English version). So please do not remove the following. --><!-- Thanks -mhatta -->" +
+ "<!-- The same for the Czech page. The entire text of GPL is not --><!-- translated on this page. Thanks Sisao -->[ " +
+ "<A HREF=\"/licenses/gpl.cs.html\">Czech</A>| <A HREF=\"/licenses/gpl.html\">English</A>| <A HREF=\"/licenses/gpl.ja.html\">Japanese</A>]" +
+ "<!-- It is best to not enumerate the translations here in a menu bar, --><!-- It is best to have the users follow this link, so they have the FSF' -->" +
+ "<!-- explanation about translations being unofficial, etc. --><P><UL> <LI>" +
+ "<A HREF=\"/licenses/gpl-violation.html\"><EM>What to do if you see a possible GPL violation</EM></A> <LI>" +
+ "<A HREF=\"/licenses/translations.html\"><EM>Translations of the GPL</EM></A> <LI><A HREF=\"/licenses/gpl-faq.html\"" +
+ "><EM>GPL Frequently Asked Questions</EM></A> <LI>The GNU General Public License (GPL) " +
+ "<A HREF=\"/licenses/gpl.txt\">in plain text format</A> <LI>The GNU General Public License (GPL) " +
+ "<A HREF=\"/licenses/gpl.texi\">in Texinfo format</A> <LI>The GNU General Public License (GPL) " +
+ "<A HREF=\"/licenses/gpl-2.0.tex\">in LaTeX format</A> <li>The GNU General Public License (GPL) " +
+ "<a href=\"/licenses/gpl.dbk\">as an appendix in DocBook format</a></UL><P> <HR><P><H2>Table of Contents</H2><UL> " +
+ "<LI><A NAME=\"TOC1\" HREF=\"gpl.html#SEC1\">GNU GENERAL PUBLIC LICENSE</A><UL><LI><A NAME=\"TOC2\" HREF=\"gpl.html#SEC2\">Preamble</A>";
+ }
+*/
+
+}
\ No newline at end of file
16 years, 9 months
JBoss Remoting SVN: r3638 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 16:29:00 -0400 (Fri, 14 Mar 2008)
New Revision: 3638
Removed:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase.java
Log:
JBREM-930: Retired this test.
Deleted: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase.java 2008-03-14 20:28:29 UTC (rev 3637)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase.java 2008-03-14 20:29:00 UTC (rev 3638)
@@ -1,134 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-
-package org.jboss.test.remoting.marshall.http.metadata;
-
-import junit.framework.TestCase;
-import org.apache.log4j.Level;
-import org.jboss.remoting.Client;
-import org.jboss.remoting.InvokerLocator;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-
-/**
- * Test case that uses the HTTPInvoker client to call on two different public SOAP services (one based
- * on Axis and the other based on .NET implementations).
- *
- * @author <a href="mailto:telrod@e2technologies.net">Tom Elrod</a>
- */
-public class HTTPUnMarshallerMetadataTestCase extends TestCase
-{
- private Client client;
-
- public void init(String httpTargetURL, HTTPUnMarshallerMock unmarshaller)
- {
- try
- {
- InvokerLocator locator = new InvokerLocator(httpTargetURL);
- client = new Client(locator);
- client.connect();
- client.setUnMarshaller(unmarshaller);
- client.connect();
- }
- catch(Exception e)
- {
- e.printStackTrace();
- }
- }
-
- public String makeInvocationCall(String httpTargetURL, String payload, Map metadata, HTTPUnMarshallerMock unmarshaller) throws Throwable
- {
- init(httpTargetURL, unmarshaller);
-
- Object obj = client.invoke(payload, metadata);
-
- System.out.println("invoke returned" + obj);
-
- return (String) obj;
- }
-
- public void testWeatherHTTPInvocation() throws Throwable
- {
-
- org.apache.log4j.BasicConfigurator.configure();
- org.apache.log4j.Category.getRoot().setLevel(Level.INFO);
- org.apache.log4j.Category.getInstance("org.jgroups").setLevel(Level.INFO);
- org.apache.log4j.Category.getInstance("org.jboss.remoting").setLevel(Level.DEBUG);
- org.apache.log4j.Category.getInstance("test").setLevel(Level.DEBUG);
-
-
- String testURL = "http://services.xmethods.net:80/soap/servlet/rpcrouter";
-
- String xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
- "<soap:Envelope xmlns:mrns0=\"urn:xmethods-Temperature\" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n" +
- " <soap:Body soap:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\">\n" +
- " <mrns0:getTemp>\n" +
- " <zipcode xsi:type=\"xs:string\">30106</zipcode>\n" +
- " </mrns0:getTemp>\n" +
- " </soap:Body>\n" +
- "</soap:Envelope>";
-
- Map metadata = new HashMap();
- metadata.put(Client.RAW, Boolean.TRUE);
- metadata.put("TYPE", "POST");
-
- Properties headerProps = new Properties();
- headerProps.put("SOAPAction", "");
- headerProps.put("Content-type", "text/xml; charset=UTF-8");
-
- metadata.put("HEADER", headerProps);
-
-
- HTTPUnMarshallerMetadataTestCase client = new HTTPUnMarshallerMetadataTestCase();
-
- HTTPUnMarshallerMock unmarshaller = new HTTPUnMarshallerMock();
-
- String result = client.makeInvocationCall(testURL, xml, metadata, unmarshaller);
-
- // expect to get the following header
- assertNotNull(unmarshaller.getMetadata());
- List header = (List) unmarshaller.getMetadata().get("Status");
- assertEquals("200", header.get(0));
-
- // don't need to comapre full string. (as actual temp value will change each time run)
- assertEquals(getExpectedWeatherResult().substring(0, 380), result.substring(0, 380));
-
- }
-
- private String getExpectedWeatherResult()
- {
- return "<?xml version='1.0' encoding='UTF-8'?>" +
- "<SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">" +
- "<SOAP-ENV:Body>" +
- "<ns1:getTempResponse xmlns:ns1=\"urn:xmethods-Temperature\" SOAP-ENV:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\">" +
- "<return xsi:type=\"xsd:float\">60.0</return>" +
- "</ns1:getTempResponse>" +
- "\n" +
- "</SOAP-ENV:Body>\n" +
- "</SOAP-ENV:Envelope>";
- }
-
-
-}
\ No newline at end of file
16 years, 9 months
JBoss Remoting SVN: r3637 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 16:28:29 -0400 (Fri, 14 Mar 2008)
New Revision: 3637
Added:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase_Retired.java
Log:
JBREM-930: Retired this test.
Copied: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase_Retired.java (from rev 3593, remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase.java)
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase_Retired.java (rev 0)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/marshall/http/metadata/HTTPUnMarshallerMetadataTestCase_Retired.java 2008-03-14 20:28:29 UTC (rev 3637)
@@ -0,0 +1,134 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+
+package org.jboss.test.remoting.marshall.http.metadata;
+
+import junit.framework.TestCase;
+import org.apache.log4j.Level;
+import org.jboss.remoting.Client;
+import org.jboss.remoting.InvokerLocator;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+
+/**
+ * Test case that uses the HTTPInvoker client to call on two different public SOAP services (one based
+ * on Axis and the other based on .NET implementations).
+ *
+ * @author <a href="mailto:telrod@e2technologies.net">Tom Elrod</a>
+ */
+public class HTTPUnMarshallerMetadataTestCase_Retired extends TestCase
+{
+ private Client client;
+
+ public void init(String httpTargetURL, HTTPUnMarshallerMock unmarshaller)
+ {
+ try
+ {
+ InvokerLocator locator = new InvokerLocator(httpTargetURL);
+ client = new Client(locator);
+ client.connect();
+ client.setUnMarshaller(unmarshaller);
+ client.connect();
+ }
+ catch(Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ public String makeInvocationCall(String httpTargetURL, String payload, Map metadata, HTTPUnMarshallerMock unmarshaller) throws Throwable
+ {
+ init(httpTargetURL, unmarshaller);
+
+ Object obj = client.invoke(payload, metadata);
+
+ System.out.println("invoke returned" + obj);
+
+ return (String) obj;
+ }
+
+ public void testWeatherHTTPInvocation() throws Throwable
+ {
+
+ org.apache.log4j.BasicConfigurator.configure();
+ org.apache.log4j.Category.getRoot().setLevel(Level.INFO);
+ org.apache.log4j.Category.getInstance("org.jgroups").setLevel(Level.INFO);
+ org.apache.log4j.Category.getInstance("org.jboss.remoting").setLevel(Level.DEBUG);
+ org.apache.log4j.Category.getInstance("test").setLevel(Level.DEBUG);
+
+
+ String testURL = "http://services.xmethods.net:80/soap/servlet/rpcrouter";
+
+ String xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
+ "<soap:Envelope xmlns:mrns0=\"urn:xmethods-Temperature\" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:soapenc=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:xs=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n" +
+ " <soap:Body soap:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\">\n" +
+ " <mrns0:getTemp>\n" +
+ " <zipcode xsi:type=\"xs:string\">30106</zipcode>\n" +
+ " </mrns0:getTemp>\n" +
+ " </soap:Body>\n" +
+ "</soap:Envelope>";
+
+ Map metadata = new HashMap();
+ metadata.put(Client.RAW, Boolean.TRUE);
+ metadata.put("TYPE", "POST");
+
+ Properties headerProps = new Properties();
+ headerProps.put("SOAPAction", "");
+ headerProps.put("Content-type", "text/xml; charset=UTF-8");
+
+ metadata.put("HEADER", headerProps);
+
+
+ HTTPUnMarshallerMetadataTestCase_Retired client = new HTTPUnMarshallerMetadataTestCase_Retired();
+
+ HTTPUnMarshallerMock unmarshaller = new HTTPUnMarshallerMock();
+
+ String result = client.makeInvocationCall(testURL, xml, metadata, unmarshaller);
+
+ // expect to get the following header
+ assertNotNull(unmarshaller.getMetadata());
+ List header = (List) unmarshaller.getMetadata().get("Status");
+ assertEquals("200", header.get(0));
+
+ // don't need to comapre full string. (as actual temp value will change each time run)
+ assertEquals(getExpectedWeatherResult().substring(0, 380), result.substring(0, 380));
+
+ }
+
+ private String getExpectedWeatherResult()
+ {
+ return "<?xml version='1.0' encoding='UTF-8'?>" +
+ "<SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">" +
+ "<SOAP-ENV:Body>" +
+ "<ns1:getTempResponse xmlns:ns1=\"urn:xmethods-Temperature\" SOAP-ENV:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\">" +
+ "<return xsi:type=\"xsd:float\">60.0</return>" +
+ "</ns1:getTempResponse>" +
+ "\n" +
+ "</SOAP-ENV:Body>\n" +
+ "</SOAP-ENV:Envelope>";
+ }
+
+
+}
\ No newline at end of file
16 years, 9 months
JBoss Remoting SVN: r3636 - remoting2/branches/2.x/src/tests/org/jboss/test/remoting/soak.
by jboss-remoting-commits@lists.jboss.org
Author: ron.sigal(a)jboss.com
Date: 2008-03-14 04:56:25 -0400 (Fri, 14 Mar 2008)
New Revision: 3636
Modified:
remoting2/branches/2.x/src/tests/org/jboss/test/remoting/soak/SoakConstants.java
Log:
JBREM-931: New constants for soak test.
Modified: remoting2/branches/2.x/src/tests/org/jboss/test/remoting/soak/SoakConstants.java
===================================================================
--- remoting2/branches/2.x/src/tests/org/jboss/test/remoting/soak/SoakConstants.java 2008-03-14 08:56:11 UTC (rev 3635)
+++ remoting2/branches/2.x/src/tests/org/jboss/test/remoting/soak/SoakConstants.java 2008-03-14 08:56:25 UTC (rev 3636)
@@ -38,5 +38,25 @@
public static final int DURATION = 30000;
public static final int INTERVAL = 1000;
+
+ public static final String NUMBER_OF_CALLS = "numberOfCalls";
+
+ public static final String NAME = "name";
+
+ public static final String COPY = "copy";
+
+ public static final String SPIN = "spin";
+
+ public static final String CALLBACK = "callback";
+
+ public static final String NUMBER_OF_CALLBACKS = "numberOfCallbacks";
+
+ public static final String PAYLOAD = "payload";
+
+ public static final String SPIN_TIME = "spinTime";
+
+ public static final String COUNTER = "counter";
+
+ public static final String FAILURE_COUNTER = "failureCounter";
}
16 years, 9 months