Class: Fluent::MessagePackRPCInput
- Inherits:
-
Input
- Object
- Input
- Fluent::MessagePackRPCInput
- Defined in:
- lib/fluent/plugin/in_msgpack_rpc.rb
Defined Under Namespace
Classes: Server
Instance Method Summary collapse
- #configure(conf) ⇒ Object
-
#initialize ⇒ MessagePackRPCInput
constructor
A new instance of MessagePackRPCInput.
- #shutdown ⇒ Object
- #start ⇒ Object
Constructor Details
#initialize ⇒ MessagePackRPCInput
Returns a new instance of MessagePackRPCInput.
23 24 25 26 |
# File 'lib/fluent/plugin/in_msgpack_rpc.rb', line 23 def initialize require 'msgpack/rpc' super end |
Instance Method Details
#configure(conf) ⇒ Object
31 32 33 34 |
# File 'lib/fluent/plugin/in_msgpack_rpc.rb', line 31 def configure(conf) # TODO: Reject invalid bind parameter super end |
#shutdown ⇒ Object
44 45 46 47 |
# File 'lib/fluent/plugin/in_msgpack_rpc.rb', line 44 def shutdown @server.close @thread.join end |
#start ⇒ Object
36 37 38 39 40 41 42 |
# File 'lib/fluent/plugin/in_msgpack_rpc.rb', line 36 def start @server = MessagePack::RPC::Server.new @server.listen @bind, @port, Server.new @thread = Thread.new { @server.run } end |