Class DigitalOceanMetadataConfiguration
java.lang.Object
io.micronaut.discovery.cloud.digitalocean.DigitalOceanMetadataConfiguration
- All Implemented Interfaces:
Toggleable
@ConfigurationProperties("micronaut.application.digitalocean.metadata")
@Requires(env="digitalocean")
public class DigitalOceanMetadataConfiguration
extends Object
implements Toggleable
Default configuration for retrieving Digital Ocean metadata for
ComputePlatform.DIGITAL_OCEAN
.- Since:
- 1.1
- Author:
- Alvaro Sanchez-Mariscal
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetUrl()
boolean
void
setEnabled
(boolean enabled) Default value (true).void
Default value ("http://169.254.169.254/metadata/v1.json").
-
Field Details
-
PREFIX
- See Also:
-
DEFAULT_ENABLED
public static final boolean DEFAULT_ENABLEDThe default enable value.- See Also:
-
DEFAULT_URL
The default url value.- See Also:
-
-
Constructor Details
-
DigitalOceanMetadataConfiguration
public DigitalOceanMetadataConfiguration()
-
-
Method Details
-
isEnabled
public boolean isEnabled()- Specified by:
isEnabled
in interfaceToggleable
- Returns:
- Whether the Amazon EC2 configuration is enabled
-
setEnabled
public void setEnabled(boolean enabled) Default value (true).- Parameters:
enabled
- Enable or disable the Amazon EC2 configuration
-
getUrl
- Returns:
- The Url
-
setUrl
Default value ("http://169.254.169.254/metadata/v1.json").- Parameters:
url
- The url
-