public final class InfluxDBClientImpl extends AbstractInfluxDBClient implements InfluxDBClient
DEFAULT_DIALECT, gzipInterceptor, healthService, loggingInterceptor, options, retrofit
Constructor and Description |
---|
InfluxDBClientImpl(InfluxDBClientOptions options) |
Modifier and Type | Method and Description |
---|---|
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.
|
close, health
execute, getLogLevel, responseToError, setLogLevel
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close
public InfluxDBClientImpl(@Nonnull InfluxDBClientOptions options)
@Nonnull public QueryApi getQueryApi()
InfluxDBClient
getQueryApi
in interface InfluxDBClient
@Nonnull public WriteApi getWriteApi()
InfluxDBClient
getWriteApi
in interface InfluxDBClient
@Nonnull public WriteApi getWriteApi(@Nonnull WriteOptions writeOptions)
InfluxDBClient
getWriteApi
in interface InfluxDBClient
writeOptions
- the writes configuration@Nonnull public WriteApiBlocking getWriteApiBlocking()
InfluxDBClient
getWriteApiBlocking
in interface InfluxDBClient
@Nonnull public AuthorizationsApi getAuthorizationsApi()
InfluxDBClient
Authorization
client.getAuthorizationsApi
in interface InfluxDBClient
@Nonnull public BucketsApi getBucketsApi()
InfluxDBClient
Bucket
client.getBucketsApi
in interface InfluxDBClient
@Nonnull public OrganizationsApi getOrganizationsApi()
InfluxDBClient
Organization
client.getOrganizationsApi
in interface InfluxDBClient
@Nonnull public SourcesApi getSourcesApi()
InfluxDBClient
Source
client.getSourcesApi
in interface InfluxDBClient
@Nonnull public TasksApi getTasksApi()
InfluxDBClient
Task
client.getTasksApi
in interface InfluxDBClient
@Nonnull public UsersApi getUsersApi()
InfluxDBClient
User
client.getUsersApi
in interface InfluxDBClient
@Nonnull public ScraperTargetsApi getScraperTargetsApi()
InfluxDBClient
ScraperTargetResponse
client.getScraperTargetsApi
in interface InfluxDBClient
@Nonnull public TelegrafsApi getTelegrafsApi()
InfluxDBClient
Telegraf
client.getTelegrafsApi
in interface InfluxDBClient
@Nonnull public LabelsApi getLabelsApi()
InfluxDBClient
Label
client.getLabelsApi
in interface InfluxDBClient
@Nonnull public TemplatesApi getTemplatesApi()
InfluxDBClient
Document
client.getTemplatesApi
in interface InfluxDBClient
@Nonnull public VariablesApi getVariablesApi()
InfluxDBClient
Variable
client.getVariablesApi
in interface InfluxDBClient
@Nonnull public DashboardsApi getDashboardsApi()
InfluxDBClient
Dashboard
client.getDashboardsApi
in interface InfluxDBClient
@Nonnull public ChecksApi getChecksApi()
InfluxDBClient
Check
client.getChecksApi
in interface InfluxDBClient
@Nonnull public NotificationEndpointsApi getNotificationEndpointsApi()
InfluxDBClient
NotificationEndpoint
client.getNotificationEndpointsApi
in interface InfluxDBClient
@Nonnull public NotificationRulesApi getNotificationRulesApi()
InfluxDBClient
NotificationRules
client.getNotificationRulesApi
in interface InfluxDBClient
@Nonnull public DeleteApi getDeleteApi()
InfluxDBClient
getDeleteApi
in interface InfluxDBClient
@Nonnull public <S> S getService(@Nonnull Class<S> service)
InfluxDBClient
service
interface.
The endpoints are defined in com.influxdb.client.service
.
getService
in interface InfluxDBClient
S
- type of serviceservice
- service to instantiate@Nonnull public HealthCheck health()
InfluxDBClient
health
in interface InfluxDBClient
@Nullable public Ready ready()
InfluxDBClient
ready
in interface InfluxDBClient
@Nonnull public OnboardingResponse onBoarding(@Nonnull OnboardingRequest onboarding) throws UnprocessableEntityException
InfluxDBClient
onBoarding
in interface InfluxDBClient
onboarding
- to setup defaultsUnprocessableEntityException
- when an onboarding has already been completed@Nonnull public Boolean isOnboardingAllowed()
InfluxDBClient
isOnboardingAllowed
in interface InfluxDBClient
Boolean.FALSE
if onboarding has already been completed otherwise Boolean.FALSE
.@Nonnull public LogLevel getLogLevel()
getLogLevel
in interface InfluxDBClient
LogLevel
that is used for logging requests and responses@Nonnull public InfluxDBClient setLogLevel(@Nonnull LogLevel logLevel)
InfluxDBClient
setLogLevel
in interface InfluxDBClient
logLevel
- the log level to set.@Nonnull public InfluxDBClient enableGzip()
InfluxDBClient
Currently only the "Write" and "Query" endpoints supports the Gzip compression.
enableGzip
in interface InfluxDBClient
InfluxDBClient
instance to be able to use it in a fluent manner.@Nonnull public InfluxDBClient disableGzip()
InfluxDBClient
disableGzip
in interface InfluxDBClient
InfluxDBClient
instance to be able to use it in a fluent manner.public boolean isGzipEnabled()
InfluxDBClient
isGzipEnabled
in interface InfluxDBClient
Copyright © 2018–2020 InfluxData, Inc.. All rights reserved.