ooici/coi-services — pull request #1200 by carueda (2013-06-14 01:41:13+00:00)
Title: fix OOIION-1077

fix https://jira.oceanobservatories.org/tasks/browse/OOIION-1077:
- react to TERMINATED event to invalidate associated PID
- react to any regular status event from child to "revalidate" it (basically,
get new PID, and be able to resume interacting with that child)
- in integration test_platform_status_terminate_and_restart_instrument_1_1:
- directly use process dispatcher to terminate instrument
- to start instrument, take elements from IMS.start_instrument_agent_instance
but avoiding to deal with port_agent (which does not need to be touched
during the whole test). This part is really hacky but that's what it is.
- include list of invalidated children in diagnostics report.

TODO:
The implementation so far has shown to be consistenyl effective for the
scenarios like the one in the test above, so it should work OK for the
similar UI testing where instrument agents can be terminated/resumed.
However, there are some important refinements to do later on:
- part of the logic above also applies to child platforms, but need
to complete this part and include corresponding tests.
- The PlatformAgent is now more and more reacting to asynchronous events and
part of the needed synchronization on mutable data has been included.
But need to complete this in a more systematic way.

Please review and merge.