Project

General

Profile

« Previous | Next » 

Revision 7089

Added by Chris Jones over 12 years ago

Add a few more debugging statements to HazelcastService for troubleshooting hazelcast map concurrency.

View differences:

src/edu/ucsb/nceas/metacat/dataone/hazelcast/HazelcastService.java
352 352
	 */
353 353
	@Override
354 354
	public void entryAdded(EntryEvent<Identifier, SystemMetadata> event) {
355
	  
356
	  logMetacat.info("SystemMetadata entry added event on identifier " + 
357
	      event.getKey().getValue());
355 358
		// handle as update - that method will create if necessary
356 359
		entryUpdated(event);
360

  
357 361
	}
358 362

  
359 363
	/**
......
365 369
	 */
366 370
	@Override
367 371
	public void entryEvicted(EntryEvent<Identifier, SystemMetadata> event) {
372

  
373
      logMetacat.info("SystemMetadata entry evicted event on identifier " + 
374
          event.getKey().getValue());
375
      
368 376
	    // ensure identifiers are listed in the hzIdentifiers set
369 377
      if ( !identifiers.contains(event.getKey()) ) {
370 378
          identifiers.add(event.getKey());
......
381 389
	 */
382 390
	@Override
383 391
	public void entryRemoved(EntryEvent<Identifier, SystemMetadata> event) {
384
		// we typically don't remove objects in Metacat, but can remove System Metadata
392
		
393
    logMetacat.info("SystemMetadata entry removed event on identifier " + 
394
        event.getKey().getValue());
395

  
396
	  // we typically don't remove objects in Metacat, but can remove System Metadata
385 397
		IdentifierManager.getInstance().deleteSystemMetadata(event.getValue().getIdentifier().getValue());
386 398

  
387 399
    // keep the hzIdentifiers set in sync with the systemmetadata table
......
402 414
	@Override
403 415
	public void entryUpdated(EntryEvent<Identifier, SystemMetadata> event) {
404 416
	
405
			logMetacat.debug("Entry added/updated to System Metadata map: " + event.getKey().getValue());
417
			logMetacat.debug("Entry added/updated to System Metadata map: " + 
418
			    event.getKey().getValue());
406 419
			PartitionService partitionService = Hazelcast.getPartitionService();
407 420
			Partition partition = partitionService.getPartition(event.getKey());
408 421
			Member ownerMember = partition.getOwner();

Also available in: Unified diff