@ThreadSafe public interface InfluxDBClient extends AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Shutdown and close the client.
|
InfluxDBClient |
disableGzip()
Disable Gzip compress for http request body.
|
InfluxDBClient |
enableGzip()
Enable Gzip compress for http requests.
|
AuthorizationsApi |
getAuthorizationsApi()
Get the
Authorization client. |
BucketsApi |
getBucketsApi()
Get the
Bucket client. |
ChecksApi |
getChecksApi()
Get the
Check client. |
DashboardsApi |
getDashboardsApi()
Get the
Dashboard client. |
DeleteApi |
getDeleteApi()
Get the Delete client.
|
LabelsApi |
getLabelsApi()
Get the
Label client. |
LogLevel |
getLogLevel() |
NotificationEndpointsApi |
getNotificationEndpointsApi()
Get the
NotificationEndpoint client. |
NotificationRulesApi |
getNotificationRulesApi()
Get the
NotificationRules client. |
OrganizationsApi |
getOrganizationsApi()
Get the
Organization client. |
QueryApi |
getQueryApi()
Get the Query client.
|
ScraperTargetsApi |
getScraperTargetsApi()
Get the
ScraperTargetResponse client. |
<S> S |
getService(Class<S> service)
Create an implementation of the API endpoints defined by the
service interface. |
SourcesApi |
getSourcesApi()
Get the
Source client. |
TasksApi |
getTasksApi()
Get the
Task client. |
TelegrafsApi |
getTelegrafsApi()
Get the
Telegraf client. |
TemplatesApi |
getTemplatesApi()
Get the
Document client. |
UsersApi |
getUsersApi()
Get the
User client. |
VariablesApi |
getVariablesApi()
Get the
Variable client. |
WriteApi |
getWriteApi()
Get the asynchronous non-blocking Write client.
|
WriteApi |
getWriteApi(WriteOptions writeOptions)
Get the asynchronous non-blocking Write client.
|
WriteApiBlocking |
getWriteApiBlocking()
Get the synchronous blocking Write client.
|
HealthCheck |
health()
Get the health of an instance.
|
boolean |
isGzipEnabled()
Returns whether Gzip compress for http request body is enabled.
|
Boolean |
isOnboardingAllowed()
Check if database has default user, org, bucket created, returns true if not.
|
OnboardingResponse |
onBoarding(OnboardingRequest onboarding)
Post onboarding request, to setup initial user, org and bucket.
|
Ready |
ready()
The readiness of the InfluxDB 2.0.
|
InfluxDBClient |
setLogLevel(LogLevel logLevel)
Set the log level for the request and response information.
|
@Nonnull QueryApi getQueryApi()
@Nonnull WriteApi getWriteApi()
@Nonnull WriteApi getWriteApi(@Nonnull WriteOptions writeOptions)
writeOptions - the writes configuration@Nonnull WriteApiBlocking getWriteApiBlocking()
@Nonnull AuthorizationsApi getAuthorizationsApi()
Authorization client.@Nonnull BucketsApi getBucketsApi()
Bucket client.@Nonnull OrganizationsApi getOrganizationsApi()
Organization client.@Nonnull SourcesApi getSourcesApi()
Source client.@Nonnull TasksApi getTasksApi()
Task client.@Nonnull UsersApi getUsersApi()
User client.@Nonnull ScraperTargetsApi getScraperTargetsApi()
ScraperTargetResponse client.@Nonnull TelegrafsApi getTelegrafsApi()
Telegraf client.@Nonnull LabelsApi getLabelsApi()
Label client.@Nonnull TemplatesApi getTemplatesApi()
Document client.@Nonnull VariablesApi getVariablesApi()
Variable client.@Nonnull DashboardsApi getDashboardsApi()
Dashboard client.@Nonnull ChecksApi getChecksApi()
Check client.@Nonnull NotificationEndpointsApi getNotificationEndpointsApi()
NotificationEndpoint client.@Nonnull NotificationRulesApi getNotificationRulesApi()
NotificationRules client.@Nonnull DeleteApi getDeleteApi()
@Nonnull <S> S getService(@Nonnull Class<S> service)
service interface.
The endpoints are defined in com.influxdb.client.service.
S - type of serviceservice - service to instantiate@Nonnull HealthCheck health()
@Nullable Ready ready()
@Nonnull OnboardingResponse onBoarding(@Nonnull OnboardingRequest onboarding) throws UnprocessableEntityException
onboarding - to setup defaultsUnprocessableEntityException - when an onboarding has already been completed@Nonnull Boolean isOnboardingAllowed()
Boolean.FALSE if onboarding has already been completed otherwise Boolean.FALSE.@Nonnull LogLevel getLogLevel()
LogLevel that is used for logging requests and responses@Nonnull InfluxDBClient setLogLevel(@Nonnull LogLevel logLevel)
logLevel - the log level to set.@Nonnull InfluxDBClient enableGzip()
Currently only the "Write" and "Query" endpoints supports the Gzip compression.
InfluxDBClient instance to be able to use it in a fluent manner.@Nonnull InfluxDBClient disableGzip()
InfluxDBClient instance to be able to use it in a fluent manner.boolean isGzipEnabled()
void close()
close in interface AutoCloseableCopyright © 2018–2021 InfluxData, Inc.. All rights reserved.