org.omg.CORBA.portable.RemarshalException Java Examples
The following examples show how to use
org.omg.CORBA.portable.RemarshalException.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: CorbaClientDelegateImpl.java From jdk1.8-source-analysis with Apache License 2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #2
Source File: CorbaClientDelegateImpl.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #3
Source File: CorbaClientDelegateImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #4
Source File: CorbaClientDelegateImpl.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #5
Source File: CorbaClientDelegateImpl.java From hottub with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #6
Source File: CorbaClientDelegateImpl.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #7
Source File: CorbaClientDelegateImpl.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #8
Source File: CorbaClientDelegateImpl.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #9
Source File: CorbaClientDelegateImpl.java From JDKSourceCode1.8 with MIT License | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #10
Source File: CorbaClientDelegateImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
public InputStream invoke(org.omg.CORBA.Object self, OutputStream output) throws ApplicationException, RemarshalException { ClientRequestDispatcher subcontract = getClientRequestDispatcher(); return (InputStream) subcontract.marshalingComplete((Object)self, (OutputObject)output); }
Example #11
Source File: PINoOpHandlerImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { }
Example #12
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #13
Source File: PIHandlerImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { if( !hasClientInterceptors ) return; if( !isClientPIEnabledForThisThread() ) return; // Invoke the starting interception points and record exception // and reply status info in the info object: ClientRequestInfoImpl info = peekClientRequestInfoImplStack(); interceptorInvoker.invokeClientInterceptorStartingPoint( info ); // Check reply status. If we will not have another chance later // to invoke the client ending points, do it now. short replyStatus = info.getReplyStatus(); if( (replyStatus == SYSTEM_EXCEPTION.value) || (replyStatus == LOCATION_FORWARD.value) ) { // Note: Transport retry cannot happen here since this happens // before the request hits the wire. Exception exception = invokeClientPIEndingPoint( convertPIReplyStatusToReplyMessage( replyStatus ), info.getException() ); if( exception == null ) { // Do not throw anything. Otherwise, it must be a // SystemException, UserException or RemarshalException. } if( exception instanceof SystemException ) { throw (SystemException)exception; } else if( exception instanceof RemarshalException ) { throw (RemarshalException)exception; } else if( (exception instanceof UserException) || (exception instanceof ApplicationException) ) { // It should not be possible for an interceptor to throw // a UserException. By asserting instead of throwing the // UserException, we need not declare anything but // RemarshalException in the throws clause. throw wrapper.exceptionInvalid() ; } } else if( replyStatus != ClientRequestInfoImpl.UNINITIALIZED ) { throw wrapper.replyStatusNotInit() ; } }
Example #14
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
protected void continueOrThrowSystemOrRemarshal( CorbaMessageMediator messageMediator, Exception exception) throws SystemException, RemarshalException { ORB orb = (ORB) messageMediator.getBroker(); if( exception == null ) { // do nothing. } else if( exception instanceof RemarshalException ) { // REVISIT - unify with PI handling orb.getInvocationInfo().setIsRetryInvocation(true); // NOTE - We must unregister the waiter NOW for this request // since the retry will result in a new request id. Therefore // the old request id would be lost and we would have a memory // leak in the responseWaitingRoom. unregisterWaiter(orb); if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing Remarshal"); } throw (RemarshalException)exception; } else { if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing sex:" + exception); } throw (SystemException)exception; } }
Example #15
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #16
Source File: PINoOpHandlerImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { }
Example #17
Source File: PIHandlerImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { if( !hasClientInterceptors ) return; if( !isClientPIEnabledForThisThread() ) return; // Invoke the starting interception points and record exception // and reply status info in the info object: ClientRequestInfoImpl info = peekClientRequestInfoImplStack(); interceptorInvoker.invokeClientInterceptorStartingPoint( info ); // Check reply status. If we will not have another chance later // to invoke the client ending points, do it now. short replyStatus = info.getReplyStatus(); if( (replyStatus == SYSTEM_EXCEPTION.value) || (replyStatus == LOCATION_FORWARD.value) ) { // Note: Transport retry cannot happen here since this happens // before the request hits the wire. Exception exception = invokeClientPIEndingPoint( convertPIReplyStatusToReplyMessage( replyStatus ), info.getException() ); if( exception == null ) { // Do not throw anything. Otherwise, it must be a // SystemException, UserException or RemarshalException. } if( exception instanceof SystemException ) { throw (SystemException)exception; } else if( exception instanceof RemarshalException ) { throw (RemarshalException)exception; } else if( (exception instanceof UserException) || (exception instanceof ApplicationException) ) { // It should not be possible for an interceptor to throw // a UserException. By asserting instead of throwing the // UserException, we need not declare anything but // RemarshalException in the throws clause. throw wrapper.exceptionInvalid() ; } } else if( replyStatus != ClientRequestInfoImpl.UNINITIALIZED ) { throw wrapper.replyStatusNotInit() ; } }
Example #18
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
protected void continueOrThrowSystemOrRemarshal( CorbaMessageMediator messageMediator, Exception exception) throws SystemException, RemarshalException { ORB orb = (ORB) messageMediator.getBroker(); if( exception == null ) { // do nothing. } else if( exception instanceof RemarshalException ) { // REVISIT - unify with PI handling orb.getInvocationInfo().setIsRetryInvocation(true); // NOTE - We must unregister the waiter NOW for this request // since the retry will result in a new request id. Therefore // the old request id would be lost and we would have a memory // leak in the responseWaitingRoom. unregisterWaiter(orb); if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing Remarshal"); } throw (RemarshalException)exception; } else { if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing sex:" + exception); } throw (SystemException)exception; } }
Example #19
Source File: CorbaClientRequestDispatcherImpl.java From jdk1.8-source-analysis with Apache License 2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #20
Source File: CorbaClientRequestDispatcherImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #21
Source File: CorbaClientRequestDispatcherImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
protected void continueOrThrowSystemOrRemarshal( CorbaMessageMediator messageMediator, Exception exception) throws SystemException, RemarshalException { ORB orb = (ORB) messageMediator.getBroker(); if( exception == null ) { // do nothing. } else if( exception instanceof RemarshalException ) { // REVISIT - unify with PI handling orb.getInvocationInfo().setIsRetryInvocation(true); // NOTE - We must unregister the waiter NOW for this request // since the retry will result in a new request id. Therefore // the old request id would be lost and we would have a memory // leak in the responseWaitingRoom. unregisterWaiter(orb); if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing Remarshal"); } throw (RemarshalException)exception; } else { if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing sex:" + exception); } throw (SystemException)exception; } }
Example #22
Source File: PIHandlerImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { if( !hasClientInterceptors ) return; if( !isClientPIEnabledForThisThread() ) return; // Invoke the starting interception points and record exception // and reply status info in the info object: ClientRequestInfoImpl info = peekClientRequestInfoImplStack(); interceptorInvoker.invokeClientInterceptorStartingPoint( info ); // Check reply status. If we will not have another chance later // to invoke the client ending points, do it now. short replyStatus = info.getReplyStatus(); if( (replyStatus == SYSTEM_EXCEPTION.value) || (replyStatus == LOCATION_FORWARD.value) ) { // Note: Transport retry cannot happen here since this happens // before the request hits the wire. Exception exception = invokeClientPIEndingPoint( convertPIReplyStatusToReplyMessage( replyStatus ), info.getException() ); if( exception == null ) { // Do not throw anything. Otherwise, it must be a // SystemException, UserException or RemarshalException. } if( exception instanceof SystemException ) { throw (SystemException)exception; } else if( exception instanceof RemarshalException ) { throw (RemarshalException)exception; } else if( (exception instanceof UserException) || (exception instanceof ApplicationException) ) { // It should not be possible for an interceptor to throw // a UserException. By asserting instead of throwing the // UserException, we need not declare anything but // RemarshalException in the throws clause. throw wrapper.exceptionInvalid() ; } } else if( replyStatus != ClientRequestInfoImpl.UNINITIALIZED ) { throw wrapper.replyStatusNotInit() ; } }
Example #23
Source File: PINoOpHandlerImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { }
Example #24
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #25
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
protected void continueOrThrowSystemOrRemarshal( CorbaMessageMediator messageMediator, Exception exception) throws SystemException, RemarshalException { ORB orb = (ORB) messageMediator.getBroker(); if( exception == null ) { // do nothing. } else if( exception instanceof RemarshalException ) { // REVISIT - unify with PI handling orb.getInvocationInfo().setIsRetryInvocation(true); // NOTE - We must unregister the waiter NOW for this request // since the retry will result in a new request id. Therefore // the old request id would be lost and we would have a memory // leak in the responseWaitingRoom. unregisterWaiter(orb); if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing Remarshal"); } throw (RemarshalException)exception; } else { if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing sex:" + exception); } throw (SystemException)exception; } }
Example #26
Source File: PIHandlerImpl.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { if( !hasClientInterceptors ) return; if( !isClientPIEnabledForThisThread() ) return; // Invoke the starting interception points and record exception // and reply status info in the info object: ClientRequestInfoImpl info = peekClientRequestInfoImplStack(); interceptorInvoker.invokeClientInterceptorStartingPoint( info ); // Check reply status. If we will not have another chance later // to invoke the client ending points, do it now. short replyStatus = info.getReplyStatus(); if( (replyStatus == SYSTEM_EXCEPTION.value) || (replyStatus == LOCATION_FORWARD.value) ) { // Note: Transport retry cannot happen here since this happens // before the request hits the wire. Exception exception = invokeClientPIEndingPoint( convertPIReplyStatusToReplyMessage( replyStatus ), info.getException() ); if( exception == null ) { // Do not throw anything. Otherwise, it must be a // SystemException, UserException or RemarshalException. } if( exception instanceof SystemException ) { throw (SystemException)exception; } else if( exception instanceof RemarshalException ) { throw (RemarshalException)exception; } else if( (exception instanceof UserException) || (exception instanceof ApplicationException) ) { // It should not be possible for an interceptor to throw // a UserException. By asserting instead of throwing the // UserException, we need not declare anything but // RemarshalException in the throws clause. throw wrapper.exceptionInvalid() ; } } else if( replyStatus != ClientRequestInfoImpl.UNINITIALIZED ) { throw wrapper.replyStatusNotInit() ; } }
Example #27
Source File: PINoOpHandlerImpl.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { }
Example #28
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
public InputObject marshalingComplete1( ORB orb, CorbaMessageMediator messageMediator) throws ApplicationException, org.omg.CORBA.portable.RemarshalException { try { messageMediator.finishSendingRequest(); if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": finished sending request"); } return messageMediator.waitForResponse(); } catch (RuntimeException e) { if (orb.subcontractDebugFlag) { dprint(".marshalingComplete: " + opAndId(messageMediator) + ": exception: " + e.toString()); } boolean retry = getContactInfoListIterator(orb) .reportException(messageMediator.getContactInfo(), e); //Bug 6382377: must not lose exception in PI // Must run interceptor end point before retrying. Exception newException = orb.getPIHandler().invokeClientPIEndingPoint( ReplyMessage.SYSTEM_EXCEPTION, e); if (retry) { if (newException == e) { continueOrThrowSystemOrRemarshal(messageMediator, new RemarshalException()); } else { continueOrThrowSystemOrRemarshal(messageMediator, newException); } } else { if (newException instanceof RuntimeException){ throw (RuntimeException)newException; } else if (newException instanceof RemarshalException) { throw (RemarshalException)newException; } // NOTE: Interceptor ending point will run in releaseReply. throw e; } return null; // for compiler } }
Example #29
Source File: CorbaClientRequestDispatcherImpl.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
protected void continueOrThrowSystemOrRemarshal( CorbaMessageMediator messageMediator, Exception exception) throws SystemException, RemarshalException { ORB orb = (ORB) messageMediator.getBroker(); if( exception == null ) { // do nothing. } else if( exception instanceof RemarshalException ) { // REVISIT - unify with PI handling orb.getInvocationInfo().setIsRetryInvocation(true); // NOTE - We must unregister the waiter NOW for this request // since the retry will result in a new request id. Therefore // the old request id would be lost and we would have a memory // leak in the responseWaitingRoom. unregisterWaiter(orb); if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing Remarshal"); } throw (RemarshalException)exception; } else { if (orb.subcontractDebugFlag) { dprint(".continueOrThrowSystemOrRemarshal: " + opAndId(messageMediator) + ": throwing sex:" + exception); } throw (SystemException)exception; } }
Example #30
Source File: PIHandlerImpl.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
public void invokeClientPIStartingPoint() throws RemarshalException { if( !hasClientInterceptors ) return; if( !isClientPIEnabledForThisThread() ) return; // Invoke the starting interception points and record exception // and reply status info in the info object: ClientRequestInfoImpl info = peekClientRequestInfoImplStack(); interceptorInvoker.invokeClientInterceptorStartingPoint( info ); // Check reply status. If we will not have another chance later // to invoke the client ending points, do it now. short replyStatus = info.getReplyStatus(); if( (replyStatus == SYSTEM_EXCEPTION.value) || (replyStatus == LOCATION_FORWARD.value) ) { // Note: Transport retry cannot happen here since this happens // before the request hits the wire. Exception exception = invokeClientPIEndingPoint( convertPIReplyStatusToReplyMessage( replyStatus ), info.getException() ); if( exception == null ) { // Do not throw anything. Otherwise, it must be a // SystemException, UserException or RemarshalException. } if( exception instanceof SystemException ) { throw (SystemException)exception; } else if( exception instanceof RemarshalException ) { throw (RemarshalException)exception; } else if( (exception instanceof UserException) || (exception instanceof ApplicationException) ) { // It should not be possible for an interceptor to throw // a UserException. By asserting instead of throwing the // UserException, we need not declare anything but // RemarshalException in the throws clause. throw wrapper.exceptionInvalid() ; } } else if( replyStatus != ClientRequestInfoImpl.UNINITIALIZED ) { throw wrapper.replyStatusNotInit() ; } }