idx int64 0 41.2k | question stringlengths 73 5.81k | target stringlengths 5 918 |
|---|---|---|
24,000 | public final ControlSilence createNewControlSilence ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlSilence" ) ; ControlSilence msg = null ; try { msg = new ControlSilenceImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlSilence" ) ; return msg ; } | Create a new empty ControlSilence message |
24,001 | public final ControlAck createNewControlAck ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlAck" ) ; ControlAck msg = null ; try { msg = new ControlAckImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlAck" ) ; return msg ; } | Create a new empty ControlAck message |
24,002 | public final ControlNack createNewControlNack ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlNack" ) ; ControlNack msg = null ; try { msg = new ControlNackImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlNack" ) ; return msg ; } | Create a new empty ControlNack message |
24,003 | public final ControlPrevalue createNewControlPrevalue ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlPrevalue" ) ; ControlPrevalue msg = null ; try { msg = new ControlPrevalueImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlPrevalue" ) ; return msg ; } | Create a new empty ControlPrevalue message |
24,004 | public final ControlAccept createNewControlAccept ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlAccept" ) ; ControlAccept msg = null ; try { msg = new ControlAcceptImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlAccept" ) ; return msg ; } | Create a new empty ControlAccept message |
24,005 | public final ControlReject createNewControlReject ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlReject" ) ; ControlReject msg = null ; try { msg = new ControlRejectImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlReject" ) ; return msg ; } | Create a new empty ControlReject message |
24,006 | public final ControlDecision createNewControlDecision ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlDecision" ) ; ControlDecision msg = null ; try { msg = new ControlDecisionImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlDecision" ) ; return msg ; } | Create a new empty ControlDecision message |
24,007 | public final ControlRequest createNewControlRequest ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlRequest" ) ; ControlRequest msg = null ; try { msg = new ControlRequestImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlRequest" ) ; return msg ; } | Create a new empty ControlRequest Message |
24,008 | public final ControlRequestAck createNewControlRequestAck ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlRequestAck" ) ; ControlRequestAck msg = null ; try { msg = new ControlRequestAckImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlRequestAck" ) ; return msg ; } | Create a new empty ControlRequestAck Message |
24,009 | public final ControlRequestHighestGeneratedTick createNewControlRequestHighestGeneratedTick ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlRequestHighestGeneratedTick" ) ; ControlRequestHighestGeneratedTick msg = null ; try { msg = new ControlRequestHighestGeneratedTickImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlRequestHighestGeneratedTick" ) ; return msg ; } | Create a new empty ControlRequestHighestGeneratedTick Message |
24,010 | public final ControlHighestGeneratedTick createNewControlHighestGeneratedTick ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlHighestGeneratedTick" ) ; ControlHighestGeneratedTick msg = null ; try { msg = new ControlHighestGeneratedTickImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlHighestGeneratedTick" ) ; return msg ; } | Create a new empty ControlHighestGeneratedTick Message |
24,011 | public final ControlResetRequestAck createNewControlResetRequestAck ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlResetRequestAck" ) ; ControlResetRequestAck msg = null ; try { msg = new ControlResetRequestAckImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlResetRequestAck" ) ; return msg ; } | Create a new empty ControlResetRequestAck Message |
24,012 | public final ControlResetRequestAckAck createNewControlResetRequestAckAck ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlResetRequestAckAck" ) ; ControlResetRequestAckAck msg = null ; try { msg = new ControlResetRequestAckAckImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlResetRequestAckAck" ) ; return msg ; } | Create a new empty ControlResetRequestAckAck Message |
24,013 | public final ControlBrowseGet createNewControlBrowseGet ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlBrowseGet" ) ; ControlBrowseGet msg = null ; try { msg = new ControlBrowseGetImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlBrowseGet" ) ; return msg ; } | Create a new empty ControlBrowseGet Message |
24,014 | public final ControlBrowseEnd createNewControlBrowseEnd ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlBrowseEnd" ) ; ControlBrowseEnd msg = null ; try { msg = new ControlBrowseEndImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlBrowseEnd" ) ; return msg ; } | Create a new empty ControlBrowseEnd Message |
24,015 | public final ControlBrowseStatus createNewControlBrowseStatus ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlBrowseStatus" ) ; ControlBrowseStatus msg = null ; try { msg = new ControlBrowseStatusImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlBrowseStatus" ) ; return msg ; } | Create a new empty ControlBrowseStatus Message |
24,016 | public final ControlCompleted createNewControlCompleted ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlCompleted" ) ; ControlCompleted msg = null ; try { msg = new ControlCompletedImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlCompleted" ) ; return msg ; } | Create a new empty ControlCompleted Message |
24,017 | public final ControlDecisionExpected createNewControlDecisionExpected ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlDecisionExpected" ) ; ControlDecisionExpected msg = null ; try { msg = new ControlDecisionExpectedImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlDecisionExpected" ) ; return msg ; } | Create a new empty ControlDecisionExpected Message |
24,018 | public final ControlCreateStream createNewControlCreateStream ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlCreateStream" ) ; ControlCreateStream msg = null ; try { msg = new ControlCreateStreamImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlCreateStream" ) ; return msg ; } | Create a new empty ControlCreateStream Message |
24,019 | public final ControlAreYouFlushed createNewControlAreYouFlushed ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlAreYouFlushed" ) ; ControlAreYouFlushed msg = null ; try { msg = new ControlAreYouFlushedImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlAreYouFlushed" ) ; return msg ; } | Create a new empty ControlAreYouFlushed Message |
24,020 | public final ControlFlushed createNewControlFlushed ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlFlushed" ) ; ControlFlushed msg = null ; try { msg = new ControlFlushedImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlFlushed" ) ; return msg ; } | Create a new empty ControlFlushed Message |
24,021 | public final ControlNotFlushed createNewControlNotFlushed ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlNotFlushed" ) ; ControlNotFlushed msg = null ; try { msg = new ControlNotFlushedImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlNotFlushed" ) ; return msg ; } | Create a new empty ControlNotFlushed Message |
24,022 | public final ControlRequestFlush createNewControlRequestFlush ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlRequestFlush" ) ; ControlRequestFlush msg = null ; try { msg = new ControlRequestFlushImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlRequestFlush" ) ; return msg ; } | Create a new empty ControlRequestFlush Message |
24,023 | public final ControlRequestCardinalityInfo createNewControlRequestCardinalityInfo ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlRequestCardinalityInfo" ) ; ControlRequestCardinalityInfo msg = null ; try { msg = new ControlRequestCardinalityInfoImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlRequestCardinalityInfo" ) ; return msg ; } | Create a new empty ControlRequestCardinalityInfo Message |
24,024 | public final ControlCardinalityInfo createNewControlCardinalityInfo ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlCardinalityInfo" ) ; ControlCardinalityInfo msg = null ; try { msg = new ControlCardinalityInfoImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlCardinalityInfo" ) ; return msg ; } | Create a new empty ControlCardinalityInfo Message |
24,025 | public final ControlCreateDurable createNewControlCreateDurable ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlCreateDurable" ) ; ControlCreateDurable msg = null ; try { msg = new ControlCreateDurableImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlCreateDurable" ) ; return msg ; } | Create a new empty ControlCreateDurable Message |
24,026 | public final ControlDeleteDurable createNewControlDeleteDurable ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlDeleteDurable" ) ; ControlDeleteDurable msg = null ; try { msg = new ControlDeleteDurableImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlDeleteDurable" ) ; return msg ; } | Create a new empty ControlDeleteDurable Message |
24,027 | public final ControlDurableConfirm createNewControlDurableConfirm ( ) throws MessageCreateFailedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewControlDurableConfirm" ) ; ControlDurableConfirm msg = null ; try { msg = new ControlDurableConfirmImpl ( MfpConstants . CONSTRUCTOR_NO_OP ) ; } catch ( MessageDecodeFailedException e ) { throw new MessageCreateFailedException ( e ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createNewControlDurableConfirm" ) ; return msg ; } | Create a new empty ControlDurableConfirm Message |
24,028 | public void service ( ServletRequest req , ServletResponse res ) throws ServletException , IOException { HttpServletRequest request ; HttpServletResponse response ; try { request = ( HttpServletRequest ) req ; if ( collaborator != null ) { ComponentMetaData componentMetaData = ComponentMetaDataAccessorImpl . getComponentMetaDataAccessor ( ) . getComponentMetaData ( ) ; request = new JaxWsHttpServletRequestAdapter ( request , collaborator , componentMetaData ) ; } response = ( HttpServletResponse ) res ; } catch ( ClassCastException e ) { throw new ServletException ( "Unrecognized HTTP request or response object" , e ) ; } String method = request . getMethod ( ) ; if ( KNOWN_HTTP_VERBS . contains ( method ) ) { super . service ( request , response ) ; } else { handleRequest ( request , response ) ; } } | As AbstractHTTPServlet in CXF with this it will make sure that all the request methods will be routed to handleRequest method . |
24,029 | private void reportAvailableService ( HttpServletRequest request , HttpServletResponse response ) throws IOException { PrintWriter writer = response . getWriter ( ) ; response . setContentType ( HTML_CONTENT_TYPE ) ; writer . println ( "<h2>" + request . getServletPath ( ) + "</h2>" ) ; writer . println ( "<h3>Hello! This is a CXF Web Service!</h3>" ) ; } | Prints a welcome message for the endpoint |
24,030 | public void registerForEvents ( SIMPMessage msg ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "registerForEvents" , msg ) ; msg . registerMessageEventListener ( MessageEvents . PRE_PREPARE_TRANSACTION , this ) ; if ( msg . getReportCOD ( ) != null && _destination instanceof BaseDestinationHandler ) msg . registerMessageEventListener ( MessageEvents . COD_CALLBACK , ( BaseDestinationHandler ) _destination ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "registerForEvents" ) ; } | Register for the pre prepare callback . |
24,031 | protected void remoteToLocalPut ( MessageItem msgItem ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "remoteToLocalPut" , new Object [ ] { msgItem } ) ; _targetStreamManager . handleMessage ( msgItem ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "remoteToLocalPut" ) ; } | This is a put message that has oringinated from another ME |
24,032 | public void reconstituteTargetStreams ( StreamSet streamSet ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "reconstituteTargetStreams" , streamSet ) ; _targetStreamManager . reconstituteStreamSet ( streamSet ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "reconstituteTargetStreams" ) ; } | Used to restore the GD target stream |
24,033 | public OutputHandler handleMessage ( MessageItem msg ) throws SIMPNotPossibleInCurrentConfigurationException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "handleMessage" , msg ) ; msg . setCurrentMEArrivalTimestamp ( System . currentTimeMillis ( ) ) ; Reliability msgReliability = msg . getReliability ( ) ; if ( msgReliability == Reliability . NONE ) { msgReliability = _destination . getDefaultReliability ( ) ; msg . setReliability ( msgReliability ) ; } else { if ( msgReliability . compareTo ( _destination . getMaxReliability ( ) ) > 0 ) { if ( ( _destination . isTemporary ( ) || _destination . getName ( ) . equals ( _messageProcessor . getTDReceiverAddr ( ) . getDestinationName ( ) ) ) && ( msg . getReliability ( ) . compareTo ( Reliability . RELIABLE_PERSISTENT ) >= 0 ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "handleMessage" , "Sending ASSURED message to temporary destination" ) ; } else { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "handleMessage" , "Reliablity greater than dest" ) ; SIMPNotPossibleInCurrentConfigurationException e = new SIMPNotPossibleInCurrentConfigurationException ( nls_cwsik . getFormattedMessage ( "DELIVERY_ERROR_SIRC_33" , new Object [ ] { msg . getReliability ( ) . toString ( ) , _destination . getMaxReliability ( ) . toString ( ) , _destination . getName ( ) , _messageProcessor . getMessagingEngineName ( ) } , null ) ) ; e . setExceptionReason ( SIRCConstants . SIRC0033_MESSAGE_RELIABILITY_ERROR ) ; e . setExceptionInserts ( new String [ ] { msg . getReliability ( ) . toString ( ) , _destination . getMaxReliability ( ) . toString ( ) , _destination . getName ( ) , _messageProcessor . getMessagingEngineName ( ) } ) ; throw e ; } } } if ( _destination . isTemporary ( ) || _destination . getName ( ) . equals ( _messageProcessor . getTDReceiverAddr ( ) . getDestinationName ( ) ) ) { msg . setMaxStorageStrategy ( AbstractItem . STORE_MAYBE ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "handleMessage" ) ; return null ; } | Puts a message to the InputHandlers destination |
24,034 | public void registerMessage ( MessageItem msg , TransactionCommon tran ) throws SIIncorrectCallException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "registerMessage" , new Object [ ] { msg , tran } ) ; if ( tran != null && ! tran . isAlive ( ) ) { SIMPIncorrectCallException e = new SIMPIncorrectCallException ( nls_cwsik . getFormattedMessage ( "DELIVERY_ERROR_SIRC_16" , new Object [ ] { _destination } , null ) ) ; e . setExceptionReason ( SIRCConstants . SIRC0016_TRANSACTION_SEND_USAGE_ERROR ) ; e . setExceptionInserts ( new String [ ] { _destination . getName ( ) } ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) SibTr . exception ( tc , e ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "registerMessage" , e ) ; throw e ; } registerForEvents ( msg ) ; tran . registerCallback ( msg ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "registerMessage" ) ; } | Method registerMessage . |
24,035 | public ReturnCode dump ( ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverDumping" ) , serverName ) ) ; Set < JavaDumpAction > javaDumpActions = new LinkedHashSet < JavaDumpAction > ( ) ; parseJavaDumpInclude ( javaDumpActions ) ; ServerDumpPackager sdp = new ServerDumpPackager ( bootProps , launchArgs . getOption ( BootstrapConstants . CLI_ARG_ARCHIVE_TARGET ) ) ; sdp . initializeDumpDirectory ( ) ; ReturnCode dumpRc = createDumps ( javaDumpActions , true , sdp . getDumpTimestamp ( ) ) ; boolean serverInactiveStatusFlag = dumpRc == ReturnCode . SERVER_INACTIVE_STATUS ; boolean serverUnknownStatusFlag = dumpRc == ReturnCode . SERVER_UNKNOWN_STATUS ; boolean serverCommandPortDisabledFlag = dumpRc == ReturnCode . SERVER_COMMAND_PORT_DISABLED_STATUS ; if ( dumpRc == ReturnCode . OK ) { File dumpedFlag = new File ( sdp . getDumpDir ( ) , BootstrapConstants . SERVER_DUMPED_FLAG_FILE_NAME ) ; if ( ! dumpedFlag . exists ( ) ) { dumpRc = ReturnCode . ERROR_SERVER_DUMP ; } } if ( dumpRc == ReturnCode . OK || dumpRc == ReturnCode . SERVER_INACTIVE_STATUS || dumpRc == ReturnCode . SERVER_UNKNOWN_STATUS || dumpRc == ReturnCode . SERVER_COMMAND_PORT_DISABLED_STATUS ) { if ( javaDumpActions != null && ( ! ! ! javaDumpActions . isEmpty ( ) ) ) { dumpRc = sdp . packageDump ( true ) ; } else { dumpRc = sdp . packageDump ( false ) ; } } sdp . cleanupDumpDirectory ( ) ; if ( dumpRc == ReturnCode . OK ) { if ( serverInactiveStatusFlag ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverNotRunning" ) , serverName ) ) ; } if ( serverUnknownStatusFlag ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverStatusException" ) , serverName ) ) ; dumpRc = ReturnCode . SERVER_UNKNOWN_STATUS ; } if ( serverCommandPortDisabledFlag ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "warning.serverDumpCompleteCommandPortDisabled" ) , serverName , sdp . getDumpFile ( ) . getAbsolutePath ( ) ) ) ; } else { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverDumpComplete" ) , serverName , sdp . getDumpFile ( ) . getAbsolutePath ( ) ) ) ; } } else { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverDumpException" ) , serverName ) ) ; } return dumpRc ; } | Dump the server |
24,036 | public static Map < JavaDumpAction , String > readJavaDumpLocations ( File javaDumpLocationFile ) { Map < JavaDumpAction , String > fileLocations = new EnumMap < JavaDumpAction , String > ( JavaDumpAction . class ) ; BufferedReader reader = null ; try { reader = new BufferedReader ( new InputStreamReader ( new FileInputStream ( javaDumpLocationFile ) , "UTF-8" ) ) ; for ( String line ; ( line = reader . readLine ( ) ) != null ; ) { int index = line . indexOf ( '=' ) ; String actionName = line . substring ( 0 , index ) ; String fileName = line . substring ( index + 1 ) . trim ( ) ; fileLocations . put ( JavaDumpAction . valueOf ( actionName ) , fileName ) ; } } catch ( IOException ex ) { return null ; } finally { Utils . tryToClose ( reader ) ; } return fileLocations ; } | Read in the file containing the location of the java dumps and populate into a map of dump type to file location |
24,037 | private ReturnCode createDumps ( Set < JavaDumpAction > javaDumpActions , boolean introspect , String dumpTimestamp ) { ServerLock serverLock = ServerLock . createTestLock ( bootProps ) ; ReturnCode dumpRc = ReturnCode . OK ; boolean lockExists = serverLock . lockFileExists ( ) ; if ( lockExists ) { if ( serverLock . testServerRunning ( ) ) { ServerCommandClient scc = new ServerCommandClient ( bootProps ) ; if ( scc . isValid ( ) ) { if ( introspect ) { dumpRc = scc . introspectServer ( dumpTimestamp , javaDumpActions ) ; } else { dumpRc = scc . javaDump ( javaDumpActions ) ; } } else { dumpRc = ReturnCode . SERVER_UNKNOWN_STATUS ; } } else { dumpRc = ReturnCode . SERVER_INACTIVE_STATUS ; } } else { dumpRc = ReturnCode . SERVER_INACTIVE_STATUS ; } return dumpRc ; } | Run the relevant command for dumping the system |
24,038 | public ReturnCode pause ( ) { ServerLock serverLock = ServerLock . createTestLock ( bootProps ) ; ReturnCode pauseRc = ReturnCode . PAUSE_ACTION ; boolean lockExists = serverLock . lockFileExists ( ) ; String targetParm = launchArgs . getOption ( "target" ) ; if ( lockExists ) { if ( serverLock . testServerRunning ( ) ) { ServerCommandClient scc = new ServerCommandClient ( bootProps ) ; if ( scc . isValid ( ) ) { if ( targetParm != null ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pausingListeners.target" ) , serverName ) ) ; targetParm = "target=" + targetParm ; } else { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pausingListeners" ) , serverName ) ) ; } pauseRc = scc . pause ( targetParm ) ; } else { pauseRc = ReturnCode . SERVER_UNKNOWN_STATUS ; } } else { pauseRc = ReturnCode . SERVER_UNKNOWN_STATUS ; } } else { pauseRc = ReturnCode . SERVER_UNKNOWN_STATUS ; } if ( pauseRc == ReturnCode . OK ) { if ( targetParm != null ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pausedListeners.target" ) , serverName ) ) ; } else { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pausedListeners" ) , serverName ) ) ; } } else if ( pauseRc == ReturnCode . SERVER_UNKNOWN_STATUS ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.serverNotRunning" ) , serverName ) ) ; } else if ( pauseRc == ReturnCode . SERVER_COMMAND_PORT_DISABLED_STATUS ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "error.server.pause.command.port.disabled" ) , serverName ) ) ; } else { if ( targetParm != null ) { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pauseFailedException.target" ) , serverName ) ) ; } else { System . out . println ( MessageFormat . format ( BootstrapConstants . messages . getString ( "info.pauseFailedException" ) , serverName ) ) ; } } return pauseRc ; } | Pause inbound work to the Server . |
24,039 | protected boolean shouldSkipChildren ( Element jspElement ) throws JspCoreException { if ( ! shouldSkipChildrenForThisVisitor ( ) ) { return false ; } String uri = jspElement . getNamespaceURI ( ) ; String name = jspElement . getLocalName ( ) ; NodeList children ; if ( uri . equalsIgnoreCase ( Constants . JSP_NAMESPACE ) && name . equalsIgnoreCase ( Constants . JSP_BODY_TYPE ) ) { return isNodeTagDependent ( jspElement . getParentNode ( ) ) ; } if ( ! isElementTagDependent ( jspElement ) ) { return false ; } children = jspElement . getChildNodes ( ) ; if ( children . getLength ( ) == 0 ) { return false ; } for ( int i = 0 ; i < children . getLength ( ) ; ++ i ) { Node node = children . item ( i ) ; if ( node . getNodeType ( ) == Node . ELEMENT_NODE ) { Element element = ( Element ) node ; String elemURI = element . getNamespaceURI ( ) ; if ( elemURI . equalsIgnoreCase ( Constants . JSP_NAMESPACE ) ) { String elemName = element . getLocalName ( ) ; if ( elemName . equalsIgnoreCase ( Constants . JSP_ATTRIBUTE_TYPE ) || elemName . equalsIgnoreCase ( Constants . JSP_BODY_TYPE ) ) { return false ; } else { return true ; } } } } return false ; } | validate the children ) . |
24,040 | public void put ( QueueData queueData , short msgBatch ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "put" , new Object [ ] { queueData , "" + msgBatch } ) ; synchronized ( this ) { if ( ! ordered && batchesReady == 1 ) { SIErrorException e = new SIErrorException ( nls . getFormattedMessage ( "ASYNC_BATCH_ALREADY_READY_SICO1031" , null , null ) ) ; FFDCFilter . processException ( e , CLASS_NAME + ".put" , CommsConstants . ASYNCHPQ_PUT_01 , this ) ; throw e ; } queue . addLast ( queueData ) ; if ( ! queueData . isChunkedMessage ( ) ) { notifyMessageReceived ( queueData . isLastInBatch ( ) ) ; } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "Put has completed: " + this ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "put" ) ; } | Places a message onto the queue . |
24,041 | public void appendToLastMessage ( CommsByteBuffer msgBuffer , boolean lastChunk ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "appendToLastMessage" , new Object [ ] { msgBuffer , lastChunk } ) ; synchronized ( this ) { QueueData queueData = queue . getLast ( ) ; queueData . addSlice ( msgBuffer , lastChunk ) ; if ( lastChunk ) { notifyMessageReceived ( queueData . isLastInBatch ( ) ) ; } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "Append has completed: " + this ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "appendToLastMessage" ) ; } | This method is called when a middle or final chunk of a message has been received by the proxy queue . In this case we should append the chunk to those already collected and if this is the last chunk we perform the processing that would normally be done when a full message is received . |
24,042 | public synchronized void purge ( short sessionId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "purge" , "" + sessionId ) ; int [ ] indexsToDelete = new int [ queue . size ( ) ] ; int indexCount = 0 ; boolean completeBatchRemoved = false ; for ( int x = 0 ; x < queue . size ( ) ; x ++ ) { QueueData data = queue . get ( x ) ; if ( data . getProxyQueue ( ) . getId ( ) == sessionId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "Deleting item: " + data ) ; indexsToDelete [ indexCount ++ ] = x ; completeBatchRemoved = data . isLastInBatch ( ) ; } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "Removing " + indexCount + " entries" ) ; for ( int x = ( indexCount - 1 ) ; x >= 0 ; x -- ) { queue . remove ( indexsToDelete [ x ] ) ; } if ( completeBatchRemoved ) batchesReady -- ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "Purge completed. Queue is now: " + this ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "purge" ) ; } | This method will purge messages from the queue that belong to a particular session Id . |
24,043 | private synchronized JsMessage [ ] getBatch ( int batchSize , ConversationHelper convHelper ) throws SIResourceException , SIConnectionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getBatch" , new Object [ ] { batchSize , convHelper } ) ; if ( batchesReady == 0 ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "No batches are ready!!" ) ; SIErrorException e = new SIErrorException ( nls . getFormattedMessage ( "ASYNC_BATCH_NOT_READY_SICO1033" , null , null ) ) ; FFDCFilter . processException ( e , CLASS_NAME + ".getBatch" , CommsConstants . ASYNCHPQ_GETBATCH_01 , this ) ; throw e ; } int currentSessionId = 0 ; JsMessage [ ] msg = new JsMessage [ batchSize ] ; QueueData data = null ; for ( int i = 0 ; i < msg . length ; ++ i ) { data = queue . removeFirst ( ) ; currentSessionId = data . getProxyQueue ( ) . getId ( ) ; msg [ i ] = ( JsMessage ) data . getMessage ( ) ; if ( data . isLastInBatch ( ) ) break ; } batchesReady -- ; if ( ! isQueueEmpty ( ) ) { QueueData qd = queue . get ( 0 ) ; AsynchConsumerProxyQueue pq = ( AsynchConsumerProxyQueue ) qd . getProxyQueue ( ) ; if ( pq . getId ( ) != currentSessionId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "Next data on the queue is for a different session:" , pq ) ; pq . nudge ( ) ; } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "getBatch" , msg ) ; return msg ; } | Gets a batch of messages from the queue . |
24,044 | protected void setAuthDataService ( ServiceReference < AuthDataService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "setAuthDataService" , ref ) ; authDataServiceRef . setReference ( ref ) ; } | Declarative Services method for setting the AuthDataService reference . |
24,045 | protected void setDeferrableScheduledExecutor ( ServiceReference < ScheduledExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "setDeferrableScheduledExecutor" , ref ) ; deferrableSchedXSvcRef . setReference ( ref ) ; } | Declarative Services method for setting the deferrable scheduled executor service reference . |
24,046 | protected void setExecutor ( ServiceReference < ExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "setExecutor" , ref ) ; execSvcRef . setReference ( ref ) ; } | Declarative Services method for setting the executor service reference . |
24,047 | protected void setNonDeferrableScheduledExecutor ( ServiceReference < ScheduledExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "setNonDeferrableScheduledExecutor" , ref ) ; nonDeferrableSchedXSvcRef . setReference ( ref ) ; } | Declarative Services method for setting the non - deferrable scheduled executor service reference . |
24,048 | protected void unsetAuthDataService ( ServiceReference < AuthDataService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "unsetAuthDataService" , ref ) ; authDataServiceRef . unsetReference ( ref ) ; } | Declarative Services method for unsetting the AuthDataService reference . |
24,049 | protected void unsetDeferrableScheduledExecutor ( ServiceReference < ScheduledExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "unsetDeferrableScheduledExecutor" , ref ) ; deferrableSchedXSvcRef . unsetReference ( ref ) ; } | Declarative Services method for unsetting the deferrable scheduled executor service reference . |
24,050 | protected void unsetExecutor ( ServiceReference < ExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "unsetExecutor" , ref ) ; execSvcRef . unsetReference ( ref ) ; } | Declarative Services method for unsetting the executor service reference . |
24,051 | protected void unsetNonDeferrableScheduledExecutor ( ServiceReference < ScheduledExecutorService > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "unsetNonDeferrableScheduledExecutor" , ref ) ; nonDeferrableSchedXSvcRef . unsetReference ( ref ) ; } | Declarative Services method for unsetting the non - deferrable scheduled executor service reference . |
24,052 | protected void unsetRRSXAResourceFactory ( ServiceReference < Object > ref ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "unsetRRSXAResourceFactory" , ref ) ; rrsXAResFactorySvcRef . unsetReference ( ref ) ; } | Declarative Services method for unsetting the RRS XA resource factory service implementation reference . |
24,053 | public void saveRequestUrlAndParameters ( HttpServletRequest request , HttpServletResponse response ) { String cookieName = ReferrerURLCookieHandler . REFERRER_URL_COOKIENAME ; ReferrerURLCookieHandler referrerURLCookieHandler = getCookieHandler ( ) ; Cookie c = referrerURLCookieHandler . createCookie ( cookieName , getRequestUrlWithEncodedQueryString ( request ) , request ) ; response . addCookie ( c ) ; savePostParameters ( request , response ) ; } | Saves the original request URL and any POST parameters . |
24,054 | public void removeRequestUrlAndParameters ( HttpServletRequest request , HttpServletResponse response ) { ReferrerURLCookieHandler referrerURLCookieHandler = getCookieHandler ( ) ; referrerURLCookieHandler . invalidateReferrerURLCookie ( request , response , ReferrerURLCookieHandler . REFERRER_URL_COOKIENAME ) ; WebAppSecurityConfig webAppSecConfig = getWebAppSecurityConfig ( ) ; if ( isPostDataSavedInCookie ( webAppSecConfig ) ) { deleteCookie ( request , response , PostParameterHelper . POSTPARAM_COOKIE , webAppSecConfig ) ; } else { removePostParameterSessionAttributes ( request ) ; } } | Invalidates the original request URL cookie or removes the same respective session attributes depending on how the data was saved . |
24,055 | public void deleteCookie ( HttpServletRequest request , HttpServletResponse response , String cookieName , WebAppSecurityConfig webAppSecConfig ) { ReferrerURLCookieHandler referrerURLCookieHandler = getCookieHandler ( ) ; referrerURLCookieHandler . clearReferrerURLCookie ( request , response , cookieName ) ; Cookie paramCookie = createExpiredCookie ( request , cookieName , webAppSecConfig ) ; response . addCookie ( paramCookie ) ; } | Clears the specified cookie and sets its path to the current request URI . |
24,056 | public Constructor < T > getConstructor ( ) { if ( this . constructor == null ) { try { this . constructor = this . managedClass . getConstructor ( ( Class < ? > [ ] ) null ) ; } catch ( NoSuchMethodException e ) { throw new IllegalStateException ( e ) ; } } return this . constructor ; } | Returns the constructor that will be used by this factory to create the managed object . |
24,057 | public void setConfiguration ( VirtualHost config ) { this . config = config ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "setConfiguration" , "config set ->" + this . config ) ; } } | Set or replace the underlying VirtualHost that provides host aliases and default mime type configuration . |
24,058 | public static void rcvResetBrowse ( CommsByteBuffer request , Conversation conversation , int requestNumber , boolean allocatedFromBufferPool , boolean partOfExchange ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "rcvResetBrowse" , new Object [ ] { request , conversation , "" + requestNumber , "" + allocatedFromBufferPool } ) ; short connectionObjectId = request . getShort ( ) ; short browserSessionId = request . getShort ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "rcvResetBrowse> connectionObjectId = " + connectionObjectId + "\nrcvResetBrowse> browserSessionId = " + browserSessionId ) ; BrowserSession browserSession = null ; ConversationState convState = null ; try { convState = ( ConversationState ) conversation . getAttachment ( ) ; CATMainConsumer mainConsumer = ( CATMainConsumer ) convState . getObject ( browserSessionId ) ; browserSession = mainConsumer . getBrowserSession ( ) ; if ( browserSession == null ) { SIErrorException e = new SIErrorException ( nls . getFormattedMessage ( "BROWSER_SESSION_NULL_SICO20" , null , null ) ) ; FFDCFilter . processException ( e , CLASS_NAME + ".rcvResetBrowse" , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_04 ) ; throw e ; } } catch ( NullPointerException npe ) { FFDCFilter . processException ( npe , CLASS_NAME + ".rcvResetBrowse" , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_01 ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "Browser session was null!" , npe ) ; StaticCATHelper . sendExceptionToClient ( npe , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_01 , conversation , requestNumber ) ; } if ( browserSession != null ) { try { browserSession . reset ( ) ; } catch ( SIException e ) { if ( ! convState . hasMETerminated ( ) ) { FFDCFilter . processException ( e , CLASS_NAME + ".rcvResetBrowse" , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_02 ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , e . getMessage ( ) , e ) ; StaticCATHelper . sendExceptionToClient ( e , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_02 , conversation , requestNumber ) ; } } CommsByteBuffer reply = poolManager . allocate ( ) ; try { conversation . send ( reply , JFapChannelConstants . SEG_RESET_BROWSE_R , requestNumber , JFapChannelConstants . PRIORITY_MEDIUM , true , ThrottlingPolicy . BLOCK_THREAD , null ) ; } catch ( SIException e ) { FFDCFilter . processException ( e , CLASS_NAME + ".rcvResetBrowse" , CommsConstants . STATICCATBROWSER_RCVRESETBROWSERSESS_03 ) ; SibTr . error ( tc , "COMMUNICATION_ERROR_SICO2020" , e ) ; } request . release ( allocatedFromBufferPool ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "rcvResetBrowse" ) ; } | Processes a request to reset a browser session . This is achieved by decoding the request data and using it to locate the browser session to reset . |
24,059 | public static String getLongestUrlPattern ( String firstUrlPattern , String secondUrlPattern ) { if ( secondUrlPattern == null || ( firstUrlPattern != null && firstUrlPattern . length ( ) >= secondUrlPattern . length ( ) ) ) { return firstUrlPattern ; } else { return secondUrlPattern ; } } | Determine the longest URL pattern . |
24,060 | public static boolean isPathNameMatch ( String uri , String urlPattern ) { if ( urlPattern . startsWith ( "/" ) && urlPattern . endsWith ( "/*" ) ) { String s = urlPattern . substring ( 0 , urlPattern . length ( ) - 1 ) ; if ( s . equalsIgnoreCase ( uri ) ) { return true ; } if ( uri . equalsIgnoreCase ( s . substring ( 0 , s . length ( ) - 1 ) ) ) { return true ; } if ( uri . startsWith ( s ) ) { return true ; } } return false ; } | Determine if the urlPattern is a path name match for the uri . |
24,061 | public static boolean isExtensionMatch ( String uriName , String urlPattern ) { if ( urlPattern . startsWith ( "*." ) ) { String ext = urlPattern . substring ( 1 ) ; if ( uriName . endsWith ( ext ) ) { return true ; } } return false ; } | Determine if the urlPattern is an extension match for the uriName . |
24,062 | public static void validateEditions ( AppliesToFilterInfo info , String appliesToHeader ) throws RepositoryResourceCreationException { if ( info . getRawEditions ( ) != null ) { for ( String rawEdition : info . getRawEditions ( ) ) { List < String > mappedEditions = mapRawEditionToHumanReadable ( rawEdition ) ; if ( mappedEditions . size ( ) == 1 && mappedEditions . get ( 0 ) . equals ( EDITION_UNKNOWN ) ) { throw new RepositoryResourceCreationException ( "Resource applies to at least one unknown edition: " + rawEdition + "; appliesTo= " + appliesToHeader , null ) ; } } } } | Validates the list of rawEditions and throws RepositoryResourceCreationException if any of them are unknown . |
24,063 | public static List < AppliesToEntry > parseAppliesToEntries ( String appliesTo ) { List < AppliesToEntry > result = new ArrayList < AppliesToEntry > ( ) ; List < List < String > > parsedProducts = doParse ( appliesTo ) ; for ( List < String > parsedProduct : parsedProducts ) { AppliesToEntry entry = new AppliesToEntry ( ) ; for ( String productChunk : parsedProduct ) { entry . add ( productChunk ) ; } result . add ( entry ) ; } return result ; } | Parse the given raw appliesTo header into a list of AppliesToEntry objects |
24,064 | public static Logger getLogger ( final String name , final String resourceBundleName ) { WebContainerLogger tempLogger = map . get ( name ) ; if ( tempLogger == null ) { tempLogger = ( WebContainerLogger ) AccessController . doPrivileged ( new PrivilegedAction < WebContainerLogger > ( ) { public WebContainerLogger run ( ) { return new WebContainerLogger ( Logger . getLogger ( name , resourceBundleName ) , name , resourceBundleName ) ; } } ) ; map . put ( name , tempLogger ) ; } return tempLogger ; } | getLogger method will create an instance of WebContainerLogger with the appropriate Logger object |
24,065 | public void logp ( Level level , String sourceClass , String sourceMethod , String msg ) { delegateLogger . logp ( level , sourceClass , sourceMethod , msg ) ; } | Override every method from Logger to be called on the delegateLogger . |
24,066 | public static String throwableToString ( Throwable t ) { StringWriter s = new StringWriter ( ) ; PrintWriter p = new PrintWriter ( s ) ; t . printStackTrace ( p ) ; return s . toString ( ) ; } | Accepts a throwable and returns a String representation . |
24,067 | public static JSPCache getJspCache ( String cacheName ) { final String methodName = "getJspCache()" ; JSPCache cacheOut = null ; if ( servletCacheEnabled == false ) { Tr . error ( tc , "DYNA1059W" , new Object [ ] { cacheName } ) ; } else { if ( cacheName != null ) { try { cacheOut = cacheUnit . getJSPCache ( cacheName ) ; } catch ( Exception e ) { Tr . error ( tc , "DYNA1003E" , new Object [ ] { cacheName , e } ) ; } } else { cacheOut = ServerCache . jspCache ; } } if ( cacheOut == null && TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , methodName + " could not find JSPCache for cacheName=" + cacheName ) ; } return cacheOut ; } | Get a named Jsp cache . |
24,068 | public static CommandCache getCommandCache ( String cacheName ) { final String methodName = "getCommandCache()" ; CommandCache cacheOut = null ; if ( servletCacheEnabled == false ) { Tr . error ( tc , "DYNA1059W" , new Object [ ] { cacheName } ) ; } else { if ( cacheName != null ) { try { cacheOut = cacheUnit . getCommandCache ( cacheName ) ; } catch ( Exception e ) { Tr . error ( tc , "DYNA1003E" , new Object [ ] { cacheName , e } ) ; } } else { cacheOut = ServerCache . commandCache ; } } if ( cacheOut == null && TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , methodName + " could not find CommandCache for cacheName=" + cacheName ) ; } return cacheOut ; } | Get a named Command cache . |
24,069 | public static DCache getCache ( String cacheName ) { final String methodName = "getCache()" ; DCache cacheOut = ServerCache . cache ; if ( cacheName != null ) { cacheName = normalizeCacheName ( cacheName , null ) ; } if ( cacheName != null && ! cacheName . equalsIgnoreCase ( DCacheBase . DEFAULT_CACHE_NAME ) ) { cacheOut = cacheInstances . get ( cacheName ) ; } if ( cacheOut == null && TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , methodName + " could not find cache for cacheName=" + cacheName ) ; } return cacheOut ; } | Get a named cache . Caller must check for null return . |
24,070 | public static DCache getConfiguredCache ( String cacheName ) { final String methodName = "getConfiguredCache()" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , methodName + " input cacheName=" + cacheName ) ; } DCache cacheOut = null ; if ( coreCacheEnabled == false ) { Tr . error ( tc , "DYNA1003E" , new Object [ ] { cacheName , "Core Cache Service has not been started." } ) ; } else { cacheOut = getCache ( cacheName ) ; if ( cacheOut == null ) { CacheConfig config = getCacheService ( ) . getCacheInstanceConfig ( cacheName ) ; if ( config == null ) { Tr . error ( tc , "DYNA1004E" , new Object [ ] { cacheName } ) ; cacheOut = null ; } else { cacheOut = createCache ( config . cacheName , config ) ; } } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . exit ( tc , methodName + " output cacheName=" + ( cacheOut != null ? cacheOut . getCacheName ( ) : "null" ) ) ; } return cacheOut ; } | Get a configured named cache . |
24,071 | public static String normalizeCacheName ( String cacheName , CacheConfig cacheConfig ) { String tempCacheName = cacheName ; if ( cacheName . equalsIgnoreCase ( DCacheBase . DEFAULT_BASE_JNDI_NAME ) ) { tempCacheName = DCacheBase . DEFAULT_CACHE_NAME ; } else if ( cacheName . equalsIgnoreCase ( DCacheBase . DEFAULT_DMAP_JNDI_NAME ) ) { tempCacheName = DCacheBase . DEFAULT_DISTRIBUTED_MAP_NAME ; } if ( null != cacheConfig && ! tempCacheName . equals ( cacheConfig . cacheName ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "normalized cacheName=" + cacheName + " does not match with cacheConfig cacheName=" + cacheConfig . cacheName ) ; } cacheConfig . cacheName = tempCacheName ; } return tempCacheName ; } | Since the cache instances are stored with key as cacheName it has to change default cache JNDI name to internal cache name . |
24,072 | public static int getLocalTID ( TransactionImpl tran ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getLocalTID" , tran ) ; int id ; while ( true ) { final int currSeed = _baseSeed ++ ; id = ( ++ _baseSeed << ( _baseSeed - currSeed ) ) & 0x7FFFFFFF ; if ( id > 0 && localTIDMap . putIfAbsent ( id , tran ) == null ) { break ; } } if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "getLocalTID" , id ) ; return id ; } | Return the next available local tid and associate it with the given transaction . This method should be used during the creation of a new transaction . |
24,073 | public static void removeLocalTID ( int localTID ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "removeLocalTID" , localTID ) ; localTIDMap . remove ( localTID ) ; if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "removeLocalTID" ) ; } | Remove the given local tid from the map . This method should be called once a transaction has completed . |
24,074 | public static TransactionImpl [ ] getAllTransactions ( ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getAllTransactions" ) ; final Collection < TransactionImpl > txns = localTIDMap . values ( ) ; if ( txns != null ) { if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "getAllTransactions" , txns ) ; return txns . toArray ( noTxns ) ; } if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "getAllTransactions" , noTxns ) ; return noTxns ; } | Return an array of all the transactions currently running on the server . |
24,075 | protected WSJdbcResultSet createWrapper ( ResultSet rsetImpl ) { WSJdbcResultSet rsetWrapper ; if ( childWrapper == null && ( childWrappers == null || childWrappers . isEmpty ( ) ) ) { childWrapper = rsetWrapper = mcf . jdbcRuntime . newResultSet ( rsetImpl , this ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "Set the result set to child wrapper" ) ; } else { if ( childWrappers == null ) childWrappers = new ArrayList < Wrapper > ( 5 ) ; rsetWrapper = mcf . jdbcRuntime . newResultSet ( rsetImpl , this ) ; childWrappers . add ( rsetWrapper ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "Add the result set to child wrappers list." ) ; } return rsetWrapper ; } | Construct and track a new result set wrapper . |
24,076 | private Object getCursor ( Object implObject , Method method , Object [ ] args ) throws IllegalAccessException , IllegalArgumentException , InvocationTargetException , SQLException { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getCursor" , this , args [ 0 ] ) ; ResultSet rsetImpl = ( ResultSet ) method . invoke ( implObject , args ) ; WSJdbcResultSet rsetWrapper = rsetImpl == null ? null : createWrapper ( rsetImpl ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . exit ( tc , "getCursor" , rsetWrapper ) ; return rsetWrapper ; } | Invokes getCursor and wraps the result set . |
24,077 | public Object getObject ( String parameterName , java . util . Map < String , Class < ? > > map ) throws SQLException { try { return cstmtImpl . getObject ( parameterName , map ) ; } catch ( SQLException ex ) { FFDCFilter . processException ( ex , "com.ibm.ws.rsadapter.jdbc.WSJdbcCallableStatement.getObject(String, Map)" , "1524" , this ) ; throw WSJdbcUtil . mapException ( this , ex ) ; } catch ( NullPointerException nullX ) { throw runtimeXIfNotClosed ( nullX ) ; } } | enhanced method signature . |
24,078 | public void processTAIUserFeatureProps ( ConcurrentServiceReferenceMap < String , TrustAssociationInterceptor > interceptorServiceRef , String interceptorId ) { invokeBeforeSSO = false ; invokeAfterSSO = false ; addLtpaCookieToResponse = true ; ServiceReference < TrustAssociationInterceptor > taiServiceRef = interceptorServiceRef . getReference ( interceptorId ) ; Object beforeSsoProp = taiServiceRef . getProperty ( TAIConfig . KEY_INVOKE_BEFORE_SSO ) ; Object afterSsoProp = taiServiceRef . getProperty ( TAIConfig . KEY_INVOKE_AFTER_SSO ) ; if ( taiServiceRef . getProperty ( TAIConfig . KEY_ADD_LTPA_TO_RESPONSE ) != null ) { addLtpaCookieToResponse = ( Boolean ) taiServiceRef . getProperty ( TAIConfig . KEY_ADD_LTPA_TO_RESPONSE ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "user feature have properties, beforeSsoProp=" + beforeSsoProp + " invokeAfterSSO=" + afterSsoProp + " addLtpaCookieToResponse=" + addLtpaCookieToResponse ) ; } if ( beforeSsoProp == null && afterSsoProp == null ) { invokeAfterSSO = true ; } else if ( beforeSsoProp == null && afterSsoProp != null ) { resolveOnlyInvokeAfterSSOSpecified ( afterSsoProp ) ; } else if ( beforeSsoProp != null && afterSsoProp == null ) { resolveOnlyInvokeBeforeSSOSpecified ( beforeSsoProp ) ; } else if ( beforeSsoProp != null && afterSsoProp != null ) { invokeBeforeSSO = ( Boolean ) beforeSsoProp ; invokeAfterSSO = ( Boolean ) afterSsoProp ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "resolve user feature have, invokeBeforeSSO=" + invokeBeforeSSO + " invokeAfterSSO=" + invokeAfterSSO + " addLtpaCookieToResponse=" + addLtpaCookieToResponse ) ; } } | This method will process the TAI user feature properties and determine whether this TAI will be invoked before or after the SSO authentication . Because we do not have a direct access to the TAI user feature configuration if any . |
24,079 | public void consolidate ( List targets ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "consolidate" , targets ) ; Iterator itr = targets . iterator ( ) ; levelUsersAllowedToSubscribe . clear ( ) ; levelUsersAllowedToPublish . clear ( ) ; levelGroupAllowedToSubscribe . clear ( ) ; levelGroupAllowedToPublish . clear ( ) ; while ( itr . hasNext ( ) ) { Object target = itr . next ( ) ; if ( target instanceof TopicAcl ) { Principal principal = ( ( TopicAcl ) target ) . getPrincipal ( ) ; if ( ( ( TopicAcl ) target ) . getOperationType ( ) == 1 ) { if ( principal == null ) { accumUsersAllowedToPublish . clear ( ) ; accumGroupAllowedToPublish . clear ( ) ; } else if ( principal instanceof Group ) { levelGroupAllowedToPublish . add ( principal ) ; } else { levelUsersAllowedToPublish . add ( principal ) ; } } else { if ( principal == null ) { accumUsersAllowedToSubscribe . clear ( ) ; accumGroupAllowedToSubscribe . clear ( ) ; } else if ( principal instanceof Group ) { levelGroupAllowedToSubscribe . add ( principal ) ; } else { levelUsersAllowedToSubscribe . add ( principal ) ; } } } } if ( ! levelUsersAllowedToSubscribe . isEmpty ( ) ) { accumUsersAllowedToSubscribe . addAll ( levelUsersAllowedToSubscribe ) ; } if ( ! levelUsersAllowedToPublish . isEmpty ( ) ) { accumUsersAllowedToPublish . addAll ( levelUsersAllowedToPublish ) ; } if ( ! levelGroupAllowedToSubscribe . isEmpty ( ) ) { accumGroupAllowedToSubscribe . addAll ( levelGroupAllowedToSubscribe ) ; } if ( ! levelGroupAllowedToPublish . isEmpty ( ) ) { accumGroupAllowedToPublish . addAll ( levelGroupAllowedToPublish ) ; } if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "consolidate" ) ; } | Method consolidate Used to add a set of acls to the accumulated permission vectors |
24,080 | public boolean checkPermission ( Principal user , int operation ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "checkPermission" , new Object [ ] { user , new Integer ( operation ) } ) ; boolean allowed = false ; if ( operation == 1 ) { if ( accumGroupAllowedToPublish . size ( ) > 0 && accumGroupAllowedToPublish . contains ( everyone ) ) { allowed = true ; } else if ( user . getName ( ) != null && user . getName ( ) . length ( ) > 0 ) { if ( accumUsersAllowedToPublish . size ( ) > 0 && accumUsersAllowedToPublish . contains ( user ) ) { allowed = true ; } else { if ( accumGroupAllowedToPublish . size ( ) > 0 ) { if ( accumGroupAllowedToPublish . contains ( allAuthenticated ) ) { allowed = true ; } else { Iterator itr = accumGroupAllowedToPublish . iterator ( ) ; while ( itr . hasNext ( ) ) { Group group = ( Group ) itr . next ( ) ; if ( group . isMember ( user ) ) { allowed = true ; break ; } } } } } } } else { if ( accumGroupAllowedToSubscribe . size ( ) > 0 && accumGroupAllowedToSubscribe . contains ( everyone ) ) { allowed = true ; } else if ( user . getName ( ) != null && user . getName ( ) . length ( ) > 0 ) { if ( accumUsersAllowedToSubscribe . size ( ) > 0 && accumUsersAllowedToSubscribe . contains ( user ) ) { allowed = true ; } else { if ( accumGroupAllowedToSubscribe . size ( ) > 0 ) { if ( accumGroupAllowedToSubscribe . contains ( allAuthenticated ) ) { allowed = true ; } else { Iterator itr = accumGroupAllowedToSubscribe . iterator ( ) ; while ( itr . hasNext ( ) ) { Group group = ( Group ) itr . next ( ) ; if ( group . isMember ( user ) ) { allowed = true ; break ; } } } } } } } if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "checkPermission" , new Boolean ( allowed ) ) ; return allowed ; } | Method checkPermission Used to determine whether a user is allowed to perform a particular operation . |
24,081 | protected void captureSystemStreams ( ) { PrintStream sysOut = System . out ; PrintStream sysErr = System . err ; PrintStream trSysOut = systemOut . getOriginalStream ( ) ; PrintStream trSysErr = systemErr . getOriginalStream ( ) ; if ( sysOut != trSysOut ) { throw new ConcurrentModificationException ( "Someone else has reset or cached System.out" ) ; } if ( sysErr != trSysErr ) { throw new ConcurrentModificationException ( "Someone else has reset or cached System.err" ) ; } super . captureSystemStreams ( ) ; } | This is not to be used by the SharedOutputManager! This is an override of the BaseTraceService method that captures system streams . |
24,082 | public void echo ( SystemLogHolder holder , LogRecord logRecord ) { TraceWriter detailLog = traceLog ; String message = formatter . messageLogFormat ( logRecord , logRecord . getMessage ( ) ) ; messagesLog . writeRecord ( message ) ; invokeMessageRouters ( new RoutedMessageImpl ( logRecord . getMessage ( ) , logRecord . getMessage ( ) , message , logRecord ) ) ; if ( detailLog == systemOut ) { publishTraceLogRecord ( holder , logRecord , NULL_ID , NULL_FORMATTED_MSG , NULL_FORMATTED_MSG ) ; } else { if ( copySystemStreams ) { writeFilteredStreamOutput ( holder , logRecord ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) ) { publishTraceLogRecord ( detailLog , logRecord , NULL_ID , NULL_FORMATTED_MSG , NULL_FORMATTED_MSG ) ; } } } | Overwritten for old BaseTraceService behaviour for echo |
24,083 | protected void publishTraceLogRecord ( TraceWriter detailLog , LogRecord logRecord , Object id , String formattedMsg , String formattedVerboseMsg ) { if ( formattedVerboseMsg == null ) { formattedVerboseMsg = formatter . formatVerboseMessage ( logRecord , formattedMsg , false ) ; } Level level = logRecord . getLevel ( ) ; int levelVal = level . intValue ( ) ; String traceDetail = formatter . traceLogFormat ( logRecord , id , formattedMsg , formattedVerboseMsg ) ; invokeTraceRouters ( new RoutedMessageImpl ( formattedMsg , formattedVerboseMsg , traceDetail , logRecord ) ) ; if ( traceDetail . contains ( "x.com.ibm" ) ) { return ; } if ( detailLog == systemOut || detailLog == systemErr ) { if ( levelVal == WsLevel . ERROR . intValue ( ) || levelVal == WsLevel . SEVERE . intValue ( ) ) { writeStreamOutput ( systemErr , traceDetail , false ) ; } else { writeStreamOutput ( ( SystemLogHolder ) detailLog , traceDetail , false ) ; } } else { detailLog . writeRecord ( traceDetail ) ; } } | Overwritten for old BaseTraceService behaviour for publishTraceLogRecord |
24,084 | public void setXSDTypeName ( String name ) { this . xsdTypeName = name ; Integer code = ( Integer ) JSBaseTypes . xsdTypeNames . get ( name ) ; if ( code == null ) throw new IllegalArgumentException ( "XSDTypeName=" + name ) ; setTypeCode ( code . intValue ( ) ) ; } | Set the XSD type name and as a side - effect set the type code most appropriate for use with that type |
24,085 | public void setTypeCode ( int typeCode ) { if ( typeCode <= 0 || typeCode >= JSBaseTypes . baseTypes . length ) throw new IllegalArgumentException ( "TypeCode=" + typeCode ) ; this . typeCode = typeCode ; baseType = JSBaseTypes . baseTypes [ typeCode ] ; } | Set the typeCode for the type . Doing this automatically sets all the other type information implied by the type . |
24,086 | @ FFDCIgnore ( { IOException . class , InterruptedException . class } ) public static List < String > executeProgramWithInput ( String input , String ... commandLine ) throws OperatingSystemException { try { ProcessBuilder builder = new ProcessBuilder ( ) ; builder . command ( commandLine ) ; Process process = builder . start ( ) ; if ( input != null ) { try ( OutputStream os = process . getOutputStream ( ) ) { try ( OutputStreamWriter osw = new OutputStreamWriter ( os ) ) { try ( BufferedWriter bw = new BufferedWriter ( osw ) ) { bw . write ( input ) ; bw . flush ( ) ; } } } } List < String > lines = new ArrayList < String > ( ) ; try ( InputStream is = process . getInputStream ( ) ) { try ( InputStreamReader isr = new InputStreamReader ( is ) ) { try ( BufferedReader br = new BufferedReader ( isr ) ) { String line ; while ( ( line = br . readLine ( ) ) != null ) { lines . add ( line ) ; } } } } int returnCode = process . waitFor ( ) ; if ( returnCode != 0 ) { throw new OperatingSystemException ( Tr . formatMessage ( tc , "os.execute.error" , commandLine , returnCode , lines ) ) ; } return lines ; } catch ( IOException e ) { throw new OperatingSystemException ( e ) ; } catch ( InterruptedException e ) { throw new OperatingSystemException ( e ) ; } } | On recent JDKs this should do a fork that doesn t duplicate the whole virtual address space . |
24,087 | protected Connection getConnection ( ConnectionRequestInfo connInfo ) throws SQLException { final boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "getConnection" , AdapterUtil . toString ( connInfo ) ) ; WSJdbcConnection connWrapper ; try { connWrapper = ( WSJdbcConnection ) cm . allocateConnection ( mcf , connInfo ) ; } catch ( ResourceException resX ) { FFDCFilter . processException ( resX , "com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource.getConnection" , "299" , this ) ; SQLException x = AdapterUtil . toSQLException ( resX ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . exit ( this , tc , "getConnection" , "Exception" ) ; throw x ; } try { connWrapper . initialize ( cm ) ; } catch ( SQLException sqlX ) { FFDCFilter . processException ( sqlX , "com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource.getConnection" , "280" , this ) ; sqlX = WSJdbcUtil . mapException ( connWrapper , sqlX ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . exit ( this , tc , "getConnection" , sqlX ) ; throw sqlX ; } Connection c = dsConfig . get ( ) . enableConnectionCasting ? connWrapper . getCastableWrapper ( vendorConnectionInterfaces ) : connWrapper ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . exit ( this , tc , "getConnection" , c ) ; return c ; } | This is the common getConnection implementation used by the other getConnection methods . This method handles the connection request to the CM and related exceptions including the ConnectionWaitTimeoutException . Exceptions thrown by the CM are converted to SQLExceptions . |
24,088 | private final int getDefaultIsolationLevel ( ) { int defaultIsolationLevel = resRefInfo == null ? Connection . TRANSACTION_NONE : resRefInfo . getIsolationLevel ( ) ; if ( defaultIsolationLevel == Connection . TRANSACTION_NONE ) defaultIsolationLevel = dsConfig . get ( ) . isolationLevel ; if ( defaultIsolationLevel == - 1 ) defaultIsolationLevel = mcf . getHelper ( ) . getDefaultIsolationLevel ( ) ; return defaultIsolationLevel ; } | Determine the default isolation level for this data source . |
24,089 | Object replaceObject ( ResourceRefConfigFactory resRefConfigFactory ) { DSConfig config = dsConfig . get ( ) ; String filter = config . jndiName == null || config . jndiName . startsWith ( "java:" ) ? FilterUtils . createPropertyFilter ( "config.displayId" , config . id ) : FilterUtils . createPropertyFilter ( ResourceFactory . JNDI_NAME , config . jndiName ) ; ResourceRefConfig resRefConfig = resRefInfo == null ? null : resRefConfigFactory . createResourceRefConfig ( DataSource . class . getName ( ) ) ; if ( resRefInfo != null ) { resRefConfig . setBranchCoupling ( resRefInfo . getBranchCoupling ( ) ) ; resRefConfig . setCommitPriority ( resRefInfo . getCommitPriority ( ) ) ; resRefConfig . setIsolationLevel ( resRefInfo . getIsolationLevel ( ) ) ; resRefConfig . setJNDIName ( resRefInfo . getJNDIName ( ) ) ; resRefConfig . setLoginConfigurationName ( resRefInfo . getLoginConfigurationName ( ) ) ; resRefConfig . setResAuthType ( resRefInfo . getAuth ( ) ) ; resRefConfig . setSharingScope ( resRefInfo . getSharingScope ( ) ) ; } return new SerializedDataSourceWrapper ( filter , resRefConfig ) ; } | Returns a replacement object that can be serialized instead of WSJdbcDataSource . |
24,090 | private static PersistenceUnit newPersistenceUnit ( final String fJndiName , final String fUnitName ) { return new PersistenceUnit ( ) { public String name ( ) { return fJndiName ; } public Class < ? extends Annotation > annotationType ( ) { return javax . persistence . PersistenceUnit . class ; } public String unitName ( ) { return fUnitName ; } public String toString ( ) { return "JPA.PersistenceUnit(name=" + fJndiName + ", unitName=" + fUnitName + ")" ; } } ; } | This transient PersistencUnit annotation class has no default value . i . e . null is a valid value for some fields . |
24,091 | public void processConfig ( Dictionary < ? , ? > props ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Session manager configuration updated" ) ; } this . myConfig . updated ( props ) ; String value = ( String ) props . get ( "purge.interval" ) ; if ( null != value ) { try { this . purgeInterval = Long . parseLong ( value . trim ( ) ) ; } catch ( NumberFormatException nfe ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Ignoring incorrect purge interval [" + value + "]" , nfe . getMessage ( ) ) ; } } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Config: purge interval [" + this . purgeInterval + "]" ) ; } } | Method called when the properties for the session manager have been found or udpated . |
24,092 | private void startPurgeTimer ( ) { if ( null != this . future || null == this . scheduler ) { return ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Creating repeating purge event" ) ; } this . future = this . scheduler . schedule ( SessionEventHandler . PURGE_EVENT , this . purgeInterval , this . purgeInterval , TimeUnit . SECONDS ) ; } | Once sessions are actively being used this is used to start the background invalidation timer that periodically scans for expired sessions that should be purged from storage . |
24,093 | protected void startPurge ( ) { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; if ( bTrace && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Running purge of expired sessions" ) ; } try { List < SessionImpl > toPurge = new ArrayList < SessionImpl > ( ) ; for ( Map < String , SessionImpl > sessions : this . groupings . values ( ) ) { synchronized ( sessions ) { for ( SessionImpl session : sessions . values ( ) ) { if ( session . checkExpiration ( false ) ) { toPurge . add ( session ) ; } } for ( SessionImpl session : toPurge ) { sessions . remove ( session . getId ( ) ) ; } } for ( SessionImpl session : toPurge ) { if ( bTrace && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Purging session; " + session ) ; } if ( ! session . isInvalid ( ) ) { session . invalidate ( ) ; } } toPurge . clear ( ) ; } } catch ( Throwable t ) { FFDCFilter . processException ( t , getClass ( ) . getName ( ) , "purge" ) ; if ( bTrace && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Error while running purge scan; " + t ) ; } } } | Method used by the recurring session purge event to scan for and discard expired sessions . This prevents memory build up when sessions are no longer queried by clients . |
24,094 | public SessionImpl getSession ( SessionInfo info , boolean create ) { ServletContext key = info . getContext ( ) ; Map < String , SessionImpl > sessions = this . groupings . get ( key ) ; if ( null == sessions ) { synchronized ( this . groupings ) { sessions = this . groupings . get ( key ) ; if ( null == sessions ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Creating session group: " + key ) ; } sessions = new HashMap < String , SessionImpl > ( ) ; this . groupings . put ( key , sessions ) ; } } } SessionImpl session = null ; String id = info . getID ( ) ; if ( null != id ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "getSession: existing id=" + id ) ; } session = sessions . get ( id ) ; if ( null != session ) { if ( session . checkExpiration ( true ) ) { if ( ! session . isInvalid ( ) ) { session . invalidate ( ) ; } session = null ; } } id = null ; } if ( null == session && create ) { id = this . idgen . getID ( ) ; session = new SessionImpl ( id , info . getContext ( ) ) ; synchronized ( sessions ) { sessions . put ( id , session ) ; } if ( null == this . future ) { synchronized ( this . timerLock ) { startPurgeTimer ( ) ; } } } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "getSession: " + session ) ; } return session ; } | Access and possibly create if not found a session for the given client information . |
24,095 | public List matchAll ( String uri ) { ClauseNode currentNode = root ; ArrayList < Object > returnList = new ArrayList < Object > ( ) ; int dot = uri . lastIndexOf ( "." ) ; if ( dot != - 1 ) { Object tar = extensions . get ( uri . substring ( dot + 1 ) ) ; if ( tar != null ) { returnList . add ( tar ) ; } } if ( defaultNode != null ) { returnList . add ( defaultNode . getStarTarget ( ) ) ; } boolean exact = true ; int startIdx = 1 ; int slashIdx ; boolean done = false ; while ( ! done ) { slashIdx = uri . indexOf ( '/' , startIdx ) ; String segment ; if ( slashIdx == - 1 ) { done = true ; slashIdx = uri . length ( ) ; segment = ( startIdx < slashIdx ) ? uri . substring ( startIdx , slashIdx ) : null ; } else { segment = uri . substring ( startIdx , slashIdx ) ; } if ( segment != null ) { currentNode = currentNode . traverse ( segment ) ; if ( currentNode == null ) { exact = false ; done = true ; } else if ( currentNode . getStarTarget ( ) != null ) { returnList . add ( currentNode . getStarTarget ( ) ) ; } startIdx = slashIdx + 1 ; } } if ( exact ) { Object target = currentNode . getTarget ( ) ; if ( target != null && currentNode . getStarTarget ( ) == null ) { returnList . add ( target ) ; } } return returnList ; } | Returns a list of all targets that match the specified uri in the increasing order of specificity |
24,096 | public void close ( ) throws SIConnectionLostException , SIResourceException , SIErrorException , SIConnectionDroppedException { final String methodName = "close" ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName ) ; } _delegateSession . close ( ) ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . exit ( this , TRACE , methodName ) ; } } | Closes this session . Delegates . |
24,097 | public SIDestinationAddress getDestinationAddress ( ) { final String methodName = "getDestinationAddress" ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName ) ; } final SIDestinationAddress address = _delegateSession . getDestinationAddress ( ) ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . exit ( this , TRACE , methodName , _parentConnection ) ; } return address ; } | Returns the destination address associated with this session . Delegates . |
24,098 | protected void checkValid ( ) throws SISessionUnavailableException { if ( ! _parentConnection . isValid ( ) ) { final SISessionUnavailableException exception = new SISessionUnavailableException ( NLS . getString ( "INVALID_SESSION_CWSIV0200" ) ) ; if ( TRACE . isEventEnabled ( ) ) { SibTr . exception ( this , TRACE , exception ) ; } throw exception ; } } | Checks that the parent connection has not been invalidated by the connection manager . |
24,099 | void close ( ) { final String methodName = "close" ; if ( TraceComponent . isAnyTracingEnabled ( ) && TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName ) ; } _cancelled = true ; if ( TraceComponent . isAnyTracingEnabled ( ) && TRACE . isEntryEnabled ( ) ) { SibTr . exit ( this , TRACE , methodName ) ; } } | Closes the session associated with this dispatcher and releases the message endpoint . |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.