Native PostgreSQL Schema Script: postgres.sql - Resources and shadows
This page documents schema objects parsed from config/sql/native/postgres.sql.
Region: Resources and shadows
Resources, shadows, shadow partitions, connectors, and resource object reference data.
Tables
m_ref_resource_business_configuration_approver
Stores approver references for resource business configuration.
Inherits from: m_reference
Columns
| Column | Type | Required / constraints | Description |
|---|---|---|---|
|
|
primary key, required |
OID of the resource that owns the business configuration approver reference. |
|
|
Indexes
| Name | Columns | Purpose / notes |
|---|---|---|
|
|
Speeds up reverse lookup of resource business configuration approver references by target object and relation. Used for: resource business approver reference target searches |
Foreign keys
| Column | References | Notes |
|---|---|---|
|
ON DELETE CASCADE |
m_resource
Stores resource objects and resource-specific searchable state.
Represents ResourceType, see https://docs.evolveum.com/midpoint/reference/resources/resource-configuration/
XSD type: http://midpoint.evolveum.com/xml/ns/public/common/common-3#ResourceType
Inherits from: m_assignment_holder
Columns
| Column | Type | Required / constraints | Description |
|---|---|---|---|
|
|
primary key, required |
Resource object identifier. |
|
|
||
|
|
Business administrative state of the resource. |
|
|
|
Administrative availability status from the resource operational state. |
|
|
|
Last known resource availability status. |
|
|
|
OID of the connector referenced by the resource. |
|
|
|
Object type of the connector referenced by the resource. |
|
|
|
Relation URI identifier of the connector reference. |
|
|
|
Marks whether the resource is a resource template. |
|
|
|
Marks whether the resource is abstract. |
|
|
|
OID of the resource super-reference target. |
|
|
|
Object type of the resource super-reference target. |
|
|
|
Relation URI identifier of the resource super-reference. |
Indexes
| Name | Columns | Purpose / notes |
|---|---|---|
|
|
Speeds up lookup by original object name. Used for: original name searches |
|
|
Enforces unique normalized object names and speeds up exact name lookup. Used for: normalized name lookup and uniqueness checks. unique |
|
|
Speeds up filtering by object subtype. Used for: subtype filters |
|
|
Speeds up full-text-like object searches. Used for: full-text-like object searches |
|
|
Speeds up filtering or ordering by creation time. Used for: creation time filters and ordering |
|
|
Speeds up filtering or ordering by modification time. Used for: modification time filters and ordering |
Foreign keys
| Column | References |
|---|---|
|
|
|
|
|
m_shadow
Stores resource object shadows and their searchable synchronization state.
Represents ShadowType, see https://docs.evolveum.com/midpoint/reference/resources/shadow/ and also https://docs.evolveum.com/midpoint/reference/schema/focus-and-projections/
XSD type: http://midpoint.evolveum.com/xml/ns/public/common/common-3#ShadowType
No primary key is defined for this table.
Columns
| Column | Type | Required / constraints | Description |
|---|---|---|---|
|
|
required |
Shadow object identifier. |
|
|
||
|
|
required |
Original shadow name. |
|
|
required |
Normalized shadow name used for exact lookup. |
|
|
Serialized full shadow object. |
|
|
|
OID of the tenant reference target object. |
|
|
|
Object type of the tenant reference target. |
|
|
|
Relation URI identifier of the tenant reference. |
|
|
|
||
|
|
required, default |
Next container identifier value allocated within this shadow. |
|
|
required, default |
Shadow version used for optimistic locking. |
|
|
Policy situation URI identifiers attached to the shadow. |
|
|
|
Shadow subtype values used for subtype filtering. |
|
|
|
Text search helper content derived from selected shadow data. |
|
|
|
Indexed extension values stored as JSON data. |
|
|
|
OID of the object that created this shadow. |
|
|
|
Object type of the object that created this shadow. |
|
|
|
Relation URI identifier for the creator reference. |
|
|
|
URI identifier of the channel that created the shadow. |
|
|
|
Time when the shadow was created. |
|
|
|
OID of the object that last modified this shadow. |
|
|
|
Object type of the object that last modified this shadow. |
|
|
|
Relation URI identifier for the modifier reference. |
|
|
|
URI identifier of the channel that last modified the shadow. |
|
|
|
Time when the shadow was last modified. |
|
|
|
required, default |
Database timestamp when this row was created. Purely DB-managed metadata, not mapped to in midPoint. Updated in update trigger. |
|
|
required, default |
Database timestamp when this row was last modified. Purely DB-managed metadata, not mapped to in midPoint. Updated in update trigger. |
|
|
URI identifier of the shadow object class. |
|
|
|
OID of the resource that owns the shadow. |
|
|
|
Object type of the resource that owns the shadow. |
|
|
|
Relation URI identifier of the resource reference. |
|
|
|
Shadow intent value. |
|
|
|
Shadow tag value. |
|
|
|
Shadow kind classification. |
|
|
|
Marks whether the resource object is considered dead. |
|
|
|
Marks whether the resource object currently exists. |
|
|
|
Time of the last full synchronization for this shadow. |
|
|
|
required |
Number of pending operations recorded for this shadow. |
|
|
Primary identifier value of the resource object. |
|
|
|
Synchronization situation of the shadow. |
|
|
|
Time of the last synchronization situation update. |
|
|
|
Indexed shadow attributes stored as JSON data. |
|
|
|
Time when correlation processing started. |
|
|
|
Time when correlation processing ended. |
|
|
|
Time when a correlation case was opened. |
|
|
|
Time when a correlation case was closed. |
|
|
|
Correlation situation of the shadow. |
|
|
|
URI identifier of the disable reason. |
|
|
|
Time when the shadow becomes enabled. |
|
|
|
Time when the shadow becomes disabled. |
|
|
|
Last login timestamp observed for this shadow. |
m_shadow_default
Default shadow partition used before resource-specific shadow partitions are created.
No primary key is defined for this table.
This table is a partition of m_shadow. Columns are inherited from the partitioned table.
Indexes
| Name | Columns | Purpose / notes |
|---|---|---|
|
|
Speeds up lookup by original shadow name. Used for: original shadow name searches |
|
|
Speeds up lookup by normalized shadow name. Used for: normalized shadow name searches |
|
|
Enforces uniqueness of primary identifier value within object class and resource. Used for: shadow primary identifier lookup and uniqueness checks. unique |
|
|
Speeds up filtering by shadow subtype. Used for: subtype filters |
|
|
Speeds up filtering by policy situation. Used for: policy situation filters |
|
|
Speeds up filtering by indexed extension values. Used for: extension item filters |
|
|
Speeds up filtering by indexed shadow attributes. Used for: shadow attribute filters |
|
|
Speeds up full-text-like shadow searches. Used for: full-text-like shadow searches |
|
|
Speeds up filtering shadows by resource OID. Used for: resource shadow searches |
|
|
Speeds up filtering or ordering by creation time. Used for: creation time filters and ordering |
|
|
Speeds up filtering or ordering by modification time. Used for: modification time filters and ordering |
|
|
Speeds up filtering by correlation start time. Used for: correlation time filters |
|
|
Speeds up filtering by correlation end time. Used for: correlation time filters |
|
|
Speeds up filtering by correlation case open time. Used for: correlation case time filters |
|
|
Speeds up filtering by correlation case close time. Used for: correlation case time filters |
m_shadow_partition_def
Stores definitions of shadow partition tables managed by repository-side partition triggers.
No primary key is defined for this table.
Columns
| Column | Type | Required / constraints | Description |
|---|---|---|---|
|
|
Resource OID represented by the shadow partition. |
|
|
|
Object class identifier represented by the shadow partition, when partitioned by object class. |
|
|
|
required |
Physical table name for the shadow partition. |
|
|
required |
Whether this definition represents a real data partition. |
|
|
required |
Whether this partition is attached to the parent partitioned table. |
m_shadow_ref_attribute
Stores reference-valued shadow attributes for searching and reverse lookup.
No primary key is defined for this table.
Columns
| Column | Type | Required / constraints | Description |
|---|---|---|---|
|
|
required |
OID of the shadow that owns the reference attribute value. |
|
|
required |
Object type of the reference attribute owner. |
|
|
required |
URI identifier of the reference attribute path. |
|
|
OID of the resource containing the shadow. |
|
|
|
URI identifier of the owner shadow object class. |
|
|
|
required |
OID of the referenced target object. |
|
|
required |
Object type of the referenced target object. |
|
|
required |
Relation URI identifier of the reference attribute value. |
Indexes
| Name | Columns | Purpose / notes |
|---|---|---|
|
|
Speeds up lookup of reference attributes by owning shadow. Used for: shadow reference attribute owner searches |
Foreign keys
| Column | References | Notes |
|---|---|---|
|
ON DELETE CASCADE |
|
|
- |
Views
Views present derived or queryable data from repository tables.
m_object_view
Presents regular objects and shadows through a common object-shaped query surface.
Kind: view
Functions and procedures
Functions and procedures implement repository-side database behavior.
m_shadow_create_partition
Creates or attaches resource-specific shadow partitions when partition definitions are inserted.
Kind: function
m_shadow_delete_partition
Drops a shadow partition table when its partition definition is deleted.
Kind: function
m_shadow_update_partition
Attaches shadow partition tables when their partition definition is updated.
Kind: function
Triggers
Triggers run routines automatically when table rows are inserted, updated, or deleted.