Revision 7207
Added by ben leinfelder over 12 years ago
src/edu/ucsb/nceas/metacat/dataone/hazelcast/HazelcastService.java | ||
---|---|---|
238 | 238 |
logMetacat.debug("Temporarily shutting down which resynching system metadata"); |
239 | 239 |
|
240 | 240 |
// pause to make us not own any keys |
241 |
hzInstance.getLifecycleService().shutdown();
|
|
241 |
hzInstance.getLifecycleService().pause();
|
|
242 | 242 |
// synch on restart |
243 | 243 |
resynchInThread(); |
244 | 244 |
} catch (Exception e) { |
... | ... | |
517 | 517 |
logMetacat.debug("shared pid already exisits locally: " + pid.getValue()); |
518 | 518 |
} |
519 | 519 |
} |
520 |
// now we can take ownership of keys |
|
521 |
hzInstance.getLifecycleService().resume(); |
|
520 | 522 |
} |
521 | 523 |
|
522 | 524 |
private void resynchInThread() { |
... | ... | |
527 | 529 |
public void run() { |
528 | 530 |
try { |
529 | 531 |
resynch(); |
530 |
// now we can take ownership of keys |
|
531 |
hzInstance.getLifecycleService().restart(); |
|
532 | 532 |
} catch (Exception e) { |
533 | 533 |
logMetacat.error("Error in resynchInThread: " + e.getMessage(), e); |
534 | 534 |
} |
Also available in: Unified diff
due to hudson build issue, did not actually end up testing pause/resume -- trying that again