Class: Fluent::Plugin::AzureEventHubsOutputBuffered
- Inherits:
-
BufferedOutput
- Object
- BufferedOutput
- Fluent::Plugin::AzureEventHubsOutputBuffered
- Defined in:
- lib/fluent/plugin/out_azureeventhubs_buffered.rb
Constant Summary collapse
- DEFAULT_BUFFER_TYPE =
"memory"
Instance Method Summary collapse
- #configure(conf) ⇒ Object
- #format(tag, time, record) ⇒ Object
- #formatted_to_msgpack_binary? ⇒ Boolean
-
#initialize ⇒ AzureEventHubsOutputBuffered
constructor
A new instance of AzureEventHubsOutputBuffered.
- #multi_workers_ready? ⇒ Boolean
- #prefer_buffered_processing ⇒ Object
- #shutdown ⇒ Object
- #start ⇒ Object
- #write(chunk) ⇒ Object
Constructor Details
#initialize ⇒ AzureEventHubsOutputBuffered
Returns a new instance of AzureEventHubsOutputBuffered.
29 30 31 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 29 def initialize super end |
Instance Method Details
#configure(conf) ⇒ Object
45 46 47 48 49 50 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 45 def configure(conf) compat_parameters_convert(conf, :buffer, :inject) super require_relative 'azureeventhubs/http' @sender = AzureEventHubsHttpSender.new(@connection_string, @hub_name, @expiry_interval,@proxy_addr,@proxy_port,@open_timeout,@read_timeout) end |
#format(tag, time, record) ⇒ Object
52 53 54 55 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 52 def format(tag, time, record) record = inject_values_to_record(tag, time, record) [tag, time, record].to_msgpack end |
#formatted_to_msgpack_binary? ⇒ Boolean
57 58 59 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 57 def formatted_to_msgpack_binary? true end |
#multi_workers_ready? ⇒ Boolean
61 62 63 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 61 def multi_workers_ready? true end |
#prefer_buffered_processing ⇒ Object
41 42 43 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 41 def prefer_buffered_processing true end |
#shutdown ⇒ Object
37 38 39 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 37 def shutdown super end |
#start ⇒ Object
33 34 35 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 33 def start super end |
#write(chunk) ⇒ Object
65 66 67 68 69 70 71 |
# File 'lib/fluent/plugin/out_azureeventhubs_buffered.rb', line 65 def write(chunk) chunk.msgpack_each { |tag, time, record| records = [] records.push(record) @sender.send_w_properties(records, ) } end |