Interface AgentBuilder.RedefinitionStrategy.Listener

    • Method Detail

      • onBatch

        void onBatch​(int index,
                     List<Class<?>> batch,
                     List<Class<?>> types)
        Invoked before applying a batch.
        Parameters:
        index - A running index of the batch starting at 0.
        batch - The types included in this batch.
        types - All types included in the redefinition.
      • onError

        Iterable<? extends List<Class<?>>> onError​(int index,
                                                   List<Class<?>> batch,
                                                   Throwable throwable,
                                                   List<Class<?>> types)
        Invoked upon an error during a batch. This method is not invoked if the failure handler handled this error.
        Parameters:
        index - A running index of the batch starting at 0.
        batch - The types included in this batch.
        throwable - The throwable that caused this invocation.
        types - All types included in the redefinition.
        Returns:
        A set of classes which should be attempted to be redefined. Typically, this should be a subset of the classes contained in batch but not all classes.
      • onComplete

        void onComplete​(int amount,
                        List<Class<?>> types,
                        Map<List<Class<?>>,​Throwable> failures)
        Invoked upon completion of all batches.
        Parameters:
        amount - The total amount of batches that were executed.
        types - All types included in the redefinition.
        failures - A mapping of batch types to their unhandled failures.