idx int64 0 165k | question stringlengths 73 5.81k | target stringlengths 5 918 |
|---|---|---|
159,800 | private HttpURLConnection createHeadConnection ( String path ) throws IOException { HttpURLConnection connection = createHttpURLConnectionToMassive ( path ) ; connection . setRequestMethod ( "HEAD" ) ; return connection ; } | Creates a head request connection to the specified path |
159,801 | private void deleteAsset ( String id ) throws IOException , RequestFailureException { HttpURLConnection connection = createHttpURLConnectionToMassive ( "/assets/" + id ) ; connection . setRequestMethod ( "DELETE" ) ; testResponseCode ( connection , true ) ; } | Deletes an asset with the given ID . Note this will not delete any attachments associated with the asset . |
159,802 | private void writeMultiPart ( final String assetId , final AttachmentSummary attSummary , HttpURLConnection connection ) throws IOException , BadVersionException , RequestFailureException { final File fileToWrite = attSummary . getFile ( ) ; String boundary = "---------------------------287032381131322" ; byte [ ] star... | Adds a new attachment to an asset |
159,803 | public InputStream getAttachment ( final Asset asset , final Attachment attachment ) throws IOException , BadVersionException , RequestFailureException { HttpURLConnection connection ; if ( attachment . getType ( ) == AttachmentType . CONTENT ) { connection = createHttpURLConnection ( attachment . getUrl ( ) + "?licens... | Returns the contents of an attachment |
159,804 | public Attachment getAttachmentMetaData ( String assetId , String attachmentId ) throws IOException , BadVersionException , RequestFailureException { Asset ass = getAsset ( assetId ) ; List < Attachment > allAttachments = ass . getAttachments ( ) ; for ( Attachment attachment : allAttachments ) { if ( attachmentId . eq... | Returns the meta data about an attachment |
159,805 | public void deleteAttachment ( final String assetId , final String attachmentId ) throws IOException , RequestFailureException { HttpURLConnection connection = createHttpURLConnectionToMassive ( "/assets/" + assetId + "/attachments/" + attachmentId ) ; connection . setRequestMethod ( "DELETE" ) ; testResponseCode ( con... | Delete an attachment from an asset |
159,806 | public void deleteAssetAndAttachments ( final String assetId ) throws IOException , RequestFailureException { Asset ass = getUnverifiedAsset ( assetId ) ; List < Attachment > attachments = ass . getAttachments ( ) ; if ( attachments != null ) { for ( Attachment attachment : attachments ) { deleteAttachment ( assetId , ... | This will delete an asset and all its attachments |
159,807 | public Asset getAsset ( final String assetId ) throws IOException , BadVersionException , RequestFailureException { HttpURLConnection connection = createHttpURLConnectionToMassive ( "/assets/" + assetId ) ; connection . setRequestMethod ( "GET" ) ; testResponseCode ( connection ) ; return JSONAssetConverter . readValue... | Gets a single asset |
159,808 | public void updateState ( final String assetId , final StateAction action ) throws IOException , RequestFailureException { StateUpdateAction newState = new StateUpdateAction ( action ) ; HttpURLConnection connection = createHttpURLConnectionToMassive ( "/assets/" + assetId + "/state" ) ; connection . setRequestMethod (... | This method will update the state of an object by taking the supplied action . |
159,809 | private URL createURL ( final String urlString ) throws MalformedURLException { URL url ; try { url = AccessController . doPrivileged ( new PrivilegedExceptionAction < URL > ( ) { public URL run ( ) throws MalformedURLException { return new URL ( urlString ) ; } } ) ; } catch ( PrivilegedActionException e ) { throw ( M... | Create a URL in a doPriv |
159,810 | public Attachment updateAttachment ( String assetId , AttachmentSummary summary ) throws IOException , BadVersionException , RequestFailureException { Asset ass = getAsset ( assetId ) ; List < Attachment > attachments = ass . getAttachments ( ) ; if ( attachments != null ) { for ( Attachment attachment : attachments ) ... | This method will update an existing attachment on an asset . Note that Massive currently doesn t support update attachment so this will do a delete and an add . |
159,811 | private void clearInputStream ( HttpURLConnection conn ) { InputStream is = null ; byte [ ] buffer = new byte [ 1024 ] ; try { is = conn . getInputStream ( ) ; while ( is . read ( buffer ) != - 1 ) { continue ; } } catch ( IOException e ) { } finally { if ( is != null ) { try { is . close ( ) ; } catch ( IOException e ... | Read the input stream from the connection throw it away and close the connection swallow all exceptions . |
159,812 | public static String getCharset ( final String contentType ) { String charset = "UTF-8" ; try { if ( contentType != null && ! contentType . isEmpty ( ) ) { if ( contentType . contains ( ";" ) ) { String [ ] params = contentType . substring ( contentType . indexOf ( ";" ) ) . split ( ";" ) ; for ( String param : params ... | Utility method to get the charset from a url connection s content type |
159,813 | private String parseErrorObject ( String errorObject ) { if ( errorObject == null ) { return null ; } try { InputStream inputStream = new ByteArrayInputStream ( errorObject . getBytes ( Charset . forName ( "UTF-8" ) ) ) ; JsonReader jsonReader = Json . createReader ( inputStream ) ; JsonObject parsedObject = jsonReader... | This treats the supplied string as a JSON object and looks for the message attribute inside it . If it is not valid JSON or does not contain a message the original string is returned . |
159,814 | public static void writeValue ( OutputStream stream , Object pojo ) throws IOException { DataModelSerializer . serializeAsStream ( pojo , stream ) ; } | Write a JSON representation of the asset to a stream |
159,815 | public static List < Asset > readValues ( InputStream inputStream ) throws IOException { return DataModelSerializer . deserializeList ( inputStream , Asset . class ) ; } | Read a list of assets from an input stream |
159,816 | public static Asset readValue ( InputStream inputStream ) throws IOException , BadVersionException { return DataModelSerializer . deserializeObject ( inputStream , Asset . class ) ; } | Read a single assets from an input stream |
159,817 | public static < T > T readValue ( InputStream inputStream , Class < T > type ) throws IOException , BadVersionException { return DataModelSerializer . deserializeObject ( inputStream , type ) ; } | Reads in a single object from a JSON input stream |
159,818 | public static < T > List < T > readValues ( InputStream inputStream , Class < T > type ) throws IOException { return DataModelSerializer . deserializeList ( inputStream , type ) ; } | Reads in a list of objects from a JSON input stream |
159,819 | public static String getHomeBeanClassName ( EnterpriseBean enterpriseBean , boolean isPost11DD ) { String packageName = null ; String homeInterfaceName = getHomeInterfaceName ( enterpriseBean ) ; if ( homeInterfaceName == null ) { homeInterfaceName = getLocalHomeInterfaceName ( enterpriseBean ) ; } if ( homeInterfaceNa... | Return the name of the deployed home bean class . Assumption here is the package name of the local and remote interfaces are the same . This method uses the last package name found in either the remote or local interface if one or the other exist . If neither is found null is returned . |
159,820 | public static String getConcreteBeanClassName ( EnterpriseBean enterpriseBean ) { String beanClassName = enterpriseBean . getEjbClassName ( ) ; String packageName = packageName ( beanClassName ) ; String beanName = encodeBeanInterfacesName ( enterpriseBean , true , false , false , false ) ; StringBuffer result = new St... | f110762 . 2 |
159,821 | public static final String updateFilenameHashCode ( EnterpriseBean enterpriseBean , String oldName ) { String newName = null ; int len = oldName . length ( ) ; int last_ = ( len > 9 && ( oldName . charAt ( len - 9 ) == '_' ) ) ? len - 9 : - 1 ; if ( last_ != - 1 && allHexDigits ( oldName , ++ last_ , len ) ) { String h... | Attempts to find the new file name originated from input oldName using the the new modified BuzzHash algorithm . This method detects if the oldName contains a valid trailing hashcode and try to compute the new one . If the oldName has no valid hashcode in the input name null is return . For ease of invocation regardles... |
159,822 | public String getWebServiceEndpointProxyClassName ( ) { StringBuilder result = new StringBuilder ( ) ; String packageName = packageName ( ivBeanClass ) ; if ( packageName != null ) { result . append ( packageName ) ; result . append ( '.' ) ; } result . append ( endpointPrefix ) ; result . append ( ivBeanType ) ; resul... | LI3294 - 35 d497921 |
159,823 | public void processMessage ( JsMessage jsMsg ) throws SIResourceException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "processMessage" , new Object [ ] { jsMsg } ) ; int priority = jsMsg . getPriority ( ) . intValue ( ) ; Reliability reliability = jsMsg . getReliability ( ) ; SIBUuid12 streamID = jsMsg . getG... | This method creates a Stream if this is the first inbound message which has been sent to remote Mes |
159,824 | private void activeRequestIntropectors ( PrintWriter writer ) { writer . println ( "\n------------------------------------------------------------------------------" ) ; writer . println ( " Active Requests" ) ; writer . println ( "---------------------------------------------------------------------------... | This method will dump all the active request thread id and their duration in tabular format . In addition will dump the RequestContext |
159,825 | private void transformDescriptorIntrospectors ( PrintWriter writer ) { Map < String , RequestProbeTransformDescriptor > registeredTransformDescriptors = RequestProbeBCIManagerImpl . getRequestProbeTransformDescriptors ( ) ; List < String > transformDescriptorRefs = new ArrayList < String > ( ) { { add ( "Transform Desc... | This method will dump all registered transform descriptors . It includes className methodName and description |
159,826 | public void instrumentWithProbes ( Collection < Class < ? > > classes ) { for ( Class < ? > clazz : classes ) { try { instrumentation . retransformClasses ( clazz ) ; } catch ( Throwable t ) { } } } | Instrument the provided classes with the appropriate probes . |
159,827 | public final JsMessageHandle createJsMessageHandle ( SIBUuid8 uuid , long value ) throws NullPointerException { if ( uuid == null ) { throw new NullPointerException ( "uuid" ) ; } return new JsMessageHandleImpl ( uuid , Long . valueOf ( value ) ) ; } | Create a new JsMessageHandle to represent an SIBusMessage . |
159,828 | public Principal getCallerPrincipal ( ) { EJBSecurityCollaborator < ? > securityCollaborator = container . ivSecurityCollaborator ; if ( securityCollaborator == null ) { return NullSecurityCollaborator . UNAUTHENTICATED ; } return getCallerPrincipal ( securityCollaborator , EJSContainer . getMethodContext ( ) ) ; } | Not implemented yet |
159,829 | HandleList getHandleList ( boolean create ) { if ( connectionHandleList == null && create ) { connectionHandleList = new HandleList ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "getHandleList: created " + connectionHandleList ) ; } return connectionHandleList ; } | Gets the handle list associated with this bean optionally creating one if the bean does not have a handle list yet . |
159,830 | HandleListInterface reAssociateHandleList ( ) throws CSIException { HandleListInterface hl ; if ( connectionHandleList == null ) { hl = HandleListProxy . INSTANCE ; } else { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "reAssociateHandleList: " + connectionHandleList ) ; ... | Reassociates handles in the handle list associated with this bean and returns a handle list to be pushed onto the thread handle list stack . |
159,831 | void parkHandleList ( ) { if ( connectionHandleList != null ) { final boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTraceOn && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "parkHandleList: " + connectionHandleList ) ; try { connectionHandleList . parkHandle ( ) ; } catch ( Exception ex ) { if ( i... | Parks handles in the handle list associated with this bean . |
159,832 | protected final void destroyHandleList ( ) { if ( connectionHandleList != null ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "destroyHandleList: destroying " + connectionHandleList ) ; connectionHandleList . componentDestroyed ( ) ; connectionHandleList = null ; } } | Destroy the handle list associated with this bean if necessary . |
159,833 | protected BeanOCallDispatchToken callDispatchEventListeners ( int dispatchEventCode , BeanOCallDispatchToken token ) { DispatchEventListenerManager dispatchEventListenerManager = container . ivDispatchEventListenerManager ; DispatchEventListenerCookie [ ] dispatchEventListenerCookies = null ; EJBMethodMetaData methodMe... | LIDB2775 - 23 . 1 |
159,834 | public Timer createCalendarTimer ( ScheduleExpression schedule , TimerConfig timerConfig ) { Serializable info = timerConfig == null ? null : timerConfig . getInfo ( ) ; boolean persistent = timerConfig == null || timerConfig . isPersistent ( ) ; boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTra... | F7437591 . codRev |
159,835 | public SIMessageHandle restoreFromString ( String data ) throws IllegalArgumentException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "restoreFromString" ) ; if ( ( data == null ) || data . equals ( "" ) ) { String badValueType ; if ( data == null ) { badValueType = ... | Restore a JsMessageHandle from a String . |
159,836 | protected Converter createConverter ( FaceletContext ctx ) throws FacesException , ELException , FaceletException { return ctx . getFacesContext ( ) . getApplication ( ) . createConverter ( this . getConverterId ( ctx ) ) ; } | Uses the specified converterId to pull an instance from the Application |
159,837 | public static JmsBodyType getBodyType ( String format ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getBodyType" ) ; JmsBodyType result = null ; if ( format . equals ( SIApiConstants . JMS_FORMAT_BYTES ) ) result = BYTES ; else if ( format . equals ( SIApiConstants... | Return the appropriate JMSBodyType for a specific format string |
159,838 | public final static JmsBodyType getJmsBodyType ( Byte aValue ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "Value = " + aValue ) ; return set [ aValue . intValue ( ) ] ; } | Returns the corresponding JmsBodyType for a given Byte . This method should NOT be called by any code outside the TEXT component . It is only public so that it can be accessed by sub - packages . |
159,839 | final void delistRRSXAResource ( XAResource xaResource ) throws Exception { RRSXAResourceFactory xaFactory = ( RRSXAResourceFactory ) pm . connectorSvc . rrsXAResFactorySvcRef . getService ( ) ; if ( xaFactory == null ) { throw new IllegalStateException ( "Native service for RRS transactional support is not active or a... | Delists a RRS XA resource information with the transaction manager . |
159,840 | final XAResource enlistRRSXAResource ( int recoveryId , int branchCoupling ) throws Exception { RRSXAResourceFactory xaFactory = ( RRSXAResourceFactory ) pm . connectorSvc . rrsXAResFactorySvcRef . getService ( ) ; if ( xaFactory == null ) { throw new IllegalStateException ( "Native service for RRS transactional suppor... | Enlists a RRS XA resource with the transaction manager . |
159,841 | public ConnectionManager getConnectionManager ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "Connection manager is " + cm + " for managed connection " + this ) ; if ( cm == null && pm != null ) { Tr . debug ( this , tc , "Connection pool is " + this . pm . t... | Get the reference to the Current CM instance associated with this MCWrapper . |
159,842 | protected void transactionComplete ( ) { if ( state != STATE_TRAN_WRAPPER_INUSE ) { IllegalStateException e = new IllegalStateException ( "transactionComplete: illegal state exception. State = " + getStateString ( ) + " MCW = " + mcWrapperObject_hexString ) ; Object [ ] parms = new Object [ ] { "transactionComplete" , ... | Called by the TranWrapper during afterCompletion . |
159,843 | protected boolean involvedInTransaction ( ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( state == STATE_TRAN_WRAPPER_INUSE ) { if ( isTracingEnabled && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "involvedInTransaction: true" ) ; } return true ; } else { if ( isTracingEnab... | Called by the Connection manager during reassociate to check if an unshared connection is currently involved in a transaction . |
159,844 | public boolean hasFatalErrorNotificationOccurred ( int fatalErrorNotificationTime ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( fatalErrorValue > fatalErrorNotificationTime ) { return false ; } else { if ( isTracingEnabled && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "h... | Fatal Error Notification Occurred |
159,845 | public void setDestroyConnectionOnReturn ( ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTracingEnabled && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "setDestroyConnectionOnReturn" ) ; } -- fatalErrorValue ; if ( isTracingEnabled && tc . isEntryEnabled ( ) ) { Tr . exi... | This method is used for marking a connection to destroy . The connection state does not matter . The connection still can be useable . When the connection is returned to the free pool this connection will be cleaned up and destroyed . |
159,846 | public void resetCoordinator ( ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTracingEnabled && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "Resetting uow coordinator to null" ) ; } uowCoord = null ; } | Reset the coordinator value to null |
159,847 | public void markTransactionError ( ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTracingEnabled && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "TransactionError occurred on MCWrapper:" + toString ( ) ) ; } _transactionErrorOccurred = true ; } | Indicates that an error has occurred from the transaction service . At which point we know that the MCWrapper is no longer usable and will be destroyed when the MCWrapper is returned to the pool . |
159,848 | public void clearHandleList ( ) { final boolean isTracingEnabled = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTracingEnabled && tc . isDebugEnabled ( ) ) { Tr . debug ( this , tc , "Clear the McWrapper handlelist for the following MCWrapper: " + this ) ; } mcwHandleList . clear ( ) ; } | clear the handle list |
159,849 | public boolean abortMC ( ) { boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( ! ( mc instanceof WSManagedConnection ) ) { if ( trace && tc . isDebugEnabled ( ) ) Tr . debug ( tc , "abortMC" , "Skipping MC abort because MC is not an instance of WSManagedConnection" ) ; return false ; } if ( trace && tc . ... | Abort the manage connection associated with this MCWrapper . |
159,850 | private Bucket getOrCreateBucketForKey ( Object key ) { int index = getBucketIndexForKey ( key ) ; Bucket bucket = buckets [ index ] ; if ( bucket == null ) { synchronized ( bucketLock ) { bucket = buckets [ index ] ; if ( bucket == null ) { bucket = wrappers ? new WrapperBucket ( this ) : new BucketImpl ( ) ; buckets ... | Returns the bucket which the specified key hashes to or creates it if it does not exist . |
159,851 | private String getProp ( Map < Object , Object > props , String key ) { String value = ( String ) props . get ( key ) ; if ( null == value ) { value = ( String ) props . get ( key . toLowerCase ( ) ) ; } return ( null != value ) ? value . trim ( ) : null ; } | Access the property that may or may not exist for the given key . |
159,852 | private void parsePersistence ( Map < Object , Object > props ) { parseKeepAliveEnabled ( props ) ; if ( isKeepAliveEnabled ( ) ) { parseMaxPersist ( props ) ; } } | Method to handle parsing all of the persistence related configuration values . |
159,853 | private void parseMaxPersist ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_MAX_PERSIST ) ; if ( null != value ) { try { this . maxPersistRequest = minLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_PERSIST_REQ ) ; if ( TraceComponent . isAnyTracingEnabled (... | Check the input configuration for the maximum allowed requests per socket setting . |
159,854 | private void parseOutgoingVersion ( Map < Object , Object > props ) { String value = getProp ( props , HttpConfigConstants . PROPNAME_OUTGOING_VERSION ) ; if ( "1.0" . equals ( value ) ) { this . outgoingHttpVersion = VersionValues . V10 ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr ... | Check the input configuration for the default outgoing HTTP version setting . |
159,855 | private void parseBufferType ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_DIRECT_BUFF ) ; if ( null != value ) { this . bDirectBuffers = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Config: u... | Check the input configuration for the type of ByteBuffer to use direct or indirect . |
159,856 | private void parseOutgoingBufferSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_OUTGOING_HDR_BUFFSIZE ) ; if ( null != value ) { try { this . outgoingHdrBuffSize = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_BUFFER_SIZE , HttpConfigConstants . M... | Check the input configuration for the maximum buffer size allowed for marshalling headers outbound . |
159,857 | private void parseIncomingHdrBufferSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_INCOMING_HDR_BUFFSIZE ) ; if ( null != value ) { try { this . incomingHdrBuffSize = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_BUFFER_SIZE , HttpConfigConstants ... | Check the input configuration for the buffer size to use when parsing the incoming headers . |
159,858 | private void parseIncomingBodyBufferSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_INCOMING_BODY_BUFFSIZE ) ; if ( null != value ) { try { this . incomingBodyBuffSize = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_BUFFER_SIZE , HttpConfigConstan... | Check the input configuration for the buffer size to use when reading the incoming body . |
159,859 | private void parsePersistTimeout ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_PERSIST_TIMEOUT ) ; if ( null != value ) { try { this . persistTimeout = TIMEOUT_MODIFIER * minLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_TIMEOUT ) ; if ( TraceComponent . i... | Check the input configuration for the timeout to use in between persistent requests . |
159,860 | private void parseReadTimeout ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_READ_TIMEOUT ) ; if ( null != value ) { try { this . readTimeout = TIMEOUT_MODIFIER * minLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_TIMEOUT ) ; if ( TraceComponent . isAnyTraci... | Check the input configuration for the timeout to use when doing any read during a connection . |
159,861 | private void parseWriteTimeout ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_WRITE_TIMEOUT ) ; if ( null != value ) { try { this . writeTimeout = TIMEOUT_MODIFIER * minLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_TIMEOUT ) ; if ( TraceComponent . isAnyTr... | Check the input configuration for the timeout to use when writing data during the connection . |
159,862 | private void parseByteCacheSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_BYTE_CACHE_SIZE ) ; if ( null != value ) { try { this . byteCacheSize = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_BYTE_CACHE_SIZE , HttpConfigConstants . MAX_BYTE_CACHE... | Check the input configuration for the size of the parse byte cache to use . |
159,863 | private void parseDelayedExtract ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_EXTRACT_VALUE ) ; if ( null != value ) { this . bExtractValue = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Conf... | Check the input configuration for the flag on whether to immediately extract header values during the parsing stage or not . |
159,864 | private void parseBinaryTransport ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_BINARY_TRANSPORT ) ; if ( null != value ) { this . bBinaryTransport = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc ... | Check the input configuration for whether the parsing and marshalling should use the binary transport mode or not . |
159,865 | private void parseLimitFieldSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_LIMIT_FIELDSIZE ) ; if ( null != value ) { try { this . limitFieldSize = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_LIMIT_FIELDSIZE , HttpConfigConstants . MAX_LIMIT_FI... | Check the input configuration for a maximum size allowed for HTTP fields . |
159,866 | private void parseLimitNumberHeaders ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_LIMIT_NUMHEADERS ) ; if ( null != value ) { try { this . limitNumHeaders = rangeLimit ( convertInteger ( value ) , HttpConfigConstants . MIN_LIMIT_NUMHEADERS , HttpConfigConstants . MAX_L... | Check the input configuration for a maximum limit on the number of headers allowed per message . |
159,867 | private void parseLimitNumberResponses ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_LIMIT_NUMBER_RESPONSES ) ; if ( null != value ) { try { int size = convertInteger ( value ) ; if ( HttpConfigConstants . UNLIMITED == size ) { this . limitNumResponses = HttpConfigConst... | Check the input configuration for a maximum limit on the number of temporary responses that will be read and skipped past . |
159,868 | private void parseLimitMessageSize ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_MSG_SIZE_LIMIT ) ; if ( null != value ) { try { this . limitMessageSize = convertLong ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( t... | Parse the possible configuration limit on the incoming message body . size . |
159,869 | private void parseAccessLog ( Map < Object , Object > props ) { String id = ( String ) props . get ( HttpConfigConstants . PROPNAME_ACCESSLOG_ID ) ; if ( id != null ) { AtomicReference < AccessLog > aLog = HttpEndpointImpl . getAccessLogger ( id ) ; if ( aLog != null ) { this . accessLogger = aLog ; } if ( TraceCompone... | Parse the NCSA access log information from the property map . |
159,870 | private void parseRemoteIp ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_REMOTE_IP ) ; if ( null != value ) { this . useForwardingHeaders = convertBoolean ( value ) ; if ( this . useForwardingHeaders && ( TraceComponent . isAnyTracingEnabled ( ) ) && ( tc . isEventEnabl... | Check the configuration to see if the remoteIp element has been configured to consider forwarding header values in the NCSA Access Log |
159,871 | private void parseAllowRetries ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_ALLOW_RETRIES ) ; if ( null != value ) { this . bAllowRetries = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Config... | Parse the input configuration for the flag on whether to allow retries or not . |
159,872 | private void parseHeaderValidation ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_HEADER_VALIDATION ) ; if ( null != value ) { this . bHeaderValidation = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( ... | Parse the configuration on whether to perform header validation or not . |
159,873 | private void parseJITOnlyReads ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_JIT_ONLY_READS ) ; if ( null != value ) { this . bJITOnlyReads = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Confi... | Parse the configuration on whether to perform JIT allocate only reads or leave it to the default behavior . |
159,874 | private void parseStrictURLFormat ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_STRICT_URL_FORMAT ) ; if ( null != value ) { this . bStrictURLFormat = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc... | Check the input configuration to decide whether to enforce a strict RFC compliance while parsing URLs . |
159,875 | private void parseServerHeader ( Map < Object , Object > props ) { String value = getProp ( props , HttpConfigConstants . PROPNAME_SERVER_HEADER_VALUE ) ; if ( null == value || "" . equals ( value ) ) { } else { if ( "DefaultServerVersion" . equalsIgnoreCase ( value ) ) { value = "WebSphere Application Server" ; } this... | Check the input configuration map for the parameters that control the Server header value . |
159,876 | private void parseDateHeaderRange ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_DATE_HEADER_RANGE ) ; if ( null != value ) { try { this . lDateHeaderRange = minLimit ( convertLong ( value ) , 0L ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ... | Parse the date header range value from the input properties . |
159,877 | private void parseCookieUpdate ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_NO_CACHE_COOKIES_CONTROL ) ; Object value2 = props . get ( HttpConfigConstants . PROPNAME_COOKIES_CONFIGURE_NOCACHE ) ; boolean documentedProperty = true ; boolean originalProperty = true ; if ... | Check the configuration map for the Set - Cookie updating no - cache value . |
159,878 | private void parseHeaderChangeLimit ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_HEADER_CHANGE_LIMIT ) ; if ( null != value ) { try { this . headerChangeLimit = convertInteger ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr .... | Parse the header change limit property . |
159,879 | private void parseRequestSmugglingProtection ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_ENABLE_SMUGGLING_PROTECTION ) ; if ( null != value ) { this . bEnableSmugglingProtection = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebug... | Check whether or not the request smuggling protection has been changed . |
159,880 | private void parseAutoDecompression ( Map < Object , Object > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_AUTODECOMPRESSION ) ; if ( null != value ) { this . bAutoDecompression = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ... | Check the configuration map for the property turning on or off the body autodecompression code . |
159,881 | private void parsev0CookieDateRFC1123compat ( Map < ? , ? > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_V0_COOKIE_RFC1123_COMPAT ) ; if ( null != value ) { this . v0CookieDateRFC1123compat = convertBoolean ( value ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) )... | Check the for the property v0CookieDateRFC1123compat |
159,882 | private void parseSkipCookiePathQuotes ( Map < ? , ? > props ) { String value = ( String ) props . get ( HttpConfigConstants . PROPNAME_SKIP_PATH_QUOTE ) ; if ( null != value ) { this . skipCookiePathQuotes = convertBoolean ( value ) ; if ( ( TraceComponent . isAnyTracingEnabled ( ) ) && ( tc . isEventEnabled ( ) ) ) {... | Check the configuration map for if we should skip adding the quote to the cookie path attribute |
159,883 | private void parseDoNotAllowDuplicateSetCookies ( Map < ? , ? > props ) { String value = ( String ) props . get ( HttpConfigConstants . PROPNAME_DO_NOT_ALLOW_DUPLICATE_SET_COOKIES ) ; if ( null != value ) { this . doNotAllowDuplicateSetCookies = convertBoolean ( value ) ; if ( ( TraceComponent . isAnyTracingEnabled ( )... | Check the configuration map for the property to tell us if we should prevent multiple set - cookies with the same name |
159,884 | private void parseWaitForEndOfMessage ( Map props ) { String value = ( String ) props . get ( HttpConfigConstants . PROPNAME_WAIT_FOR_END_OF_MESSAGE ) ; if ( null != value ) { this . waitForEndOfMessage = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ... | Check the configuration map for using WaitForEndOfMessage |
159,885 | private void parseRemoveCLHeaderInTempStatusRespRFC7230compat ( Map props ) { String value = ( String ) props . get ( HttpConfigConstants . REMOVE_CLHEADER_IN_TEMP_STATUS_RFC7230_COMPAT ) ; if ( null != value ) { this . removeCLHeaderInTempStatusRespRFC7230compat = convertBoolean ( value ) ; if ( TraceComponent . isAny... | Check the configuration map for to see if we should send or not content - length on 1xx and 204 responses |
159,886 | private void parsePreventResponseSplit ( Map < ? , ? > props ) { String value = ( String ) props . get ( HttpConfigConstants . PROPNAME_PREVENT_RESPONSE_SPLIT ) ; if ( null != value ) { this . preventResponseSplit = convertBoolean ( value ) ; if ( ( TraceComponent . isAnyTracingEnabled ( ) ) && ( tc . isEventEnabled ( ... | Check the configuration map for if we should prevent response splitting |
159,887 | private void parseAttemptPurgeData ( Map props ) { String value = ( String ) props . get ( HttpConfigConstants . PROPNAME_PURGE_DATA_DURING_CLOSE ) ; if ( null != value ) { this . attemptPurgeData = convertBoolean ( value ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc ,... | Check the configuration map for using purge behavior at the close of the connection |
159,888 | private void parseThrowIOEForInboundConnections ( Map < ? , ? > props ) { Object value = props . get ( HttpConfigConstants . PROPNAME_THROW_IOE_FOR_INBOUND_CONNECTIONS ) ; if ( null != value ) { this . throwIOEForInboundConnections = convertBoolean ( value ) ; if ( ( TraceComponent . isAnyTracingEnabled ( ) ) && ( tc .... | Check the configuration map for if we should swallow inbound connections IOEs |
159,889 | private void parsePurgeRemainingResponseBody ( Map < ? , ? > props ) { String purgeRemainingResponseProperty = AccessController . doPrivileged ( new java . security . PrivilegedAction < String > ( ) { public String run ( ) { return ( System . getProperty ( HttpConfigConstants . PROPNAME_PURGE_REMAINING_RESPONSE ) ) ; }... | Check the configuration if we should purge the remaining response data This is a JVM custom property as it s intended for outbound scenarios |
159,890 | private void parseProtocolVersion ( Map < ? , ? > props ) { Object protocolVersionProperty = props . get ( HttpConfigConstants . PROPNAME_PROTOCOL_VERSION ) ; if ( null != protocolVersionProperty ) { String protocolVersion = ( ( String ) protocolVersionProperty ) . toLowerCase ( ) ; if ( HttpConfigConstants . PROTOCOL_... | Check the configuration to see if there is a desired http protocol version that has been provided for this HTTP Channel |
159,891 | private boolean convertBoolean ( Object o ) { if ( o instanceof Boolean ) return ( Boolean ) o ; return "true" . equalsIgnoreCase ( o . toString ( ) . trim ( ) ) ; } | Convert a String to a boolean value . If the string does not match true then it defaults to false . |
159,892 | private int rangeLimit ( int size , int min , int max ) { if ( size < min ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Config: " + size + " too small" ) ; } return min ; } else if ( size > max ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled... | Take the user input size variable and make sure it is inside the given range of min and max . If it is outside the range then set the value to the closest limit . |
159,893 | private int minLimit ( int input , int min ) { if ( input < min ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Config: " + input + " too small." ) ; } return min ; } return input ; } | Return the larger value of either the input int or the minimum limit . |
159,894 | public boolean throwIOEForInboundConnections ( ) { if ( this . throwIOEForInboundConnections != null ) return this . throwIOEForInboundConnections ; Boolean IOEForInboundConnectionsBehavior = HttpDispatcher . useIOEForInboundConnectionsBehavior ( ) ; return ( ( IOEForInboundConnectionsBehavior != null ) ? IOEForInbound... | Query whether or not the HTTP Channel should swallow inbound connections IOE |
159,895 | public void activate ( ComponentContext cc ) { executorServiceRef . activate ( cc ) ; contextServiceRef . activate ( cc ) ; ReactiveStreamsFactoryResolver . setInstance ( new ReactiveStreamsFactoryImpl ( ) ) ; ReactiveStreamsEngineResolver . setInstance ( this ) ; singleton = this ; } | The OSGi component active call |
159,896 | public void deactivate ( ComponentContext cc ) { singleton = null ; ReactiveStreamsEngineResolver . setInstance ( null ) ; ReactiveStreamsFactoryResolver . setInstance ( null ) ; executorServiceRef . deactivate ( cc ) ; contextServiceRef . deactivate ( cc ) ; } | The OSGi component deactive call |
159,897 | public synchronized List getList ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getList" ) ; List list = ( List ) listPool . remove ( ) ; if ( list == null ) { if ( tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "No list available from pool - creating a new one" ) ; list = new ArrayList ( 5 ) ; } if ( tc . ... | Gets a list from the pool . |
159,898 | public synchronized void returnList ( List list ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "returnList" ) ; list . clear ( ) ; listPool . add ( list ) ; if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "returnList" ) ; } | Returns a list back to the pool so that it can be re - used |
159,899 | void setParent ( JMFMessageData parent ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) JmfTr . entry ( this , tc , "setParent" , new Object [ ] { parent } ) ; synchronized ( getMessageLockArtefact ( ) ) { if ( parent instanceof JSMessageData ) { parentMessage = ( JSMessageData ) parent ; ... | method is not private & we re somewhat paranoid . |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.