Class: ActionMCP::Server::SessionStoreFactory
- Inherits:
-
Object
- Object
- ActionMCP::Server::SessionStoreFactory
- Defined in:
- lib/action_mcp/server/session_store_factory.rb
Class Method Summary collapse
Class Method Details
.create(type = nil, **_options) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/action_mcp/server/session_store_factory.rb', line 6 def self.create(type = nil, **) type ||= default_type case type.to_sym when :volatile, :memory VolatileSessionStore.new when :active_record, :persistent ActiveRecordSessionStore.new when :test TestSessionStore.new else raise ArgumentError, "Unknown session store type: #{type}" end end |
.default_type ⇒ Object
21 22 23 |
# File 'lib/action_mcp/server/session_store_factory.rb', line 21 def self.default_type ActionMCP.configuration.server_session_store_type end |