Opened 19 months ago

Closed 19 months ago

Last modified 6 months ago

#27098 closed Cleanup/optimization (fixed)

Deprecate DatabaseIntrospection.get_indexes

Reported by: Claude Paroz Owned by: nobody
Component: Database layer (models, ORM) Version: master
Severity: Normal Keywords: introspection db-indexes
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


DatabaseIntrospection.get_indexes outputs a subset of DatabaseIntrospection.get_constraints, however only for single-column indexes. The use case was mainly for inspectdb primary key and unique detections, and for some tests. Now that multicolumn indexes is in sight, that API is less appealing and appears unnecessary (see also ticket:16220#comment:19).

Change History (8)

comment:1 Changed 19 months ago by Claude Paroz

Has patch: set
Patch needs improvement: set

comment:2 Changed 19 months ago by Akshesh Doshi

Keywords: introspection db-indexes added
Triage Stage: UnreviewedAccepted

comment:3 Changed 19 months ago by Tim Graham <timograham@…>

In 4c7bf83c:

Refs #27097, #27098 -- Moved PostgreSQL index type introspection to get_constraints().

comment:4 Changed 19 months ago by Claude Paroz

Patch needs improvement: unset

comment:5 Changed 19 months ago by Tim Graham

Triage Stage: AcceptedReady for checkin

comment:6 Changed 19 months ago by Claude Paroz <claude@…>

Resolution: fixed
Status: newclosed

In d3891256:

Fixed #27098 -- Deprecated DatabaseIntrospection.get_indexes

Thanks Akshesh <aksheshdoshi@…> for help with the PostgreSQL query.
Thanks Tim Graham for the review.

comment:7 Changed 19 months ago by Claude Paroz <claude@…>

In a1ad896:

Refs #27098 -- Added introspection for expression-based index on PostgreSQL

Also test it on PostGIS raster fields.

comment:8 Changed 6 months ago by Tim Graham <timograham@…>

In 578711c3:

Refs #27098 -- Removed DatabaseIntrospection.get_indexes() per deprecation timeline.

Note: See TracTickets for help on using tickets.
Back to Top