Module jdk.attach

Class AttachProvider

java.lang.Object
com.sun.tools.attach.spi.AttachProvider

public abstract class AttachProvider extends Object
Attach provider class for attaching to a Java virtual machine.

An attach provider is a concrete subclass of this class that has a zero-argument constructor and implements the abstract methods specified below.

An attach provider implementation is typically tied to a Java virtual machine implementation, version, or even mode of operation. That is, a specific provider implementation will typically only be capable of attaching to a specific Java virtual machine implementation or version. For example, Oracle's JDK implementation ships with provider implementations that can only attach to Oracle's HotSpot virtual machine. In general, if an environment consists of Java virtual machines of different versions and from different vendors then there will be an attach provider implementation for each family of implementations or versions.

An attach provider is identified by its name and type. The name is typically, but not required to be, a name that corresponds to the VM vendor. The Oracle JDK implementation, for example, ships with attach providers that use the package name "sun" (for historical reasons). The type typically corresponds to the attach mechanism. For example, an implementation that uses the Doors inter-process communication mechanism might use the type "doors". The purpose of the name and type is to identify providers in environments where there are multiple providers installed.

AttachProvider implementations are loaded and instantiated at the first invocation of the providers method. This method attempts to load all provider implementations that are installed on the platform.

All of the methods in this class are safe for use by multiple concurrent threads.

Since:
1.6