Skip to content

Commit

Permalink
Use new plugin log api
Browse files Browse the repository at this point in the history
Signed-off-by: sirwio <[email protected]>
  • Loading branch information
sirwio committed Nov 18, 2020
1 parent 59b6315 commit 9062cea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion plugins/out_es/es.c
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ static int cb_es_init(struct flb_output_instance *ins,

ctx = flb_calloc(1, sizeof(struct flb_elasticsearch));
if (!ctx) {
flb_errno();
flb_plg_error(ins, "cannot initialize plugin");
return -1;
}
ctx->ins = ins;
Expand Down
4 changes: 2 additions & 2 deletions plugins/out_es/es_conf.c
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ int es_config_ha(const char *upstream_file,
ctx->ha_mode = FLB_TRUE;
ctx->ha = flb_upstream_ha_from_file(upstream_file, config);
if (!ctx->ha) {
flb_error("[out_es] cannot load Upstream file");
flb_plg_error(ctx->ins, "cannot load Upstream file");
return -1;
}

Expand All @@ -296,7 +296,7 @@ int es_config_ha(const char *upstream_file,
ec = flb_calloc(1, sizeof(struct flb_elasticsearch_config));
if (!ec) {
flb_errno();
flb_error("[out_es] failed config allocation");
flb_plg_error(ctx->ins, "failed config allocation");
continue;
}

Expand Down

0 comments on commit 9062cea

Please sign in to comment.