diff --git a/lib/fluent/plugin/output.rb b/lib/fluent/plugin/output.rb index 690033eee4..c333084b13 100644 --- a/lib/fluent/plugin/output.rb +++ b/lib/fluent/plugin/output.rb @@ -426,7 +426,9 @@ def configure(conf) end @secondary.acts_as_secondary(self) @secondary.configure(secondary_conf) - if (self.class != @secondary.class) && (@custom_format || @secondary.implement?(:custom_format)) + if (@secondary.class != SecondaryFileOutput) && + (self.class != @secondary.class) && + (@custom_format || @secondary.implement?(:custom_format)) log.warn "Use different plugin for secondary. Check the plugin works with primary like secondary_file", primary: self.class.to_s, secondary: @secondary.class.to_s end else