Index functions and INDEX_CREATE_SKIP_BUILD - Mailing list pgsql-hackers

From Antonin Houska
Subject Index functions and INDEX_CREATE_SKIP_BUILD
Date
Msg-id 5275.1764659928@localhost
Whole thread Raw
Responses Re: Index functions and INDEX_CREATE_SKIP_BUILD
List pgsql-hackers
In ReindexRelationConcurrently(), the call of index_concurrently_create_copy()
is enclosed in

    /*
     * Switch to the table owner's userid, so that any index functions are
     * run as that user.  Also lock down security-restricted operations
     * and arrange to make GUC variable changes local to this command.
     */
    GetUserIdAndSecContext(&save_userid, &save_sec_context);
    SetUserIdAndSecContext(heapRel->rd_rel->relowner,
                           save_sec_context | SECURITY_RESTRICTED_OPERATION);
    save_nestlevel = NewGUCNestLevel();

and

    /* Roll back any GUC changes executed by index functions */
    AtEOXact_GUC(false, save_nestlevel);

    /* Restore userid and security context */
    SetUserIdAndSecContext(save_userid, save_sec_context);

Which index functions can be called if index_create() receives the
INDEX_CREATE_SKIP_BUILD flag?

-- 
Antonin Houska
Web: https://www.cybertec-postgresql.com



pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Refactor how we form HeapTuples for CatalogTuple(Insert|Update)
Next
From: "Hayato Kuroda (Fujitsu)"
Date:
Subject: RE: Parallel Apply