Package org.cloudburstmc.netty.signaling
Class ProviderClient
java.lang.Object
org.cloudburstmc.netty.signaling.ProviderClient
- All Implemented Interfaces:
AutoCloseable
One asynchronous, serialized control lifecycle per backend, never one poller per player.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordCapacity and playerCount describe the same observation.static final recordSampled actual players on this runtime; keep counting existing players while draining.static final class -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionProviderClient(ProviderClient.Configuration config, ProviderStateStore store, ProviderTransport transport, Supplier<ServerStatus> statusSupplier, Supplier<ProviderClient.Health> healthSupplier, Consumer<String> diagnostics) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()drain()CompletableFuture<com.google.gson.JsonObject>extensionRequest(String namespace, String operation, String method, com.google.gson.JsonObject body) Explicit application request to an advertised extension operation, never automatic execution.CompletableFuture<com.google.gson.JsonObject>Opaque registration metadata; the application decides what it means.CompletableFuture<com.google.gson.JsonObject>Refresh through the ordinary heartbeat and return its readiness observation.voidWake local observation on join/leave/reload; unchanged snapshots never create network traffic.CompletableFuture<com.google.gson.JsonObject>CompletableFuture<com.google.gson.JsonObject>voidsetServerStatus(ServerStatus status) A complete immutable listing snapshot, independent of actual player telemetry.CompletableFuture<com.google.gson.JsonObject>start()stop()updateHeartbeatExtensions(com.google.gson.JsonObject extensions) Replace optional application observations and promptly send them when running.
-
Field Details
-
AUTOMATIC
- See Also:
-
NEW_SERVICE
- See Also:
-
ATTACH_INSTANCE
- See Also:
-
ANONYMOUS_PROOF_OF_WORK
- See Also:
-
BEARER_TOKEN
- See Also:
-
-
Constructor Details
-
ProviderClient
public ProviderClient(ProviderClient.Configuration config, ProviderStateStore store, ProviderTransport transport, Supplier<ServerStatus> statusSupplier, Supplier<ProviderClient.Health> healthSupplier, Consumer<String> diagnostics)
-
-
Method Details
-
start
-
setServerStatus
A complete immutable listing snapshot, independent of actual player telemetry. -
requestStatusRefresh
public void requestStatusRefresh()Wake local observation on join/leave/reload; unchanged snapshots never create network traffic. -
readiness
Refresh through the ordinary heartbeat and return its readiness observation. -
updateHeartbeatExtensions
Replace optional application observations and promptly send them when running. An omitted extension is not an application-level instruction to clear an earlier observation. -
extensions
Opaque registration metadata; the application decides what it means. -
extensionRequest
public CompletableFuture<com.google.gson.JsonObject> extensionRequest(String namespace, String operation, String method, com.google.gson.JsonObject body) Explicit application request to an advertised extension operation, never automatic execution. -
deregister
-
rotateTicketKey
-
rotateMachineKey
-
drain
-
stop
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-