Add prepare support for InstrumentAgent