Sha256: 092830182d55c1e408558f050c0b513273903c2007c1d3ce33174b998b63e850
Contents?: true
Size: 837 Bytes
Versions: 4
Compression:
Stored size: 837 Bytes
Contents
module Aws::SessionStore::DynamoDB::Locking # This class gets and sets sessions # without a locking strategy. class Null < Aws::SessionStore::DynamoDB::Locking::Base # Retrieve session if it exists from the database by id. # Unpack the data once retrieved from the database. def get_session_data(env, sid) handle_error(env) do result = @config.dynamo_db_client.get_item(get_session_opts(sid)) extract_data(env, result) end end # @return [Hash] Options for getting session. def get_session_opts(sid) merge_all(table_opts(sid), attr_opts) end # @return [String] Session data. def extract_data(env, result = nil) env['rack.initial_data'] = result[:item]["data"] if result[:item] unpack_data(result[:item]["data"]) if result[:item] end end end
Version data entries
4 entries across 4 versions & 1 rubygems