Parameters
See plugin common configurations for configuration options available to all plugins.
There are no parameters for this plugin to be configured on routes or services.
Plugin Metadata
tcp
object
TCP server configurations.
host
string
required
IP address or the hostname of the TCP server.
port
integer
required
vaild vaule:
greater than or equal to 0
Target upstream port.
tls
boolean
If true, perform SSL verification.
tls_server_name
string
default:
Server name for the new TLS extension SNI.
skywalking
object
Skywalking server configurations.
endpoint_addr
string
default:
http://127.0.0.1:12900/v3/logs
Address of the SkyWalking server.
service_name
string
default:
APISIX
Service name for the SkyWalking reporter.
service_instance_name
string
default:
APISIX Instance Name
Service instance name for the SkyWalking reporter. Set to
$hostname
to get the local hostname.
clickhouse
object
ClickHouse server configurations.
endpoint_addr
string
default:
http://127.0.0.1:8213
ClickHouse endpoint.
user
string
default:
default
ClickHouse username.
password
string
ClickHouse password.
The password is encrypted with AES before saving to etcd.
database
string
Name of the database to store the logs.
logtable
string
Table name to store the logs. The table should have a
data
column where the plugin will push logs to.
kafka
object
Kafka server configurations.
brokers
array
required
vaild vaule:
greater than 0
List of Kafka broker nodes.
host
string
required
The host of Kafka broker.
port
string
required
The port of Kafka broker.
sasl_config
string
The SASL configuration of Kafka broker
mechanism
string
default:
PLAIN
vaild vaule:
PLAIN
The mechanism of SASL configuration.
user
string
required
The user of SASL configuration.
password
string
required
The password of SASL configuration.
kafka_topic
string
required
Target topic to push the logs for organization.
producer_type
string
default:
async
vaild vaule:
async
orsync
Target topic to push the logs for organization.
required_acks
integer
vaild vaule:
-1 or 1
Number of acknowledgements the leader needs to receive for the producer to consider the request complete. This controls the durability of the sent records. See Kafka documentation for more information.
acks=0
is not yet supported.key
string
Key used for allocating partitions for messages.
cluster_name
integer
default:
1
vaild vaule:
greater than or equal to 0
Name of the cluster. Used when there are two or more Kafka clusters. Only works if
producer_type
is set toasync
.meta_refresh_interval
integer
default:
30
vaild vaule:
greater than or equal to 1
Time interval to auto refresh the metadata. Same as the
refresh_interval
parameter in lua-resty-kafka, but in seconds.
timeout
integer
default:
3
vaild vaule:
greater than 0
Time to keep the connection alive after sending a request.
keepalive
integer
default:
30
vaild vaule:
greater than or equal to 1
Time to keep the connection alive after sending data, in seconds.
level
string
default:
WARN
vaild vaule:
STDERR
,EMERG
,ALERT
,CRIT
,ERR
,ERROR
,WARN
,NOTICE
,INFO
, orDEBUG
Severity level to filter the error logs. Note that
ERR
is the same asERROR
.name
string
default:
error-log-logger
Unique identifier of the plugin for the batch processor. If you use Prometheus to monitor APISIX metrics, the name is exported in
apisix_batch_process_entries
.batch_max_size
integer
default:
1000
vaild vaule:
greater than 0
The number of log entries allowed in one batch. Once reached, the batch will be sent to Datadog agent. Setting this parameter to 1 means immediate processing.
inactive_timeout
integer
default:
5
vaild vaule:
greater than 0
The maximum time in seconds to wait for new logs before sending the batch to the logging service. The value should be smaller than
buffer_duration
.buffer_duration
integer
default:
60
vaild vaule:
greater than 0
The maximum time in seconds from the earliest entry allowed before sending the batch to the logging service.
retry_delay
integer
default:
1
vaild vaule:
greater or equal to 0
The time interval in seconds to retry sending the batch to the logging service if the batch was not successfully sent.
max_retry_count
integer
default:
60
vaild vaule:
greater or equal to 0
The maximum number of unsuccessful retries allowed before dropping the log entries.