JSON Configuration Files Format for Different Outputs

The following section contains example JSON output for different outputs.

For DATABASE output:

{
  "td_agent_output_channelType" : "DATABASE",
  "td_agent_out_dbType" : "<MYSQL or POSTGRESQL>",
  "td_agent_out_dbHost" : "<network reachable database host>",
  "td_agent_out_dbPort" : "<port for database>",
  "td_agent_out_dbSchema" : "<name of the database>",
  "td_agent_out_dbUser" : "<db_user>",
  "td_agent_out_dbPassword" : "<db_password>"
 }

For FORWARD output:

{
  "td_agent_container_output_channelType" : "FORWARD",
  "td_agent_metric_output_channelType" : "FORWARD",
  "td_agent_output_channelType" : "FORWARD",
  "td_agent_verbose_output_channelType" : "FORWARD", 
  "td_agent_out_forward_servers" : "fluentHost1:PORT,fluentHost2:PORT",
  "td_agent_out_metric_forward_servers" : "fluentHost1:PORT, fluentHost2:PORT",
  "td_agent_out_container_forward_servers" : "fluentHost1:PORT, fluentHost2:PORT",
  "td_agent_out_verbose_forward_servers" : "fluentHost1:PORT, fluentHost2:PORT"

}
Note: Every type of log can be sent to the same FORWARD service.

For ELASTICSEARCH output:

{
    "td_agent_output_channelType": "DEFAULT,ELASTICSEARCH",
    "td_agent_container_output_channelType": "DEFAULT,ELASTICSEARCH",
    "td_agent_metric_output_channelType": "DEFAULT,ELASTICSEARCH",
    "td_agent_verbose_output_channelType" : "DEFAULT,ELASTICSEARCH,
    "td_agent_out_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_elasticsearch_port" : "9200",
    "td_agent_out_elasticsearch_index" : "ml52_access",
    "td_agent_out_container_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_container_elasticsearch_port" : "9200",
    "td_agent_out_container_elasticsearch_index" : "tml52_container",
    "td_agent_out_metric_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_metric_elasticsearch_port" : "9200",
    "td_agent_out_metric_elasticsearch_index" : "ml52_metric",
    "td_agent_out_verbose_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_verbose_elasticsearch_port" : "9200",
    "td_agent_out_verbose_elasticsearch_index" : "ml52_verbose"  
}

For KAFKA output:

{
    "td_agent_output_channelType": "DEFAULT,KAFKA",
    "td_agent_container_output_channelType": "DEFAULT,KAFKA",
    "td_agent_metric_output_channelType": "DEFAULT,KAFKA",
    "td_agent_verbose_output_channelType": "DEFAULT,KAFKA",
    "td_agent_out_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_kafka_topic" : "tml52_access_logs",
    "td_agent_out_metric_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_metric_kafka_topic" : "tml52_metric_logs",
    "td_agent_out_container_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_container_kafka_topic" : "tml52_container_logs",
    "td_agent_out_verbose_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_verbose_kafka_topic" : "tml52_verbose_logs"    
}

For HTTP output:

{
    "td_agent_output_channelType": "DEFAULT,HTTP",
    "td_agent_container_output_channelType": "DEFAULT,HTTP",
    "td_agent_metric_output_channelType": "DEFAULT,HTTP",
    "td_agent_verbose_output_channelType": "DEFAULT,HTTP",
    "td_agent_out_http_URI":"<HTTP URI>",
    "td_agent_out_metric_http_URI":"<HTTP URI>",
    "td_agent_out_container_http_URI":"<HTTP URI>",
    "td_agent_out_verbose_http_URI":"<HTTP URI>"   
}

For TCP output:

{
    "td_agent_output_channelType": "DEFAULT,TCP",
    "td_agent_container_output_channelType": "DEFAULT,TCP",
    "td_agent_metric_output_channelType": "DEFAULT,TCP",
    "td_agent_verbose_output_channelType": "DEFAULT,TCP", 
    "td_agent_out_tcp_host":"<TCP HOST>",
    "td_agent_out_tcp_port":"6000",
    "td_agent_out_metric_tcp_host":"<TCP HOST>",
    "td_agent_out_metric_tcp_port":"6000",
    "td_agent_out_container_tcp_host":"<TCP HOST>",
    "td_agent_out_container_tcp_port":"6000",
    "td_agent_out_verbose_tcp_host":"<TCP HOST>",
    "td_agent_out_verbose_tcp_port":"6000" 
}

For SYSLOG output:

{
    "td_agent_output_channelType": "DEFAULT,SYSLOG",
    "td_agent_container_output_channelType": "DEFAULT,SYSLOG",
    "td_agent_metric_output_channelType": "DEFAULT,SYSLOG",
    "td_agent_verbose_output_channelType": "DEFAULT,SYSLOG",
    "td_agent_out_syslog_host":"<SYSLOG HOST>",
    "td_agent_out_syslog_port":"5142",
    "td_agent_out_syslog_tag":"ml5_accesslogs",
    "td_agent_out_syslog_protocol":"tcp",
    "td_agent_out_metric_syslog_host":"<SYSLOG HOST>",
    "td_agent_out_metric_syslog_port":"5142",
    "td_agent_out_metric_syslog_tag":"ml5_metriclogs",
    "td_agent_out_metric_syslog_protocol":"tcp",
    "td_agent_out_container_syslog_host":"<SYSLOG Host>",
    "td_agent_out_container_syslog_port":"5142",
    "td_agent_out_container_syslog_tag":"ml5_containerlogs",
    "td_agent_out_container_syslog_protocol":"tcp",
    "td_agent_out_verbose_syslog_host":"<SYSLOG Host>",
    "td_agent_out_verbose_syslog_port":"5142",
    "td_agent_out_verbose_syslog_tag":"ml5_verboselogs",
    "td_agent_out_verbose_syslog_protocol":"tcp"
}

JSON file with multiple output:

{
    "td_agent_output_channelType": "DEFAULT,ELASTICSEARCH,KAFKA",
    "td_agent_container_output_channelType": "DEFAULT,ELASTICSEARCH,KAFKA",
    "td_agent_metric_output_channelType": "DEFAULT,ELASTICSEARCH,KAFKA",
    "td_agent_verbose_output_channelType": "DEFAULT,ELASTICSEARCH,KAFKA",
    "td_agent_out_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_elasticsearch_port" : "9200",
    "td_agent_out_elasticsearch_index" : "ml52_access",
    "td_agent_out_container_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_container_elasticsearch_port" : "9200",
    "td_agent_out_container_elasticsearch_index" : "tml52_container",
    "td_agent_out_metric_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_metric_elasticsearch_port" : "9200",
    "td_agent_out_metric_elasticsearch_index" : "ml52_metric",
    "td_agent_out_verbose_elasticsearch_host" : "<Elasticsearch Host IP>",
    "td_agent_out_verbose_elasticsearch_port" : "9200",
    "td_agent_out_verbose_elasticsearch_index" : "ml52_verbose",
    "td_agent_out_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_kafka_topic" : "tml52_access_logs",
    "td_agent_out_container_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_container_kafka_topic" : "tml52_container_logs",
    "td_agent_out_metric_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_metric_kafka_topic" : "tml52_metric_logs",
    "td_agent_out_verbose_kafka_brokers" : "<Kafka Host IP>:9092",
    "td_agent_out_verbose_kafka_topic" : "tml52_verbose_logs"   
}