idx
int64
0
165k
question
stringlengths
73
4.15k
target
stringlengths
5
918
len_question
int64
21
890
len_target
int64
3
255
158,800
@ SuppressWarnings ( "unchecked" ) public < EngineComponent > EngineComponent [ ] getEngineComponents ( Class < EngineComponent > clazz ) { String thisMethodName = "getEngineComponents" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , clazz ) ; } List ...
The purpose of this method is to get an engine component that can be cast using the specified class . The EngineComponent is not a class name but represents the classes real type . It is not possible to create an Array of a generic type without using reflection .
300
51
158,801
public final JsMEConfig getMeConfig ( ) { String thisMethodName = "getMeConfig" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , this ) ; SibTr . exit ( tc , thisMethodName , _me ) ; } return _me ; }
Returns a reference to this messaging engine s configuration .
84
10
158,802
@ Deprecated public JsEngineComponent getMessageProcessor ( String name ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "getMessageProcessor" , this ) ; SibTr . exit ( tc , "getMessageProcessor" , _messageProcessor ) ; } return _messageProcessor ; }
Gets the instance of the MP associated with this ME
86
11
158,803
private void resolveExceptionDestination ( BaseDestinationDefinition dd ) { String thisMethodName = "resolveExceptionDestination" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , dd . getName ( ) ) ; } // If variable substitution string detected, then ...
Resolve if necessary a variable Exception Destination name in the specified DD to it s runtime value .
220
19
158,804
BaseDestinationDefinition getSIBDestinationByUuid ( String bus , String key , boolean newCache ) throws SIBExceptionDestinationNotFound , SIBExceptionBase { String thisMethodName = "getSIBDestinationByUuid" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodNam...
Accessor method to return a destination definition .
259
9
158,805
public final String getState ( ) { String thisMethodName = "getState" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , this ) ; SibTr . exit ( tc , thisMethodName , states [ _state ] ) ; } return states [ _state ] ; }
Get the state of this ME
83
6
158,806
public final boolean isStarted ( ) { String thisMethodName = "isStarted" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , this ) ; } boolean retVal = ( _state == STATE_STARTED ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( )...
Returns an indication of whether this ME is started or not
123
11
158,807
final boolean addLocalizationPoint ( LWMConfig lp , DestinationDefinition dd ) { String thisMethodName = "addLocalizationPoint" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , lp ) ; } boolean success = _localizer . addLocalizationPoint ( lp , dd ) ; ...
Pass the request to add a new localization point onto the localizer object .
135
15
158,808
final void alterLocalizationPoint ( BaseDestination dest , LWMConfig lp ) { String thisMethodName = "alterLocalizationPoint" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , lp ) ; } try { _localizer . alterLocalizationPoint ( dest , lp ) ; } catch ( E...
Pass the request to alter a localization point onto the localizer object .
143
14
158,809
final void deleteLocalizationPoint ( JsBus bus , LWMConfig dest ) { String thisMethodName = "deleteLocalizationPoint" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , dest ) ; } try { _localizer . deleteLocalizationPoint ( bus , dest ) ; } catch ( SIBE...
Pass the request to delete a localization point onto the localizer object .
162
14
158,810
final void setLPConfigObjects ( List config ) { String thisMethodName = "setLPConfigObjects" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , "Number of LPs =" + config . size ( ) ) ; } _lpConfig . clear ( ) ; _lpConfig . addAll ( config ) ; if ( Trace...
Update the cache of localization point config objects . This method is used by dynamic config to refresh the cache .
130
21
158,811
public boolean isEventNotificationPropertySet ( ) { String thisMethodName = "isEventNotificationPropertySet" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , this ) ; } boolean enabled = true ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEn...
Test whether the Event Notification property has been set . This method resolves the setting for the specific ME and the setting for the bus .
116
26
158,812
public JsMainImpl getMainImpl ( ) { String thisMethodName = "getMainImpl" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , this ) ; SibTr . exit ( tc , thisMethodName , _mainImpl ) ; } return _mainImpl ; }
Returns a reference to the repository service . This is used in conjunction with ConfigRoot to access EMF configuration documents .
83
23
158,813
protected final JsEngineComponent loadClass ( String className , int stopSeq , boolean reportError ) { String thisMethodName = "loadClass" ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , thisMethodName , new Object [ ] { className , Integer . toString ( stopSeq ) , Bo...
Load the named class and add it to the list of engine components .
685
14
158,814
public void addMember ( JSConsumerKey key ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "addMember" , key ) ; super . addMember ( key ) ; // superclass method does most of the work synchronized ( criteriaLock ) { if ( allCriterias != null ...
overriding superclass method
243
6
158,815
public static void setCustomPropertyVariables ( ) { UPGRADE_READ_TIMEOUT = Integer . valueOf ( customProps . getProperty ( "upgradereadtimeout" , Integer . toString ( TCPReadRequestContext . NO_TIMEOUT ) ) ) . intValue ( ) ; UPGRADE_WRITE_TIMEOUT = Integer . valueOf ( customProps . getProperty ( "upgradewritetimeout" ,...
The timeout to use when the request has been upgraded and a write is happening
122
15
158,816
public void registerInvalidations ( String cacheName , Iterator invalidations ) { InvalidationTableList invalidationTableList = getInvalidationTableList ( cacheName ) ; if ( invalidationTableList != null ) { try { invalidationTableList . readWriteLock . writeLock ( ) . lock ( ) ; while ( invalidations . hasNext ( ) ) {...
This adds id and template invalidations .
427
8
158,817
public CacheEntry filterEntry ( String cacheName , CacheEntry cacheEntry ) { InvalidationTableList invalidationTableList = getInvalidationTableList ( cacheName ) ; try { invalidationTableList . readWriteLock . readLock ( ) . lock ( ) ; return internalFilterEntry ( cacheName , invalidationTableList , cacheEntry ) ; } fi...
This ensures the specified CacheEntrys have not been invalidated .
95
13
158,818
public ArrayList filterEntryList ( String cacheName , ArrayList incomingList ) { InvalidationTableList invalidationTableList = getInvalidationTableList ( cacheName ) ; try { invalidationTableList . readWriteLock . readLock ( ) . lock ( ) ; Iterator it = incomingList . iterator ( ) ; while ( it . hasNext ( ) ) { Object ...
This ensures all incoming CacheEntrys have not been invalidated .
221
13
158,819
private final CacheEntry internalFilterEntry ( String cacheName , InvalidationTableList invalidationTableList , CacheEntry cacheEntry ) { InvalidateByIdEvent idEvent = null ; if ( cacheEntry == null ) { if ( tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "internalFilterEntry(): Filtered cacheName=" + cacheName + " CE ==...
This is a helper method that filters a single CacheEntry . It is called by the filterEntry and filterEntryList methods .
653
25
158,820
public ExternalInvalidation filterExternalCacheFragment ( String cacheName , ExternalInvalidation externalCacheFragment ) { InvalidationTableList invalidationTableList = getInvalidationTableList ( cacheName ) ; try { invalidationTableList . readWriteLock . readLock ( ) . lock ( ) ; return internalFilterExternalCacheFra...
This ensures that the specified ExternalCacheFragment has not been invalidated .
107
15
158,821
public ArrayList filterExternalCacheFragmentList ( String cacheName , ArrayList incomingList ) { InvalidationTableList invalidationTableList = getInvalidationTableList ( cacheName ) ; try { invalidationTableList . readWriteLock . readLock ( ) . lock ( ) ; Iterator it = incomingList . iterator ( ) ; while ( it . hasNext...
This ensures all incoming ExternalCacheFragments have not been invalidated .
213
14
158,822
private final ExternalInvalidation internalFilterExternalCacheFragment ( String cacheName , InvalidationTableList invalidationTableList , ExternalInvalidation externalCacheFragment ) { if ( externalCacheFragment == null ) { return null ; } long timeStamp = externalCacheFragment . getTimeStamp ( ) ; if ( collision ( inv...
This is a helper method that filters a single ExternalCacheFragment . It is called by the filterExternalCacheFragment and filterExternalCacheFragmentList methods .
364
33
158,823
private final boolean collision ( Map < Object , InvalidationEvent > hashtable , Enumeration enumeration , long timeStamp ) { while ( enumeration . hasMoreElements ( ) ) { Object key = enumeration . nextElement ( ) ; InvalidationEvent invalidationEvent = ( InvalidationEvent ) hashtable . get ( key ) ; if ( ( invalidati...
This is a helper method that checks for a collision .
109
11
158,824
private InvalidationTableList getInvalidationTableList ( String cacheName ) { InvalidationTableList invalidationTableList = cacheinvalidationTables . get ( cacheName ) ; if ( invalidationTableList == null ) { synchronized ( this ) { invalidationTableList = new InvalidationTableList ( ) ; cacheinvalidationTables . put (...
Retrieve the InvalidationTableList by the specified cacheName .
93
13
158,825
public static File getBootstrapJar ( ) { if ( launchHome == null ) { if ( launchURL == null ) { // How were we launched? launchURL = getLocationFromClass ( KernelUtils . class ) ; } launchHome = FileUtils . getFile ( launchURL ) ; } return launchHome ; }
The location of the launch jar is only obtained once .
68
11
158,826
public static File getBootstrapLibDir ( ) { if ( libDir . get ( ) == null ) { libDir = StaticValue . mutateStaticValue ( libDir , new Utils . FileInitializer ( getBootstrapJar ( ) . getParentFile ( ) ) ) ; } return libDir . get ( ) ; }
The lib dir is the parent of the bootstrap jar
70
11
158,827
public static Properties getProperties ( final InputStream is ) throws IOException { Properties p = new Properties ( ) ; try { if ( is != null ) { p . load ( is ) ; // Look for "values" and strip the quotes to values for ( Entry < Object , Object > entry : p . entrySet ( ) ) { String s = ( ( String ) entry . getValue (...
Read properties from input stream . Will close the input stream before returning .
175
14
158,828
private static String getClassFromLine ( String line ) { line = line . trim ( ) ; // Skip commented lines if ( line . length ( ) == 0 || line . startsWith ( "#" ) ) return null ; // lop off spaces/tabs/end-of-line-comments String [ ] className = line . split ( "[\\s#]" ) ; if ( className . length >= 1 ) return classNam...
Read a service class from the given line . Must ignore whitespace and skip comment lines or end of line comments .
99
23
158,829
public final void checkSpillLimits ( ) { long currentTotal ; long currentSize ; synchronized ( this ) { currentTotal = _countTotal ; currentSize = _countTotalBytes ; } if ( ! _spilling ) { // We are not currently spilling so we need to calculate the moving average // for the number of items on our stream and then check...
Instead of just triggering spilling when we have a certain number of Items on a stream we now have the ability to trigger spilling if the total size of the Items on a stream goes over a pre - defined limit . This should allow us to control the memory usage of a stream in a more intuitive fashion .
765
60
158,830
public final void updateTotal ( int oldSizeInBytes , int newSizeInBytes ) throws SevereMessageStoreException { boolean doCallback = false ; synchronized ( this ) { // We're only replacing an old size estimation // with a new one so we do not need to change // or inspect the count total and watermark // Check whether we...
once we have the Item available to determine it from .
249
11
158,831
public static void addUnspecifiedAttributes ( FeatureDescriptor descriptor , Tag tag , String [ ] standardAttributesSorted , FaceletContext ctx ) { for ( TagAttribute attribute : tag . getAttributes ( ) . getAll ( ) ) { final String name = attribute . getLocalName ( ) ; if ( Arrays . binarySearch ( standardAttributesSo...
Adds all attributes from the given Tag which are NOT listed in standardAttributesSorted as a ValueExpression to the given BeanDescriptor . NOTE that standardAttributesSorted has to be alphabetically sorted in order to use binary search .
125
48
158,832
public static boolean containsUnspecifiedAttributes ( Tag tag , String [ ] standardAttributesSorted ) { for ( TagAttribute attribute : tag . getAttributes ( ) . getAll ( ) ) { final String name = attribute . getLocalName ( ) ; if ( Arrays . binarySearch ( standardAttributesSorted , name ) < 0 ) { return true ; } } retu...
Returns true if the given Tag contains attributes that are not specified in standardAttributesSorted . NOTE that standardAttributesSorted has to be alphabetically sorted in order to use binary search .
79
37
158,833
public static void addDevelopmentAttributes ( FeatureDescriptor descriptor , FaceletContext ctx , TagAttribute displayName , TagAttribute shortDescription , TagAttribute expert , TagAttribute hidden , TagAttribute preferred ) { if ( displayName != null ) { descriptor . setDisplayName ( displayName . getValue ( ctx ) ) ...
Applies the displayName shortDescription expert hidden and preferred attributes to the BeanDescriptor .
169
19
158,834
public static void addDevelopmentAttributesLiteral ( FeatureDescriptor descriptor , TagAttribute displayName , TagAttribute shortDescription , TagAttribute expert , TagAttribute hidden , TagAttribute preferred ) { if ( displayName != null ) { descriptor . setDisplayName ( displayName . getValue ( ) ) ; } if ( shortDesc...
Applies the displayName shortDescription expert hidden and preferred attributes to the BeanDescriptor if they are all literal values . Thus no FaceletContext is necessary .
171
33
158,835
public static boolean areAttributesLiteral ( TagAttribute ... attributes ) { for ( TagAttribute attribute : attributes ) { if ( attribute != null && ! attribute . isLiteral ( ) ) { // the attribute exists and is not literal return false ; } } // all attributes are literal return true ; }
Returns true if all specified attributes are either null or literal .
63
12
158,836
protected static FacesServletMapping calculateFacesServletMapping ( String servletPath , String pathInfo ) { if ( pathInfo != null ) { // If there is a "extra path", it's definitely no extension mapping. // Now we just have to determine the path which has been specified // in the url-pattern, but that's easy as it's th...
Determines the mapping of the FacesServlet in the web . xml configuration file . However there is no need to actually parse this configuration file as runtime information is sufficient .
351
35
158,837
private boolean isCDIEnabled ( Collection < WebSphereBeanDeploymentArchive > bdas ) { boolean anyHasBeans = false ; for ( WebSphereBeanDeploymentArchive bda : bdas ) { boolean hasBeans = false ; if ( bda . getType ( ) != ArchiveType . RUNTIME_EXTENSION ) { hasBeans = isCDIEnabled ( bda ) ; } anyHasBeans = anyHasBeans |...
Do any of the specified BDAs or any of BDAs accessible by them have any beans
124
18
158,838
private boolean isCDIEnabled ( WebSphereBeanDeploymentArchive bda ) { Boolean hasBeans = cdiStatusMap . get ( bda . getId ( ) ) ; if ( hasBeans == null ) { //it's enabled if it has beans or it is an extension which could add beans hasBeans = bda . hasBeans ( ) || bda . isExtension ( ) ; //setting this now should preven...
Does the specified BDA or any of BDAs accessible by it have any beans or it is an extension which could add beans
202
25
158,839
@ Override public boolean isCDIEnabled ( String bdaId ) { boolean hasBeans = false ; //the top level isCDIEnabled can fail faster if ( isCDIEnabled ( ) ) { Boolean hasBeansBoolean = cdiStatusMap . get ( bdaId ) ; if ( hasBeansBoolean == null ) { WebSphereBeanDeploymentArchive bda = deploymentDBAs . get ( bdaId ) ; if (...
Does the specified BDA or any of BDAs accessible by it have any beans or an extension which might add beans .
201
24
158,840
private BeanDeploymentArchive createBDAOntheFly ( Class < ? > beanClass ) throws CDIException { //Add the class in one of the bdas if an existing bda share the same classloader as the beanClass //Otherwise, we need to create a brand new bda and then add the bda to the graph //when it reaches here, it means no bda found...
Create a bda and wire it in the deployment graph
215
11
158,841
private BeanDeploymentArchive createNewBdaAndMakeWiring ( Class < ? > beanClass ) { try { OnDemandArchive onDemandArchive = new OnDemandArchive ( cdiRuntime , application , beanClass ) ; WebSphereBeanDeploymentArchive newBda = BDAFactory . createBDA ( this , onDemandArchive , cdiRuntime ) ; ClassLoader beanClassCL = on...
Create a new bda and put the beanClass to the bda and then wire this bda in the deployment according to the classloading hierarchy
447
29
158,842
private BeanDeploymentArchive findCandidateBDAtoAddThisClass ( Class < ? > beanClass ) throws CDIException { for ( WebSphereBeanDeploymentArchive wbda : getWebSphereBeanDeploymentArchives ( ) ) { if ( wbda . getClassLoader ( ) == beanClass . getClassLoader ( ) ) { wbda . addToBeanClazzes ( beanClass ) ; return wbda ; }...
Find the bda with the same classloader as the beanClass and then add the beanclasses to it
278
21
158,843
private void makeWiring ( WebSphereBeanDeploymentArchive wireFromBda , WebSphereBeanDeploymentArchive wireToBda , ClassLoader wireToBdaCL , ClassLoader wireFromBdaCL ) { while ( wireFromBdaCL != null ) { if ( wireFromBdaCL == wireToBdaCL ) { wireFromBda . addBeanDeploymentArchive ( wireToBda ) ; break ; } else { wireFr...
Make a wiring from the wireFromBda to the wireToBda if the wireFromBda s classloader is the descendant of the wireToBda s classloader
193
36
158,844
@ Override public void addBeanDeploymentArchive ( WebSphereBeanDeploymentArchive bda ) throws CDIException { deploymentDBAs . put ( bda . getId ( ) , bda ) ; extensionClassLoaders . add ( bda . getClassLoader ( ) ) ; ArchiveType type = bda . getType ( ) ; if ( type != ArchiveType . SHARED_LIB && type != ArchiveType . R...
Add a BeanDeploymentArchive to this deployment
113
10
158,845
@ Override public void addBeanDeploymentArchives ( Set < WebSphereBeanDeploymentArchive > bdas ) throws CDIException { for ( WebSphereBeanDeploymentArchive bda : bdas ) { addBeanDeploymentArchive ( bda ) ; } }
Add a Set of BDAs to the deployment
65
9
158,846
@ Override public void scan ( ) throws CDIException { Collection < WebSphereBeanDeploymentArchive > allBDAs = new ArrayList < WebSphereBeanDeploymentArchive > ( deploymentDBAs . values ( ) ) ; for ( WebSphereBeanDeploymentArchive bda : allBDAs ) { bda . scanForBeanDefiningAnnotations ( true ) ; } for ( WebSphereBeanDep...
Scan all the BDAs in the deployment to see if there are any bean classes .
128
17
158,847
@ Override public void initializeInjectionServices ( ) throws CDIException { Set < ReferenceContext > cdiReferenceContexts = new HashSet < ReferenceContext > ( ) ; //first we need to initialize the injection service and collect the reference contexts and the injection classes for ( WebSphereBeanDeploymentArchive bda : ...
Initialize the Resource Injection Service with each BDA s bean classes .
212
15
158,848
@ Override public void shutdown ( ) { if ( this . bootstrap != null ) { AccessController . doPrivileged ( new PrivilegedAction < Void > ( ) { @ Override public Void run ( ) { bootstrap . shutdown ( ) ; return null ; } } ) ; this . bootstrap = null ; this . deploymentDBAs . clear ( ) ; this . applicationBDAs . clear ( )...
Shutdown and clean up the whole deployment . The deployment will not be usable after this call has been made .
142
22
158,849
boolean isConfigValid ( ConvergedClientConfig config ) { boolean valid = true ; String clientId = config . getClientId ( ) ; String clientSecret = config . getClientSecret ( ) ; String authorizationEndpoint = config . getAuthorizationEndpointUrl ( ) ; String jwksUri = config . getJwkEndpointUrl ( ) ; if ( clientId == n...
Check for some things that will always fail and emit message about bad config . Do here so 1 ) classic oidc messages don t change and 2 ) put error message closer in log to failure .
444
40
158,850
protected void cleanOutBifurcatedMessages ( BifurcatedConsumerSessionImpl owner , boolean bumpRedeliveryOnClose ) throws SIResourceException , SISessionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "cleanOutBifurcatedMessages" , new Object [ ] { new I...
When a bifurcated consumer is closed all locked messages owned by that consumer must be unlocked
390
20
158,851
protected int getNumberOfLockedMessages ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getNumberOfLockedMessages" ) ; int count = 0 ; synchronized ( this ) { LMEMessage message ; message = firstMsg ; while ( message != null ) { count ++ ; message = message . next ...
Return the number of locked messages that are part of this locked message enumeration . The count will start from thr firstMsg unlike th getRemainingMessageCount which starts from the currentMsg .
140
38
158,852
protected void removeMessage ( LMEMessage message ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeMessage" , new Object [ ] { new Integer ( hashCode ( ) ) , message , this } ) ; // If this was the message we entered the callback with we need // to move the star...
Remove a message object from the list
518
7
158,853
protected void resetCallbackCursor ( ) throws SIResourceException , SISessionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "resetCallbackCursor" , new Integer ( hashCode ( ) ) ) ; synchronized ( this ) { unlockAllUnread ( ) ; callbackEntryMsg = lastMs...
This is called when a consumeMessages call has completed it returns the LME to a consistent state ready for the next consumeMessages .
150
28
158,854
protected void unlockAll ( boolean closingSession ) throws SIResourceException , SIMPMessageNotLockedException , SISessionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "unlockAll" , new Object [ ] { new Integer ( hashCode ( ) ) , this } ) ; int unlock...
Unlock all the messages in the list
843
8
158,855
private void unlockAllUnread ( ) throws SIResourceException , SISessionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "unlockAllUnread" , new Object [ ] { new Integer ( hashCode ( ) ) , this } ) ; int unlockedMessages = 0 ; synchronized ( this ) { mess...
Method to unlock all messages which haven t been read
474
10
158,856
public boolean containsValue ( Token value , Transaction transaction ) throws ObjectManagerException { try { for ( Iterator iterator = entrySet ( ) . iterator ( ) ; ; ) { Entry entry = ( Entry ) iterator . next ( transaction ) ; Token entryValue = entry . getValue ( ) ; if ( value == entryValue ) { return true ; } } } ...
Determines if the Map contains the Token
106
9
158,857
public long countAllMessagesOnStream ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "countAllMessagesOnStream" ) ; long count = 0 ; _targetStream . setCursor ( 0 ) ; // Get the first TickRange TickRange tr = _targetStream . getNext ( ) ; while ( tr . endstamp < Ran...
Counts the number of messages in the value state on the stream .
282
14
158,858
public final void incrementUnlockCount ( long tick ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "incrementUnlockCount" , Long . valueOf ( tick ) ) ; _targetStream . setCursor ( tick ) ; TickRange tickRange = _targetStream . getNext ( ) ; if ( tickRange . type == Ti...
sets the unlock count of the value tick s msg .
183
11
158,859
public void processRequestAck ( long tick , long dmeVersion ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "processRequestAck" , new Object [ ] { Long . valueOf ( tick ) , Long . valueOf ( dmeVersion ) } ) ; // Only consider non-stale request acks if ( dmeVersion >= ...
A ControlRequestAck message tells the RME to slow down its get repetition timeout since we now know that the DME has received the request .
378
30
158,860
public void processResetRequestAck ( long dmeVersion , SendDispatcher sendDispatcher ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "processResetRequestAck" , Long . valueOf ( dmeVersion ) ) ; // Only consider non-stale request acks if ( dmeVersion >= _latestDMEVersi...
A ControlResetRequestAck message tells the RME to start re - sending get requests with an eager timeout since the DME has crashed and recovered .
211
32
158,861
public AnycastInputHandler getAnycastInputHandler ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "getAnycastInputHandler" ) ; SibTr . exit ( tc , "getAnycastInputHandler" , _parent ) ; } return _parent ; }
Returns the AnycastInputHandler associated with this AIStream
78
11
158,862
public void messagingEngineStarting ( final JsMessagingEngine messagingEngine ) { final String methodName = "messagingEngineStarting" ; if ( TraceComponent . isAnyTracingEnabled ( ) && TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName , messagingEngine ) ; } try { addMessagingEngine ( messagingEn...
Called to indicate that a messaging engine has been started . Adds it to the set of active messaging engines .
301
22
158,863
public void messagingEngineStopping ( final JsMessagingEngine messagingEngine , final int mode ) { final String methodName = "messagingEngineStopping" ; if ( TraceComponent . isAnyTracingEnabled ( ) && TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName , new Object [ ] { messagingEngine , mode } )...
Called to indicate that a messaging engine is stopping . Removes it from the set of active messaging engines and closes any open connection .
131
27
158,864
private SQLException classNotFound ( Object interfaceNames , Set < String > packagesSearched , String dsId , Throwable cause ) { if ( cause instanceof SQLException ) return ( SQLException ) cause ; // TODO need an appropriate message when sharedLib is null and classes are loaded from the application String sharedLibId ...
Returns an exception to raise when the data source class is not found .
248
14
158,865
public ConnectionPoolDataSource createConnectionPoolDataSource ( Properties props , String dataSourceID ) throws SQLException { lock . readLock ( ) . lock ( ) ; try { if ( ! isInitialized ) try { // Switch to write lock for lazy initialization lock . readLock ( ) . unlock ( ) ; lock . writeLock ( ) . lock ( ) ; if ( ! ...
Create a ConnectionPoolDataSource
595
6
158,866
public DataSource createDataSource ( Properties props , String dataSourceID ) throws SQLException { lock . readLock ( ) . lock ( ) ; try { if ( ! isInitialized ) try { // Switch to write lock for lazy initialization lock . readLock ( ) . unlock ( ) ; lock . writeLock ( ) . lock ( ) ; if ( ! isInitialized ) { if ( ! loa...
Create a DataSource
425
4
158,867
public Object getDriver ( String url , Properties props , String dataSourceID ) throws Exception { lock . readLock ( ) . lock ( ) ; try { if ( ! isInitialized ) try { // Switch to write lock for lazy initialization lock . readLock ( ) . unlock ( ) ; lock . writeLock ( ) . lock ( ) ; if ( ! isInitialized ) { if ( ! load...
Load the Driver instance for the specified URL .
447
9
158,868
public static Collection < String > getClasspath ( Library sharedLib , boolean upperCaseFileNamesOnly ) { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getClasspath" , sharedLib ) ; Collection < String > classpath = new LinkedList < String > ...
Returns a list of file names for the specified library .
261
11
158,869
private void modified ( Dictionary < String , ? > newProperties , boolean logMessage ) { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "modified" , newProperties ) ; boolean replaced = false ; lock . writeLock ( ) . lock ( ) ; try { if ...
Clears the configuration of this JDBCDriverService so that it can lazily initialize with the new configuration on next use .
359
25
158,870
private static void setProperty ( Object obj , PropertyDescriptor pd , String value , boolean doTraceValue ) throws Exception { Object param = null ; String propName = pd . getName ( ) ; if ( tc . isDebugEnabled ( ) ) { if ( "URL" . equals ( propName ) || "url" . equals ( propName ) ) { Tr . debug ( tc , "set " + propN...
Handles the setting of any property for which a public single - parameter setter exists on the DataSource and for which the property data type is either a primitive or has a single - parameter String constructor .
561
41
158,871
protected void setSharedLib ( Library lib ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( this , tc , "setSharedLib" , lib ) ; sharedLib = lib ; }
Declarative Services method for setting the SharedLibrary service
56
11
158,872
private void shutdownDerbyEmbedded ( ) { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "shutdownDerbyEmbedded" , classloader , embDerbyRefCount ) ; // Shut down Derby embedded if the reference count drops to 0 if ( embDerbyRefCount . re...
Shut down the Derby system if the reference count for the class loader drops to 0 .
400
17
158,873
protected void unsetSharedLib ( Library lib ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( this , tc , "unsetSharedLib" , lib ) ; modified ( null , false ) ; }
Declarative Services method for unsetting the SharedLibrary service
60
12
158,874
public SIBusMessage nextLocked ( ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SIErrorException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . ...
Returns the next available locked message in the enumeration . A value of null is returned if there is no next message .
247
24
158,875
public void unlockCurrent ( ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SIIncorrectCallException , SIMessageNotLockedException , SIErrorException { if ( TraceComponent . isAnyTrac...
Unlocks the current message .
347
6
158,876
public void deleteCurrent ( SITransaction transaction ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SILimitExceededException , SIIncorrectCallException , SIMessageNotLockedException...
Deletes the current message .
547
6
158,877
public void deleteSeen ( SITransaction transaction ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SILimitExceededException , SIIncorrectCallException , SIMessageNotLockedException , ...
Deletes all messages seen so far .
559
8
158,878
private void deleteMessages ( JsMessage [ ] messagesToDelete , SITransaction transaction ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SILimitExceededException , SIIncorrectCallExce...
This private method actually performs the delete by asking the conversation helper to flow the request across the wire . However this method does not obtain any locks required to perform this operation and as such should be called by a method that does do this .
412
47
158,879
public void resetCursor ( ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException , SIResourceException , SIConnectionLostException , SIErrorException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry (...
This method will reset the cursor and allow the LME to be traversed again . Note that any messages that were deleted or unlocked will not be available again .
140
32
158,880
public int getRemainingMessageCount ( ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getRemainingMessageCount" ) ; checkValid ( ...
Returns the amount of messages left in the locked message enumeration .
147
13
158,881
private int getUnSeenMessageCount ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getUnseenMessageCount" ) ; int remain = 0 ; for ( int x = nextIndex ; x < messages . length ; x ++ ) { if ( messages [ x ] != null ) remain ++ ; } if ( TraceComponent . isAnyTr...
Private method to determine how many messages have not been seen as yet . It does this by looking at the number of non - null elements from the current item to the end of the array .
135
38
158,882
public void unlockUnseen ( ) throws SIResourceException , SIConnectionDroppedException , SIConnectionLostException , // F247845 SIIncorrectCallException , SIMessageNotLockedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "unlockUnseen" ) ; // The conver...
begin F219476 . 2
445
6
158,883
public ConsumerSession getConsumerSession ( ) throws SISessionUnavailableException , SISessionDroppedException , SIConnectionUnavailableException , SIConnectionDroppedException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getConsumerSession" ) ; // f173765.2 ...
Returns the consumer session this enumeration contains messages delivered to .
148
12
158,884
protected void markInvalid ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "markInvalid" ) ; invalid = true ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "markInvalid" ) ; }
Marks the enumeration as invalid . This is called once the asynchronous consumer callback returns to ensure that this locked message enumeration cannot be used from outside the callback .
86
33
158,885
public boolean shouldRedirectToHttps ( WebRequest webRequest ) { HttpServletRequest req = webRequest . getHttpServletRequest ( ) ; return ! req . isSecure ( ) && webRequest . isSSLRequired ( ) ; }
Determines if HTTPS redirect is required for this request .
53
12
158,886
public WebReply getHTTPSRedirectWebReply ( HttpServletRequest req ) { Integer httpsPort = ( Integer ) SRTServletRequestUtils . getPrivateAttribute ( req , "SecurityRedirectPort" ) ; if ( httpsPort == null ) { Tr . error ( tc , "SSL_PORT_IS_NULL" ) ; // return a 403 if we don't know what the port is return new DenyReply...
Get the new URL for the redirect which contains the https port .
439
13
158,887
public void receive ( int requestNumber , int tran , long timeout ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "receive" , new Object [ ] { requestNumber , tran , timeout } ) ; if ( subConsumer == null ) { subConsumer = new CATSessSynchConsumer ( this ) ; } ...
Performs a receive on this consumer . This is only a valid operation when the consumer is in synchronous mode . If the sub consumer has not been set up then this has to be created here .
155
40
158,888
public void unsetAsynchConsumerCallback ( int requestNumber , boolean stoppable ) //SIB0115d.comms { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "unsetAsynchConsumerCallback" , "requestNumber=" + requestNumber + ",stoppable=" + stoppable ) ; checkNotBrowserSess...
This method will unset the asynch consumer callback . This means that the client has requested that the session should be converted from asynchronous to synchronous and so the sub consumer must be changed
182
38
158,889
public void start ( int requestNumber , boolean deliverImmediately , boolean sendReply , SendListener sendListener ) { //471642 if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "start" , new Object [ ] { requestNumber , deliverImmediately , sendReply , sendListener ...
Start the consumer
137
3
158,890
public void setBifurcatedSession ( BifurcatedConsumerSession sess ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "setBifurcatedSession" , sess ) ; subConsumer = new CATBifurcatedConsumer ( this , sess ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . i...
This method will put the main consumer into bifurcated mode .
127
15
158,891
private void tryRunNext ( ) { while ( runningSemaphore . tryAcquire ( ) ) { ExecutionTask execution = queue . poll ( ) ; if ( execution != null ) { // Note: we've removed the execution from the queue so we're committed to running it // if we fail to do so for any reason, we need to call the exception handler to fail th...
Attempt to run any queued executions
138
7
158,892
public final boolean removeExpirable ( Expirable expirable ) throws SevereMessageStoreException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "removeExpirable" , "objId=" + ( expirable == null ? "null" : String . valueOf ( expirable . expirableGetID ( ) ) ) + " ET="...
Remove an Expirable reference for an item from the expiry index .
362
15
158,893
public final void start ( long expiryInterval , JsMessagingEngine jsme ) throws SevereMessageStoreException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "start" , "interval=" + expiryInterval + " indexSize=" + expiryIndex . size ( ) ) ; messagingEngine = jsme ...
Start the expiry daemon .
719
6
158,894
public final void stop ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "stop" ) ; synchronized ( lockObject ) { addEnabled = false ; // Prevent further expirables being added if ( runEnabled ) { runEnabled = false ; // This should terminate expiry expirerStop...
Stop the expiry daemon .
160
6
158,895
private final boolean remove ( ExpirableReference expirableRef , boolean expired ) { boolean reply = expiryIndex . remove ( ) ; if ( reply ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "Removed (" + ( expired ? "expired" : "gone" ) + ")" + " ET=" + expirableRef . ge...
Remove the expirable reference from the expiry index . This will remove the current entry pointed - to by the iterator .
191
24
158,896
private int saveStartTime ( long time ) { int indexUsed = diagIndex ; alarmTime [ diagIndex ++ ] = time ; if ( diagIndex >= MAX_DIAG_LOG ) { diagIndex = 0 ; } return indexUsed ; }
Keep last n expiry cycle start times for diagnostic dump .
56
12
158,897
private void scheduleAlarm ( long timeOut ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "scheduleAlarm timeOut=" + timeOut ) ; // NB PM27294 implementation now means you cannot decrease the the timeOut if an alarm is already scheduled. // This is OK for the e...
Schedule the next alarm . Callers of this method would typically hold lockObject already .
220
18
158,898
public void reset ( ) { expirationTimeFlag = UNSET ; inactivityFlag = UNSET ; idFlag = UNSET ; priorityFlag = UNSET ; sharingPolicyFlag = UNSET ; lock = UNSET ; id = null ; timeLimit = - 1 ; inactivity = - 1 ; expirationTime = - 1 ; validatorExpirationTime = - 1 ; priority = - 1 ; sharingPolicy = NOT_SHARED ; persistTo...
resets this EntryInfo for reuse
155
7
158,899
public void setId ( Object id ) { if ( lock == SET ) { throw new IllegalStateException ( "EntryInfo is locked" ) ; } /*if (idFlag == SET) { if (tc.isDebugEnabled()) Tr.debug(tc, "Illegal State: tried to set id to "+id+ ", but id was already set to "+this.id ); throw new IllegalStateException("id was already set"); } */...
This sets the id variable .
128
6