Skip to content

Developer Reference

Use a Java 25 JDK and the included Gradle wrapper:

Terminal window
./gradlew clean build javadocJar

On Windows PowerShell, use ./gradlew.bat clean build javadocJar. Sources target Java 25 and compile against Paper 1.21.11.

OutputPurpose
build/libs/port-bridge-<version>.jarDeployable plugin with bundled runtime dependencies
build/libs/port-bridge-<version>-plain.jarUnshaded developer artifact
build/libs/port-bridge-<version>-javadoc.jarPackaged implementation reference
build/docs/javadoc/Generated HTML documentation

Install the deployable plugin JAR on the server. Browse the generated Javadocs for class and method contracts.


ClassResponsibility
PortBridgePluginConfiguration, tunnel initialization, command/listener registration, scheduled startup, and bStats lifecycle
PlayerJoinListenerDelayed, permission-aware joining-player notification
SettingsLoaderListener-property resolution and validated immutable BridgeSettings
MessagesValidated message catalog, immutable appearance values, and literal placeholders
TunnelServiceSerialized native-process lifecycle, route probes, retries, and state callbacks
TunnelSnapshotImmutable connection state and diagnostic values

This release exposes its implementation reference rather than a separately versioned integration API. Read the source before depending on implementation types.


SettingsLoader resolves Bukkit listener properties on the server thread. Plugin accessors are intended for enabled-plugin use on that thread.

TunnelService serializes native lifecycle and route probes on its worker. Process-output readers use virtual threads, and state callbacks marshal Bukkit interactions back to the server thread. Immutable TunnelSnapshot values can be retained across threads.

An address in a snapshot does not by itself establish a verified public route. Check the state and latency/health policy when interpreting connection results.


Message formatting substitutes literal contextual values once. User-configured templates do not parse MiniMessage or legacy color codes; appearance colors are validated separately. See messages.yml.

Preserve reload validation, permission checks, and cancellation tokens when extending lifecycle behavior. Native processes, scheduled startup, and metrics are owned by the plugin lifecycle and must stop during disable.


The build runs the unit suite. Check runtime behavior against the intended Paper versions when changing startup, commands, native process management, or thread callbacks. Follow the repository’s contribution guidelines, GPL headers, and class Javadocs.

Use the issue tracker for reproducible bugs. Include exact server and Java versions, reproduction steps, and relevant logs; follow SECURITY.md for private vulnerability reports.