Class: Exwiw::ConnectionConfig

Inherits:
Struct
  • Object
show all
Defined in:
lib/exwiw.rb

Overview

uri is an optional full connection string (currently only honored by the mongodb adapter, e.g. mongodb+srv://...). When present it is the source of truth for the connection — host/port/user/password are ignored — so TLS, replica_set, auth_source, etc. can be expressed via the URI's query string.

mongodb_query_timeout_ms is the global, server-enforced operation timeout (CSOT timeout_ms) applied to every MongoDB query exwiw issues — the find cursor's whole lifetime, the count, and an executing explain. It guards against an accidentally heavy/unscoped query pinning the (often production) source: the server aborts the operation past the deadline. nil leaves it unset (no timeout). A per-collection query_timeout_ms overrides it. mongodb adapter only.

Instance Attribute Summary collapse

Instance Attribute Details

#adapterObject

Returns the value of attribute adapter

Returns:

  • (Object)

    the current value of adapter



67
68
69
# File 'lib/exwiw.rb', line 67

def adapter
  @adapter
end

#database_nameObject

Returns the value of attribute database_name

Returns:

  • (Object)

    the current value of database_name



67
68
69
# File 'lib/exwiw.rb', line 67

def database_name
  @database_name
end

#hostObject

Returns the value of attribute host

Returns:

  • (Object)

    the current value of host



67
68
69
# File 'lib/exwiw.rb', line 67

def host
  @host
end

#mongodb_query_timeout_msObject

Returns the value of attribute mongodb_query_timeout_ms

Returns:

  • (Object)

    the current value of mongodb_query_timeout_ms



67
68
69
# File 'lib/exwiw.rb', line 67

def mongodb_query_timeout_ms
  @mongodb_query_timeout_ms
end

#passwordObject

Returns the value of attribute password

Returns:

  • (Object)

    the current value of password



67
68
69
# File 'lib/exwiw.rb', line 67

def password
  @password
end

#portObject

Returns the value of attribute port

Returns:

  • (Object)

    the current value of port



67
68
69
# File 'lib/exwiw.rb', line 67

def port
  @port
end

#uriObject

Returns the value of attribute uri

Returns:

  • (Object)

    the current value of uri



67
68
69
# File 'lib/exwiw.rb', line 67

def uri
  @uri
end

#userObject

Returns the value of attribute user

Returns:

  • (Object)

    the current value of user



67
68
69
# File 'lib/exwiw.rb', line 67

def user
  @user
end