Module: QRPC
- Defined in:
- lib/qrpc/client.rb,
lib/qrpc/server.rb,
lib/qrpc/general.rb,
lib/qrpc/locator.rb,
lib/qrpc/client/job.rb,
lib/qrpc/server/job.rb,
lib/qrpc/generator/uuid.rb,
lib/qrpc/locator/em-jack.rb,
lib/qrpc/protocol/object.rb,
lib/qrpc/client/exception.rb,
lib/qrpc/client/dispatcher.rb,
lib/qrpc/protocol/abstract.rb,
lib/qrpc/protocol/json-rpc.rb,
lib/qrpc/server/dispatcher.rb,
lib/qrpc/generator/object-id.rb,
lib/qrpc/locator/evented-queue.rb,
lib/qrpc/protocol/object/error.rb,
lib/qrpc/protocol/abstract/error.rb,
lib/qrpc/protocol/json-rpc/error.rb,
lib/qrpc/protocol/object/request.rb,
lib/qrpc/protocol/abstract/object.rb,
lib/qrpc/protocol/object/response.rb,
lib/qrpc/protocol/abstract/request.rb,
lib/qrpc/protocol/json-rpc/request.rb,
lib/qrpc/protocol/abstract/response.rb,
lib/qrpc/protocol/json-rpc/response.rb,
lib/qrpc/protocol/json-rpc/native/qrpc-object.rb,
lib/qrpc/protocol/json-rpc/native/exception-data.rb
Overview
General QRPC module.
Defined Under Namespace
Modules: Generator, Locator, Protocol Classes: Client, Server
Constant Summary collapse
- QUEUE_PREFIX =
Prefix for handled queues.
"qrpc"
- QUEUE_POSTFIX_INPUT =
Input queue postfix.
"input"
- QUEUE_POSTFIX_OUTPUT =
Output queue postfix.
"output"
- DEFAULT_PRIORITY =
Indicates default job priority.
50
- DEFAULT_GENERATOR =
Holds default generator module link.
QRPC::Generator::UUID
- @@default_protocol =
Holds default protocol instance.
nil
- @@default_generator =
Holds default generator instance.
nil
Class Method Summary collapse
-
.default_generator ⇒ QRPC::Generator::UUID
Returns default generator instance.
-
.default_protocol ⇒ QRPC::Protocol::Abstract
Returns default protocol instance.
Class Method Details
.default_generator ⇒ QRPC::Generator::UUID
Returns default generator instance.
89 90 91 92 93 94 95 |
# File 'lib/qrpc/general.rb', line 89 def self.default_generator if @@default_generator.nil? @@default_generator = QRPC::DEFAULT_GENERATOR::new else @@default_generator end end |
.default_protocol ⇒ QRPC::Protocol::Abstract
Returns default protocol instance.
68 69 70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/qrpc/general.rb', line 68 def self.default_protocol if @@default_protocol.nil? begin @@default_protocol = QRPC::Protocol::JsonRpc::new(:serializer => JsonRpcObjects::Serializer::JSON::new) rescue NameError require "json-rpc-objects/serializer/json" # >= 0.4.1 require "qrpc/protocol/json-rpc" retry end else @@default_protocol end end |