com.ibm.rational.test.lt.recorder.compatibility.upgrade

Interface IMsgUpgrader



  • public interface IMsgUpgrader
    Handles the conversion of Payload Messages from recordings produced using RPT <= 8.1 to new recorder packets used in RPT 8.2, for a specific Msg {vendor,protocol,version} triplet. Implementations of this interface are registered using the extension point com.ibm.rational.test.lt.recorder.compatibility.recmodelUpgrader.exsd. An upgrader is given one Msg at a time, and has the opportunity to emit zero to many packets. It can also populate the recmodel's recording session configuration.
    • Method Detail

      • initializeUpgrade

        void initializeUpgrade(IPacketOutputStream writer,
                             RecordingSessionConfiguration configuration,
                             IRecModelUpgradeLog log)
                               throws IOException
        Initializes this upgrader. This step is invoked before any message conversion, and only performed if at least one message will be passed along to this upgrader.
        Parameters:
        writer - A recmodel writer that can be used to emit zero or more packets.
        configuration - A recording session configuration that can be augmented with recorder configurations and options as needed.
        Throws:
        IOException
      • convertMessage

        boolean convertMessage(Msg msg,
                             IPacketOutputStream writer,
                             RecordingSessionConfiguration configuration)
                               throws IOException
        Converts the provided Msg.
        Parameters:
        msg - The input Msg to convert.
        writer - A recmodel writer that can be used to emit zero or more packets that result from the conversion of the message.
        configuration - A recording session configuration that can be augmented with options that result from the conversion of the message.
        Returns:
        Whether the conversion has succeeded
        Throws:
        IOException - Any exception thrown by the writer
      • getRecordingInitialTime

        long getRecordingInitialTime()
        Returns the initial time of the recording, if this piece of information is available, expressed as milliseconds since the time 00:00:00 UTC on January 1, 1970. If it is not available, 0L should be returned.
        Returns:
        the initial time of the recording or 0L.
IBM Rational Performance Tester SDK

© Copyright IBM Corp. 2013. All rights reserved.