CloudPlatform

Simple detection for well known cloud platforms. Detection can be forced using the "spring.main.cloud-platform" configuration property.

Author

Phillip Webb

Brian Clozel

Nguyen Sach

Since

1.3.0

Entries

Link copied to clipboard

No Cloud platform. Useful when false-positives are detected.

Link copied to clipboard

Cloud Foundry platform.

Link copied to clipboard

Heroku platform.

Link copied to clipboard

SAP Cloud platform.

Link copied to clipboard

Nomad platform.

Link copied to clipboard

Kubernetes platform.

Link copied to clipboard

Azure App Service platform.

Functions

Link copied to clipboard
open fun getActive(environment: Environment): CloudPlatform
Returns the active CloudPlatform or null if one is not active.
Link copied to clipboard
open fun isActive(environment: Environment): Boolean
Determines if the platform is active (i.e.
Link copied to clipboard
abstract fun isDetected(environment: Environment): Boolean
Determines if the platform is detected by looking for platform-specific environment variables.
Link copied to clipboard
open fun isEnforced(binder: Binder): Boolean
open fun isEnforced(environment: Environment): Boolean
Determines if the platform is enforced by looking at the "spring.main.cloud-platform" configuration property.
Link copied to clipboard
Returns if the platform is behind a load balancer and uses X-Forwarded-For headers.
Link copied to clipboard
open fun valueOf(name: String): CloudPlatform

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants.