Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf70f095

Browse files
committed
Allow new relmapper entries when allow_system_table_mods is true.
This restores the pre-9.0 situation that it's possible to add new indexeson pg_class and other mapped-but-not-shared catalogs, so long as you brokethe glass and flipped the big red Dont-Touch-Me switch. As before, thereare a lot of gotchas, and you'd have to be pretty desperate to try thison a production database; but there doesn't seem to be a reason forrelmapper.c to be preventing such things all by itself. Perexperimentation with a case suggested by Cody Cutrer.
1 parent99081c6 commitf70f095

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

‎src/backend/utils/cache/relmapper.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -837,8 +837,11 @@ perform_relmap_update(bool shared, const RelMapFile *updates)
837837
else
838838
memcpy(&newmap,&local_map,sizeof(RelMapFile));
839839

840-
/* Apply the updates to newmap. No new mappings should appear. */
841-
merge_map_updates(&newmap,updates, false);
840+
/*
841+
* Apply the updates to newmap. No new mappings should appear, unless
842+
* somebody is adding indexes to system catalogs.
843+
*/
844+
merge_map_updates(&newmap,updates,allowSystemTableMods);
842845

843846
/* Write out the updated map and do other necessary tasks */
844847
write_relmap_file(shared,&newmap, true, true, true,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp