private boolean handleNewInformation ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Parsing new information: " + getVirtualConnection ( ) ) ; } final HttpInboundServiceContextImpl sc = getHTTPContext ( ) ; if ( ! isPartiallyParsed ( ) ) { // this is the first pass through on parsing this new request // PK12235, check for a full stop only if ( getChannel ( ) . isStopped ( ) ) { // channel stopped during the initial read, send error back if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Channel stopped during initial read" ) ; } sc . setHeadersParsed ( ) ; // since we haven't parsed the request version, force the // response to the minimal 1.0 version sc . getResponse ( ) . setVersion ( VersionValues . V10 ) ; sendErrorMessage ( StatusCodes . UNAVAILABLE ) ; return true ; } } boolean completed = false ; // if this is an http/2 link, don't perform additional parsing if ( this . isAlpnHttp2Link ( switchedVC ) ) { return false ; } try { completed = sc . parseMessage ( ) ; } catch ( UnsupportedMethodException meth ) { // no FFDC required sc . setHeadersParsed ( ) ; sendErrorMessage ( StatusCodes . NOT_IMPLEMENTED ) ; setPartiallyParsed ( false ) ; return true ; } catch ( UnsupportedProtocolVersionException ver ) { // no FFDC required sc . setHeadersParsed ( ) ; sendErrorMessage ( StatusCodes . UNSUPPORTED_VERSION ) ; setPartiallyParsed ( false ) ; return true ; } catch ( MessageTooLargeException mtle ) { // no FFDC required sc . setHeadersParsed ( ) ; sendErrorMessage ( StatusCodes . ENTITY_TOO_LARGE ) ; setPartiallyParsed ( false ) ; return true ; } catch ( MalformedMessageException mme ) { //no FFDC required if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "parseMessage encountered a MalformedMessageException : " + mme ) ; } handleGenericHNIError ( mme , sc ) ; return true ; } catch ( IllegalArgumentException iae ) { //no FFDC required if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "parseMessage encountered an IllegalArgumentException : " + iae ) ; } handleGenericHNIError ( iae , sc ) ; return true ; } catch ( CompressionException ce ) { //no FFDC required if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "parseMessage encountered a CompressionException : " + ce ) ; } handleGenericHNIError ( ce , sc ) ; return true ; } catch ( Throwable t ) { FFDCFilter . processException ( t , "HttpInboundLink.handleNewInformation" , "2" , this ) ; handleGenericHNIError ( t , sc ) ; return true ; } // partialParsed is the opposite of the complete flag setPartiallyParsed ( ! completed ) ; if ( isPartiallyParsed ( ) ) { sc . setupReadBuffers ( sc . getHttpConfig ( ) . getIncomingHdrBufferSize ( ) , false ) ; } return false ; }
Handle parsing the incoming request message .