[JBoss JIRA] Created: (JBWEB-191) ClassCastException
by Frank Langelage (JIRA)
ClassCastException
------------------
Key: JBWEB-191
URL: https://jira.jboss.org/browse/JBWEB-191
Project: JBoss Web
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Tomcat
Affects Versions: JBossWeb-3.0.0.Beta8
Reporter: Frank Langelage
Assignee: Remy Maucherat
I updated my JBoss-6.0.0 Snapshot this evening and my Web-Application gets this exception right on the first access:
23:14:21,480 ERROR [org.apache.catalina.connector.CoyoteAdapter] An exception or error occurred in the container during the request processing: java.lang.ClassCastException: org.apache.catalina.core.StandardHost cannot be cast to org.apache.catalina.core.StandardContext
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:136) [:]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [:]
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158) [:6.0.0-SNAPSHOT]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [:]
at org.jboss.web.tomcat.service.request.ActiveRequestResponseCacheValve.invoke(ActiveRequestResponseCacheValve.java:53) [:6.0.0-SNAPSHOT]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:362) [:]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [:]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:654) [:]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951) [:]
at java.lang.Thread.run(Thread.java:662) [:1.6.0_22]
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBAS-8706) org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase fails when run against IPv6 addresses
by Richard Achmatowicz (JIRA)
org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase fails when run against IPv6 addresses
------------------------------------------------------------------------------------------------------
Key: JBAS-8706
URL: https://jira.jboss.org/browse/JBAS-8706
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Clustering, Test Suite
Affects Versions: 6.0.0.CR1
Reporter: Richard Achmatowicz
Assignee: Paul Ferraro
Fix For: TBD-6.x
org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase checks the behaviour of HTTP requests to a server which in the process of shutting down.
As part of its processing, it uses a method
Cookie findCookie(int serverIndex, String name)
to find a cookie with a given name on a given server (usually indexed by 0 or 1).
Cookies are matched when they have the same domain and name.
Cookie domains can be represented as hostnames, or IP address literals.
Our version of HttpClient (which I hacked about one year ago) will always use enclosing brackets when presented with an IPv6 address literal.
HttpClient 3.0.1 and 3.1 did not support IPv6 address literals at the time.
I may have to reinvestigate what the correct standard is, but for the time being, the above test is failing because findCookie does not wrap IPv6 address literals
in square brackets before trying to match. As a result, we get assertion failures in the test, even though we have the correct cookies being returned:
Error Message
null
Stacktrace
junit.framework.AssertionFailedError: null
at org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase.testShutdown(CleanShutdownTestCase.java:164)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:23)
at junit.extensions.TestSetup.run(TestSetup.java:27)
Standard Output
After initial request
[fec0:0:a16:ffff::d] JSESSIONID /http-sr Eiq93h0lJFU7W6Y7YDNnXw__.cluster-udp-DIST-0
After request initiated prior to shutdown
[fec0:0:a16:ffff::d] JSESSIONID /http-sr Eiq93h0lJFU7W6Y7YDNnXw__.cluster-udp-DIST-0
[fec0:0:a16:ffff::d] sleep /http-sr 0
findCookie(0, "0") is trying to match on the pair ("fec0:0:a16:ffff::d", "0")
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBAS-8710) HASingleton PreferredMasterElectionPolicy failing with IPv6 addresses
by Richard Achmatowicz (JIRA)
HASingleton PreferredMasterElectionPolicy failing with IPv6 addresses
---------------------------------------------------------------------
Key: JBAS-8710
URL: https://jira.jboss.org/browse/JBAS-8710
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Clustering, Test Suite
Affects Versions: 6.0.0.CR1
Reporter: Richard Achmatowicz
Assignee: Paul Ferraro
Fix For: 6.0.0.Final
org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase checks the behaviour of HTTP requests to a server which in the process of shutting down.
As part of its processing, it uses a method
Cookie findCookie(int serverIndex, String name)
to find a cookie with a given name on a given server (usually indexed by 0 or 1).
Cookies are matched when they have the same domain and name.
Cookie domains can be represented as hostnames, or IP address literals.
Our version of HttpClient (which I hacked about one year ago) will always use enclosing brackets when presented with an IPv6 address literal.
HttpClient 3.0.1 and 3.1 did not support IPv6 address literals at the time.
I may have to reinvestigate what the correct standard is, but for the time being, the above test is failing because findCookie does not wrap IPv6 address literals
in square brackets before trying to match. As a result, we get assertion failures in the test, even though we have the correct cookies being returned:
Error Message
null
Stacktrace
junit.framework.AssertionFailedError: null
at org.jboss.test.cluster.defaultcfg.web.test.CleanShutdownTestCase.testShutdown(CleanShutdownTestCase.java:164)
at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24)
at junit.extensions.TestSetup$1.protect(TestSetup.java:23)
at junit.extensions.TestSetup.run(TestSetup.java:27)
Standard Output
After initial request
[fec0:0:a16:ffff::d] JSESSIONID /http-sr Eiq93h0lJFU7W6Y7YDNnXw__.cluster-udp-DIST-0
After request initiated prior to shutdown
[fec0:0:a16:ffff::d] JSESSIONID /http-sr Eiq93h0lJFU7W6Y7YDNnXw__.cluster-udp-DIST-0
[fec0:0:a16:ffff::d] sleep /http-sr 0
findCookie(0, "0") is trying to match on the pair ("fec0:0:a16:ffff::d", "0")
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBBUILD-550) Setting up test configs
by Paul Gier (JIRA)
Setting up test configs
-----------------------
Key: JBBUILD-550
URL: https://jira.jboss.org/jira/browse/JBBUILD-550
Project: JBoss Build System
Issue Type: Task
Components: Sonatype
Reporter: Paul Gier
>From Max's email:
When we run hibernate testsuite we today configure every run by having a <profile> section.
Each profile setup its own dependencies (i.e. jars for the classpath) and properties used
in interpolation of files like hibernate.properties.
This works pretty well and even works good with IDE's since you can just do:
mvn -Pdb2 test
then maven will generate the right hibernate.properties and run the tests.
Then in your IDE (eclipse, netbeans, intellij, whatever) can just use the generated hibernate.properties file
and pickup the jars. Nice and simple.
The downsides of this are:
A) To test a custom config you have to edit the pom.xml which becomes tedious when that file is under svn and thus becomes dirty
even though you haven't really changed anything in here.
B) There is not a clean way of having downstream adopters use our testsuite to run the testsuite.
A could be solved in a couple of ways:
1) create a "custom" profile which will pick up settings from lets say "custom.properties" to get the connection information. But then we would be missing the jar dependencies.
2) Another way would by being able to have profiles stored external to the pom.xml. Steve mentioned profiles.xml being discussed at some point to allow for this.
3) create a separate project per testsetup, but then we bump into other issues:
- surefire not being able to run tests based of tests in a jar. Not even when explicitly naming the class.
- Having a test subclass per config is also not scalable since it would just be tons and tons of boilerplate code with zero differences in plus without the easy "build project + dependencies" this becomes hard to maintain.
- And finally when it is a separate project it becomes cumbersome to run this easily from an IDE (the test class is in separate location, and so is the hibernate.properties)
- No way of overriding hibernate.properties since additional classpath entries are *appended* not *prepended* to the classpath when running tests.
B) could also be solved with the profiles.xml option or separate project - but have similar issues as described above.
I hope that put some more light on the issues ?
Let me know if it makes sense/nonsense.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months