Package hudson.remoting
Class Capability
- java.lang.Object
-
- hudson.remoting.Capability
-
- All Implemented Interfaces:
Serializable
public final class Capability extends Object implements Serializable
Represents additional features implemented onChannel
.Each
Channel
exposes its capability toChannel.getProperty(Object)
.This mechanism allows two different versions of
remoting.jar
to talk to each other.- Author:
- Kohsuke Kawaguchi
- See Also:
Channel.remoteCapability
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
KEY
Key usable as a WebSocket HTTP header to negotiate capabilities.static Capability
NONE
-
Constructor Summary
Constructors Constructor Description Capability()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Capability
fromASCII(String ascii)
The inverse oftoASCII()
.boolean
hasMimicException()
Deprecated.no longer usedstatic Capability
read(InputStream is)
The opposite operation ofwrite(java.io.OutputStream)
.boolean
supportsChunking()
Supports chunking to designate a command boundary.boolean
supportsGreedyRemoteInputStream()
DoesRemoteInputStream
supports greedy flag.boolean
supportsMultiClassLoaderRPC()
Does this implementation supports multi-classloader serialization inUserRequest
?boolean
supportsPipeThrottling()
Does the implementation supports window size control over pipes?boolean
supportsPrefetch()
Does the implementation allow classes to be prefetched and JARs to be cached?boolean
supportsProxyExceptionFallback()
SupportsProxyException
as a fallback when failing to deserializeUserRequest
exceptions.boolean
supportsProxyWriter2_35()
DoesProxyWriter
supports proper throttling? This flag is also used to check other improvements made in ProxyWriter at the same time.String
toASCII()
Useswrite(java.io.OutputStream)
to serialize this object to a Base64-encoded ASCII stream.String
toString()
-
-
-
Field Detail
-
KEY
public static final String KEY
Key usable as a WebSocket HTTP header to negotiate capabilities.- See Also:
- Constant Field Values
-
NONE
public static final Capability NONE
-
-
Method Detail
-
supportsMultiClassLoaderRPC
public boolean supportsMultiClassLoaderRPC()
Does this implementation supports multi-classloader serialization inUserRequest
?- See Also:
MultiClassLoaderSerializer
-
supportsPipeThrottling
public boolean supportsPipeThrottling()
Does the implementation supports window size control over pipes?- See Also:
ProxyOutputStream
-
hasMimicException
@Deprecated public boolean hasMimicException()
Deprecated.no longer used
-
supportsChunking
public boolean supportsChunking()
Supports chunking to designate a command boundary.In this mode, the wire format of the data changes to:
- Include the framing (length+payload) so that a command boundary can be discovered without understanding the Java serialization wire format.
- Each command is serialized by its
ObjectOutputStream
- See Also:
ChunkHeader
-
supportsPrefetch
public boolean supportsPrefetch()
Does the implementation allow classes to be prefetched and JARs to be cached?- Since:
- 2.24
-
supportsGreedyRemoteInputStream
public boolean supportsGreedyRemoteInputStream()
DoesRemoteInputStream
supports greedy flag.- Since:
- 2.35
-
supportsProxyWriter2_35
public boolean supportsProxyWriter2_35()
DoesProxyWriter
supports proper throttling? This flag is also used to check other improvements made in ProxyWriter at the same time.- Since:
- 2.35
-
supportsProxyExceptionFallback
public boolean supportsProxyExceptionFallback()
SupportsProxyException
as a fallback when failing to deserializeUserRequest
exceptions.- Since:
- 3.19
- See Also:
- JENKINS-50237
-
read
public static Capability read(InputStream is) throws IOException
The opposite operation ofwrite(java.io.OutputStream)
.- Throws:
IOException
-
toASCII
public String toASCII() throws IOException
Useswrite(java.io.OutputStream)
to serialize this object to a Base64-encoded ASCII stream.- Throws:
IOException
-
fromASCII
public static Capability fromASCII(String ascii) throws IOException
The inverse oftoASCII()
.- Throws:
IOException
-
-