LSST Applications 27.0.0,g0265f82a02+469cd937ee,g02d81e74bb+21ad69e7e1,g1470d8bcf6+cbe83ee85a,g2079a07aa2+e67c6346a6,g212a7c68fe+04a9158687,g2305ad1205+94392ce272,g295015adf3+81dd352a9d,g2bbee38e9b+469cd937ee,g337abbeb29+469cd937ee,g3939d97d7f+72a9f7b576,g487adcacf7+71499e7cba,g50ff169b8f+5929b3527e,g52b1c1532d+a6fc98d2e7,g591dd9f2cf+df404f777f,g5a732f18d5+be83d3ecdb,g64a986408d+21ad69e7e1,g858d7b2824+21ad69e7e1,g8a8a8dda67+a6fc98d2e7,g99cad8db69+f62e5b0af5,g9ddcbc5298+d4bad12328,ga1e77700b3+9c366c4306,ga8c6da7877+71e4819109,gb0e22166c9+25ba2f69a1,gb6a65358fc+469cd937ee,gbb8dafda3b+69d3c0e320,gc07e1c2157+a98bf949bb,gc120e1dc64+615ec43309,gc28159a63d+469cd937ee,gcf0d15dbbd+72a9f7b576,gdaeeff99f8+a38ce5ea23,ge6526c86ff+3a7c1ac5f1,ge79ae78c31+469cd937ee,gee10cc3b42+a6fc98d2e7,gf1cff7945b+21ad69e7e1,gfbcc870c63+9a11dc8c8f
LSST Data Management Base Package
Loading...
Searching...
No Matches
Public Member Functions | Static Public Attributes | List of all members
lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig Class Reference
Inheritance diagram for lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig:
lsst.dax.apdb.apdb.ApdbConfig lsst.pex.config.config.Config lsst.pex.config.config.ConfigMeta

Public Member Functions

None validate (self)
 

Static Public Attributes

 db_url = Field[str](doc="SQLAlchemy database connection URI")
 
 isolation_level
 
 connection_pool
 
 connection_timeout
 
 sql_echo = Field[bool](doc="If True then pass SQLAlchemy echo option.", default=False)
 
 dia_object_index
 
 htm_level = Field[int](doc="HTM indexing level", default=20)
 
 htm_max_ranges = Field[int](doc="Max number of ranges in HTM envelope", default=64)
 
 htm_index_column
 
 ra_dec_columns = ListField[str](default=["ra", "dec"], doc="Names of ra/dec columns in DiaObject table")
 
 dia_object_columns
 
 prefix = Field[str](doc="Prefix to add to table names and index names", default="")
 
 namespace
 
 timer = Field[bool](doc="If True then print/log timing information", default=False)
 

Detailed Description

APDB configuration class for SQL implementation (ApdbSql).

Definition at line 107 of file apdbSql.py.

Member Function Documentation

◆ validate()

None lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.validate ( self)
Validate the Config, raising an exception if invalid.

Raises
------
lsst.pex.config.FieldValidationError
    Raised if verification fails.

Notes
-----
The base class implementation performs type checks on all fields by
calling their `~lsst.pex.config.Field.validate` methods.

Complex single-field validation can be defined by deriving new Field
types. For convenience, some derived `lsst.pex.config.Field`-types
(`~lsst.pex.config.ConfigField` and
`~lsst.pex.config.ConfigChoiceField`) are defined in
``lsst.pex.config`` that handle recursing into subconfigs.

Inter-field relationships should only be checked in derived
`~lsst.pex.config.Config` classes after calling this method, and base
validation is complete.

Reimplemented from lsst.pex.config.config.Config.

Definition at line 170 of file apdbSql.py.

170 def validate(self) -> None:
171 super().validate()
172 if len(self.ra_dec_columns) != 2:
173 raise ValueError("ra_dec_columns must have exactly two column names")
174
175

Member Data Documentation

◆ connection_pool

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.connection_pool
static
Initial value:
= Field[bool](
doc="If False then disable SQLAlchemy connection pool. Do not use connection pool when forking.",
default=True,
)

Definition at line 126 of file apdbSql.py.

◆ connection_timeout

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.connection_timeout
static
Initial value:
= Field[float](
doc=(
"Maximum time to wait time for database lock to be released before exiting. "
"Defaults to sqlalchemy defaults if not set."
),
default=None,
optional=True,
)

Definition at line 130 of file apdbSql.py.

◆ db_url

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.db_url = Field[str](doc="SQLAlchemy database connection URI")
static

Definition at line 110 of file apdbSql.py.

◆ dia_object_columns

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.dia_object_columns
static
Initial value:
= ListField[str](
doc="List of columns to read from DiaObject, by default read all columns", default=[]
)

Definition at line 154 of file apdbSql.py.

◆ dia_object_index

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.dia_object_index
static
Initial value:
= ChoiceField[str](
doc="Indexing mode for DiaObject table",
allowed={
"baseline": "Index defined in baseline schema",
"pix_id_iov": "(pixelId, objectId, iovStart) PK",
"last_object_table": "Separate DiaObjectLast table",
},
default="baseline",
)

Definition at line 139 of file apdbSql.py.

◆ htm_index_column

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.htm_index_column
static
Initial value:
= Field[str](
default="pixelId", doc="Name of a HTM index column for DiaObject and DiaSource tables"
)

Definition at line 150 of file apdbSql.py.

◆ htm_level

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.htm_level = Field[int](doc="HTM indexing level", default=20)
static

Definition at line 148 of file apdbSql.py.

◆ htm_max_ranges

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.htm_max_ranges = Field[int](doc="Max number of ranges in HTM envelope", default=64)
static

Definition at line 149 of file apdbSql.py.

◆ isolation_level

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.isolation_level
static
Initial value:
= ChoiceField[str](
doc=(
"Transaction isolation level, if unset then backend-default value "
"is used, except for SQLite backend where we use READ_UNCOMMITTED. "
"Some backends may not support every allowed value."
),
allowed={
"READ_COMMITTED": "Read committed",
"READ_UNCOMMITTED": "Read uncommitted",
"REPEATABLE_READ": "Repeatable read",
"SERIALIZABLE": "Serializable",
},
default=None,
optional=True,
)

Definition at line 111 of file apdbSql.py.

◆ namespace

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.namespace
static
Initial value:
= Field[str](
doc=(
"Namespace or schema name for all tables in APDB database. "
"Presently only works for PostgreSQL backend. "
"If schema with this name does not exist it will be created when "
"APDB tables are created."
),
default=None,
optional=True,
)

Definition at line 158 of file apdbSql.py.

◆ prefix

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.prefix = Field[str](doc="Prefix to add to table names and index names", default="")
static

Definition at line 157 of file apdbSql.py.

◆ ra_dec_columns

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.ra_dec_columns = ListField[str](default=["ra", "dec"], doc="Names of ra/dec columns in DiaObject table")
static

Definition at line 153 of file apdbSql.py.

◆ sql_echo

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.sql_echo = Field[bool](doc="If True then pass SQLAlchemy echo option.", default=False)
static

Definition at line 138 of file apdbSql.py.

◆ timer

lsst.dax.apdb.sql.apdbSql.ApdbSqlConfig.timer = Field[bool](doc="If True then print/log timing information", default=False)
static

Definition at line 168 of file apdbSql.py.


The documentation for this class was generated from the following file: