forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit647fa50
committed
Remove arbitrary FUNC_MAX_ARGS limit in int2vectorin and oidvectorin.
int2vectorin limited the number of array elements it'd take toFUNC_MAX_ARGS, which is probably fine for the traditional use-cases.But now that pg_publication_rel.prattrs is an int2vector, it's notfine at all: it's easy to construct cases where that can have up toabout MaxTupleAttributeNumber entries. Trying to replicate suchtables leads to logical-replication failures.As long as we have to touch this code anyway, let's just removethe a-priori limit altogether, and let it accept any size that'llbe allowed by repalloc. (Note that since int2vector isn't toastable,we cannot store arrays longer than about BLCKSZ/2; but there is nogood excuse for letting int2vectorin depend on that. Perhaps wewill lift the no-toast restriction someday.)While at it, also improve the equivalent logic in oidvectorin.I don't know of any practical use-case for long oidvectors rightnow, but doing it right actually makes the code shorter.Per report from Erik Rijkers. Back-patch to v15 wherepg_publication_rel.prattrs was added.Discussion:https://postgr.es/m/668ba539-33c5-8190-ca11-def2913cb94b@xs4all.nl1 parent3f244d0 commit647fa50
2 files changed
+22
-29
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
146 | 147 | | |
147 | 148 | | |
148 | | - | |
| 149 | + | |
| 150 | + | |
149 | 151 | | |
150 | | - | |
| 152 | + | |
151 | 153 | | |
152 | 154 | | |
153 | 155 | | |
| |||
157 | 159 | | |
158 | 160 | | |
159 | 161 | | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
160 | 168 | | |
161 | 169 | | |
162 | 170 | | |
| |||
176 | 184 | | |
177 | 185 | | |
178 | 186 | | |
179 | | - | |
| 187 | + | |
180 | 188 | | |
181 | 189 | | |
182 | 190 | | |
183 | 191 | | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | 192 | | |
191 | 193 | | |
192 | 194 | | |
| |||
261 | 263 | | |
262 | 264 | | |
263 | 265 | | |
264 | | - | |
265 | | - | |
266 | | - | |
267 | | - | |
268 | | - | |
269 | | - | |
270 | 266 | | |
271 | 267 | | |
272 | 268 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
115 | 115 | | |
116 | 116 | | |
117 | 117 | | |
| 118 | + | |
118 | 119 | | |
119 | 120 | | |
120 | | - | |
| 121 | + | |
| 122 | + | |
121 | 123 | | |
122 | | - | |
| 124 | + | |
123 | 125 | | |
124 | 126 | | |
125 | 127 | | |
126 | 128 | | |
127 | 129 | | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
128 | 137 | | |
129 | 138 | | |
130 | 139 | | |
131 | 140 | | |
132 | 141 | | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | 142 | | |
140 | 143 | | |
141 | 144 | | |
| |||
212 | 215 | | |
213 | 216 | | |
214 | 217 | | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | 218 | | |
222 | 219 | | |
223 | 220 | | |
| |||
0 commit comments
Comments
(0)