Expand description
Functions to actually read the catalog tables from a running postgres instance, and translate them into ddl-catalog-structs.
Uses tokio-postgres through clorinde.
Most likely you’ll want to use reflect_db_state.
Modules§
- ordered_
float - Wrappers for total order on Floats. See the
OrderedFloatandNotNandocs for details.
Structs§
- AclItem
- Access control items, similar to what you’d get if you called
aclexplode, except that grants are grouped by grantee/grantor pairs. - DbState
- A large wrapper struct that holds the results of all the other reflections.
Only includes information for the single database, which is why
pg_databaseisn’t a collection. Objects that are “cluster shared” such as roles are those for the entire cluster. - Grant
- PgAggregate
- The DDL-only contents of
pg_aggregate - PgAm
- The DDL-only contents of
pg_am - PgAmop
- The DDL-only contents of
pg_amop - PgAmproc
- The DDL-only contents of
pg_amproc - PgAttrdef
- The DDL-only contents of
pg_attrdef - PgAttribute
- The DDL-only contents of
pg_attribute - PgAuth
Members - The DDL-only contents of
pg_auth_members - PgCast
- The DDL-only contents of
pg_cast - PgClass
- The DDL-only contents of
pg_class - PgClient
- An asynchronous PostgreSQL client.
- PgCollation
- The DDL-only contents of
pg_collation - PgConstraint
- The DDL-only contents of
pg_constraint - PgConversion
- The DDL-only contents of
pg_conversion - PgDatabase
- The DDL-only contents of
pg_database - PgDb
Role Setting - The DDL-only contents of
pg_db_role_setting - PgDefault
Acl - The DDL-only contents of
pg_default_acl - PgEnum
- The DDL-only contents of
pg_enum - PgEvent
Trigger - The DDL-only contents of
pg_event_trigger - PgExtension
- The DDL-only contents of
pg_extension - PgForeign
Data Wrapper - The DDL-only contents of
pg_foreign_data_wrapper - PgForeign
Server - The DDL-only contents of
pg_foreign_server - PgForeign
Table - The DDL-only contents of
pg_foreign_table - PgIndex
- The DDL-only contents of
pg_index - PgInherits
- The DDL-only contents of
pg_inherits - PgLanguage
- The DDL-only contents of
pg_language - PgMatviews
- The DDL-only contents of
pg_matviews - PgNamespace
- The DDL-only contents of
pg_namespace - PgOpclass
- The DDL-only contents of
pg_opclass - PgOperator
- The DDL-only contents of
pg_operator - PgOpfamily
- The DDL-only contents of
pg_opfamily - PgParameter
Acl - The DDL-only contents of
pg_parameter_acl - PgPartitioned
Table - The DDL-only contents of
pg_partitioned_table - PgPolicy
- The DDL-only contents of
pg_policy - PgProc
- The DDL-only contents of
pg_proc - PgPublication
- The DDL-only contents of
pg_publication - PgPublication
Namespace - The DDL-only contents of
pg_publication_namespace - PgPublication
Rel - The DDL-only contents of
pg_publication_rel - PgRange
- The DDL-only contents of
pg_range - PgRoles
- The DDL-only contents of
pg_roles - PgRules
- The DDL-only contents of
pg_rules - PgSequence
- The DDL-only contents of
pg_sequence - PgStatistic
Ext - The DDL-only contents of
pg_statistic_ext - PgSubscription
- The DDL-only contents of
pg_subscription - PgTransform
- The DDL-only contents of
pg_transform - PgTrigger
- The DDL-only contents of
pg_trigger - PgTs
Config - The DDL-only contents of
pg_ts_config - PgTs
Config Map - The DDL-only contents of
pg_ts_config_map - PgTs
Dict - The DDL-only contents of
pg_ts_dict - PgTs
Parser - The DDL-only contents of
pg_ts_parser - PgTs
Template - The DDL-only contents of
pg_ts_template - PgType
- The DDL-only contents of
pg_type - PgUser
Mappings - The DDL-only contents of
pg_user_mappings - PgViews
- The DDL-only contents of
pg_views - Str
- A
SmolStris a string type that has the following properties:
Enums§
- AclDefault
AclPrivilege - DbAcl
Privilege - Foreign
Data Wrapper AclPrivilege - Foreign
Server AclPrivilege - Function
AclPrivilege - Language
AclPrivilege - Parameter
AclPrivilege - PgAggregate
Aggfinalmodify - PgAggregate
Aggkind - PgAggregate
Aggmfinalmodify - PgAm
Amtype - PgAmop
Amoppurpose - PgAttribute
Attcompression - PgAttribute
Attgenerated - PgAttribute
Attidentity - PgAttribute
Initprivs Type - PgCast
Castcontext - PgCast
Castmethod - PgClass
Initprivs Type - PgClass
Relkind - PgClass
Relpersistence - PgClass
Relreplident - PgCollation
Collprovider - PgConstraint
Confdeltype - PgConstraint
Confmatchtype - PgConstraint
Confupdtype - PgConstraint
Contype - PgDatabase
Datlocprovider - PgDefault
AclDefaclobjtype - PgEvent
Trigger Evtenabled - PgForeign
Data Wrapper Initprivs Type - PgForeign
Server Initprivs Type - PgLanguage
Initprivs Type - PgNamespace
Initprivs Type - PgOperator
Oprkind - PgParameter
AclInitprivs Type - PgPartitioned
Table Partstrat - PgPolicy
Polcmd - PgProc
Proargmodes - PgProc
Prokind - PgProc
Proparallel - PgProc
Provolatile - PgStatistic
ExtStxkind - PgSubscription
Substream - PgSubscription
Subtwophasestate - PgTrigger
Tgenabled - PgType
Initprivs Type - PgType
Typalign - PgType
Typstorage - PgType
Typtype - Schema
AclPrivilege - Table
AclPrivilege - Table
Column AclPrivilege - Type
AclPrivilege
Functions§
- reflect_
db_ state - A large wrapper function that calls all the other reflection functions.
- reflect_
pg_ aggregate - Asynchronously pull the contents of
pg_aggregate - reflect_
pg_ am - Asynchronously pull the contents of
pg_am - reflect_
pg_ amop - Asynchronously pull the contents of
pg_amop - reflect_
pg_ amproc - Asynchronously pull the contents of
pg_amproc - reflect_
pg_ attrdef - Asynchronously pull the contents of
pg_attrdef - reflect_
pg_ attribute - Asynchronously pull the contents of
pg_attribute - reflect_
pg_ auth_ members - Asynchronously pull the contents of
pg_auth_members - reflect_
pg_ cast - Asynchronously pull the contents of
pg_cast - reflect_
pg_ class - Asynchronously pull the contents of
pg_class - reflect_
pg_ collation - Asynchronously pull the contents of
pg_collation - reflect_
pg_ constraint - Asynchronously pull the contents of
pg_constraint - reflect_
pg_ conversion - Asynchronously pull the contents of
pg_conversion - reflect_
pg_ database - Asynchronously pull the contents of
pg_database - reflect_
pg_ db_ role_ setting - Asynchronously pull the contents of
pg_db_role_setting - reflect_
pg_ default_ acl - Asynchronously pull the contents of
pg_default_acl - reflect_
pg_ enum - Asynchronously pull the contents of
pg_enum - reflect_
pg_ event_ trigger - Asynchronously pull the contents of
pg_event_trigger - reflect_
pg_ extension - Asynchronously pull the contents of
pg_extension - reflect_
pg_ foreign_ data_ wrapper - Asynchronously pull the contents of
pg_foreign_data_wrapper - reflect_
pg_ foreign_ server - Asynchronously pull the contents of
pg_foreign_server - reflect_
pg_ foreign_ table - Asynchronously pull the contents of
pg_foreign_table - reflect_
pg_ index - Asynchronously pull the contents of
pg_index - reflect_
pg_ inherits - Asynchronously pull the contents of
pg_inherits - reflect_
pg_ language - Asynchronously pull the contents of
pg_language - reflect_
pg_ matviews - Asynchronously pull the contents of
pg_matviews - reflect_
pg_ namespace - Asynchronously pull the contents of
pg_namespace - reflect_
pg_ opclass - Asynchronously pull the contents of
pg_opclass - reflect_
pg_ operator - Asynchronously pull the contents of
pg_operator - reflect_
pg_ opfamily - Asynchronously pull the contents of
pg_opfamily - reflect_
pg_ parameter_ acl - Asynchronously pull the contents of
pg_parameter_acl - reflect_
pg_ partitioned_ table - Asynchronously pull the contents of
pg_partitioned_table - reflect_
pg_ policy - Asynchronously pull the contents of
pg_policy - reflect_
pg_ proc - Asynchronously pull the contents of
pg_proc - reflect_
pg_ publication - Asynchronously pull the contents of
pg_publication - reflect_
pg_ publication_ namespace - Asynchronously pull the contents of
pg_publication_namespace - reflect_
pg_ publication_ rel - Asynchronously pull the contents of
pg_publication_rel - reflect_
pg_ range - Asynchronously pull the contents of
pg_range - reflect_
pg_ roles - Asynchronously pull the contents of
pg_roles - reflect_
pg_ rules - Asynchronously pull the contents of
pg_rules - reflect_
pg_ sequence - Asynchronously pull the contents of
pg_sequence - reflect_
pg_ statistic_ ext - Asynchronously pull the contents of
pg_statistic_ext - reflect_
pg_ subscription - Asynchronously pull the contents of
pg_subscription - reflect_
pg_ transform - Asynchronously pull the contents of
pg_transform - reflect_
pg_ trigger - Asynchronously pull the contents of
pg_trigger - reflect_
pg_ ts_ config - Asynchronously pull the contents of
pg_ts_config - reflect_
pg_ ts_ config_ map - Asynchronously pull the contents of
pg_ts_config_map - reflect_
pg_ ts_ dict - Asynchronously pull the contents of
pg_ts_dict - reflect_
pg_ ts_ parser - Asynchronously pull the contents of
pg_ts_parser - reflect_
pg_ ts_ template - Asynchronously pull the contents of
pg_ts_template - reflect_
pg_ type - Asynchronously pull the contents of
pg_type - reflect_
pg_ user_ mappings - Asynchronously pull the contents of
pg_user_mappings - reflect_
pg_ views - Asynchronously pull the contents of
pg_views
Type Aliases§
- AclDefault
AclItem - AclDefault
Grant - DbAcl
Item - DbGrant
- Foreign
Data Wrapper AclItem - Foreign
Data Wrapper Grant - Foreign
Server AclItem - Foreign
Server Grant - Function
AclItem - Function
Grant - Language
AclItem - Language
Grant - Map
- Parameter
AclItem - Parameter
Grant - Schema
AclItem - Schema
Grant - Set
- Table
AclItem - Table
Column AclItem - Table
Column Grant - Table
Grant - Type
AclItem - Type
Grant