Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9A3CF9E76 for ; Tue, 24 Jan 2012 15:47:02 +0000 (UTC) Received: (qmail 55207 invoked by uid 500); 24 Jan 2012 15:47:02 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 55097 invoked by uid 500); 24 Jan 2012 15:47:01 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 55089 invoked by uid 99); 24 Jan 2012 15:47:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Jan 2012 15:47:01 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Jan 2012 15:47:00 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 5787C160D39 for ; Tue, 24 Jan 2012 15:46:40 +0000 (UTC) Date: Tue, 24 Jan 2012 15:46:40 +0000 (UTC) From: "Aki Yoshida (Created) (JIRA)" To: issues@cxf.apache.org Message-ID: <470887894.72078.1327420000360.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Created] (CXF-4060) oneway camel scenario is accessing the user principal too late, resulting in IllegalStateException MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 oneway camel scenario is accessing the user principal too late, resulting in IllegalStateException -------------------------------------------------------------------------------------------------- Key: CXF-4060 URL: https://issues.apache.org/jira/browse/CXF-4060 Project: CXF Issue Type: Bug Components: Transports Affects Versions: 2.5.2, 2.4.6 Environment: gemini.web.tomcat 2.0.1 Reporter: Aki Yoshida Assignee: Aki Yoshida Camel-CXF looks up the user principal in Camel's DefaultCxfBinding over CXF's SecurityContext object stored in the message. In the current implementation, the principal in this object is dynamically retrieved from the associated servlet request object. Under some specific circumstances such as using tomcat with the JVM's security manager enabled, the request object is recycled after the calling thread returns. This can lead to the following exception for oneway call: java.lang.IllegalStateException: The request object has been recycled and is no longer associated with this facade at org.apache.catalina.connector.RequestFacade.getUserPrincipal(RequestFacade.java:831) ~[na:na] at org.apache.cxf.transport.http.AbstractHTTPDestination$2.getUserPrincipal(AbstractHTTPDestination.java:304) ~[bundlefile:2.5.1] at org.apache.camel.component.cxf.DefaultCxfBinding.populateExchangeFromCxfRequest(DefaultCxfBinding.java:235) ~[bundlefile:2.8.3] at org.apache.camel.component.cxf.CxfConsumer$1.perpareCamelExchange(CxfConsumer.java:159) ~[bundlefile:2.8.3] at org.apache.camel.component.cxf.CxfConsumer$1.syncInvoke(CxfConsumer.java:117) ~[bundlefile:2.8.3] at org.apache.camel.component.cxf.CxfConsumer$1.invoke(CxfConsumer.java:71) ~[bundlefile:2.8.3] at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:58) ~[na:na] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) ~[na:1.6.0_24] at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) ~[na:1.6.0_24] at java.util.concurrent.FutureTask.run(FutureTask.java:138) ~[na:1.6.0_24] at org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecutor.java:37) ~[bundlefile:2.5.1] at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:106) ~[na:na] at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:263) ~[bundlefile:2.5.1] at org.apache.cxf.phase.PhaseInterceptorChain.resume(PhaseInterceptorChain.java:232) ~[bundlefile:2.5.1] at org.apache.cxf.interceptor.OneWayProcessorInterceptor$1.run(OneWayProcessorInterceptor.java:130) ~[na:na] at org.apache.cxf.workqueue.AutomaticWorkQueueImpl$3.run(AutomaticWorkQueueImpl.java:371) ~[bundlefile:2.5.1] at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) ~[na:1.6.0_24] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) ~[na:1.6.0_24] at java.lang.Thread.run(Thread.java:662) ~[na:1.6.0_24] -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira