forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit1fb57af
committed
Create the infrastructure for planner support functions.
Rename/repurpose pg_proc.protransform as "prosupport". The idea isstill that it names an internal function that provides knowledge tothe planner about the behavior of the function it's attached to;but redesign the API specification so that it's not limited to doingjust one thing, but can support an extensible set of requests.The original purpose of simplifying a function call is handled bythe first request type to be invented, SupportRequestSimplify.Adjust all the existing transform functions to handle this API,and rename them fron "xxx_transform" to "xxx_support" to reflectthe potential generalization of what they do. (Since we neverpreviously provided any way for extensions to add transform functions,this change doesn't create an API break for them.)Also add DDL and pg_dump support for attaching a support function to auser-defined function. Unfortunately, DDL access has to be restrictedto superusers, at least for now; but seeing that support functionswill pretty much have to be written in C, that limitation is justtheoretical. (This support is untested in this patch, but a follow-onpatch will add cases that exercise it.)Discussion:https://postgr.es/m/15193.1548028093@sss.pgh.pa.us1 parent1a8d5af commit1fb57af
File tree
41 files changed
+698
-294
lines changed- doc/src/sgml
- ref
- src
- backend
- catalog
- commands
- optimizer/util
- parser
- utils/adt
- bin/pg_dump
- t
- include
- catalog
- nodes
- parser
- utils
- test
- modules/test_ddl_deparse
- expected
- sql
- regress
- expected
- sql
- tools/findoidjoins
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
41 files changed
+698
-294
lines changedLines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
5146 | 5146 |
| |
5147 | 5147 |
| |
5148 | 5148 |
| |
5149 |
| - | |
| 5149 | + | |
5150 | 5150 |
| |
5151 | 5151 |
| |
5152 |
| - | |
5153 |
| - | |
| 5152 | + | |
| 5153 | + | |
5154 | 5154 |
| |
5155 | 5155 |
| |
5156 | 5156 |
| |
|
Lines changed: 7 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
4521 | 4521 |
| |
4522 | 4522 |
| |
4523 | 4523 |
| |
| 4524 | + | |
| 4525 | + | |
| 4526 | + | |
| 4527 | + | |
| 4528 | + | |
| 4529 | + | |
| 4530 | + | |
4524 | 4531 |
| |
4525 | 4532 |
| |
4526 | 4533 |
| |
|
Lines changed: 19 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
40 | 40 |
| |
41 | 41 |
| |
42 | 42 |
| |
| 43 | + | |
43 | 44 |
| |
44 | 45 |
| |
45 | 46 |
| |
| |||
248 | 249 |
| |
249 | 250 |
| |
250 | 251 |
| |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
251 | 270 |
| |
252 | 271 |
| |
253 | 272 |
| |
|
Lines changed: 14 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
33 | 33 |
| |
34 | 34 |
| |
35 | 35 |
| |
| 36 | + | |
36 | 37 |
| |
37 | 38 |
| |
38 | 39 |
| |
| |||
477 | 478 |
| |
478 | 479 |
| |
479 | 480 |
| |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
480 | 494 |
| |
481 | 495 |
| |
482 | 496 |
| |
|
Lines changed: 86 additions & 34 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3241 | 3241 |
| |
3242 | 3242 |
| |
3243 | 3243 |
| |
3244 |
| - | |
3245 |
| - | |
3246 |
| - | |
3247 |
| - | |
3248 |
| - | |
3249 |
| - | |
3250 |
| - | |
3251 |
| - | |
3252 |
| - | |
3253 |
| - | |
3254 |
| - | |
3255 |
| - | |
3256 |
| - | |
3257 |
| - | |
3258 |
| - | |
3259 |
| - | |
3260 |
| - | |
3261 |
| - | |
3262 |
| - | |
3263 |
| - | |
3264 |
| - | |
3265 |
| - | |
3266 |
| - | |
3267 |
| - | |
3268 |
| - | |
3269 |
| - | |
3270 |
| - | |
3271 |
| - | |
3272 |
| - | |
3273 |
| - | |
3274 |
| - | |
3275 |
| - | |
3276 |
| - | |
3277 |
| - | |
3278 | 3244 |
| |
3279 | 3245 |
| |
3280 | 3246 |
| |
| |||
3388 | 3354 |
| |
3389 | 3355 |
| |
3390 | 3356 |
| |
| 3357 | + | |
| 3358 | + | |
| 3359 | + | |
| 3360 | + | |
| 3361 | + | |
| 3362 | + | |
| 3363 | + | |
| 3364 | + | |
| 3365 | + | |
| 3366 | + | |
| 3367 | + | |
| 3368 | + | |
| 3369 | + | |
| 3370 | + | |
| 3371 | + | |
| 3372 | + | |
| 3373 | + | |
| 3374 | + | |
| 3375 | + | |
| 3376 | + | |
| 3377 | + | |
| 3378 | + | |
| 3379 | + | |
| 3380 | + | |
| 3381 | + | |
| 3382 | + | |
| 3383 | + | |
| 3384 | + | |
| 3385 | + | |
| 3386 | + | |
| 3387 | + | |
| 3388 | + | |
| 3389 | + | |
| 3390 | + | |
| 3391 | + | |
| 3392 | + | |
| 3393 | + | |
| 3394 | + | |
| 3395 | + | |
| 3396 | + | |
| 3397 | + | |
| 3398 | + | |
| 3399 | + | |
| 3400 | + | |
| 3401 | + | |
| 3402 | + | |
| 3403 | + | |
| 3404 | + | |
| 3405 | + | |
| 3406 | + | |
| 3407 | + | |
| 3408 | + | |
| 3409 | + | |
| 3410 | + | |
| 3411 | + | |
| 3412 | + | |
| 3413 | + | |
| 3414 | + | |
| 3415 | + | |
| 3416 | + | |
| 3417 | + | |
| 3418 | + | |
| 3419 | + | |
| 3420 | + | |
| 3421 | + | |
| 3422 | + | |
| 3423 | + | |
| 3424 | + | |
| 3425 | + | |
| 3426 | + | |
| 3427 | + | |
| 3428 | + | |
| 3429 | + | |
| 3430 | + | |
| 3431 | + | |
| 3432 | + | |
| 3433 | + | |
| 3434 | + | |
| 3435 | + | |
| 3436 | + | |
| 3437 | + | |
| 3438 | + | |
| 3439 | + | |
| 3440 | + | |
| 3441 | + | |
| 3442 | + |
Lines changed: 12 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
78 | 78 |
| |
79 | 79 |
| |
80 | 80 |
| |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
81 | 86 |
| |
82 | 87 |
| |
83 | 88 |
| |
| |||
97 | 102 |
| |
98 | 103 |
| |
99 | 104 |
| |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
100 | 112 |
| |
101 | 113 |
| |
102 | 114 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
632 | 632 |
| |
633 | 633 |
| |
634 | 634 |
| |
| 635 | + | |
635 | 636 |
| |
636 | 637 |
| |
637 | 638 |
| |
|
Lines changed: 36 additions & 16 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
286 | 286 |
| |
287 | 287 |
| |
288 | 288 |
| |
289 |
| - | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
290 | 293 |
| |
291 |
| - | |
| 294 | + | |
292 | 295 |
| |
293 | 296 |
| |
294 | 297 |
| |
| |||
301 | 304 |
| |
302 | 305 |
| |
303 | 306 |
| |
| 307 | + | |
| 308 | + | |
304 | 309 |
| |
305 | 310 |
| |
306 | 311 |
| |
307 | 312 |
| |
308 | 313 |
| |
309 |
| - | |
310 |
| - | |
311 |
| - | |
312 |
| - | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
313 | 318 |
| |
314 | 319 |
| |
315 | 320 |
| |
316 | 321 |
| |
317 | 322 |
| |
318 |
| - | |
319 |
| - | |
320 |
| - | |
321 |
| - | |
322 |
| - | |
| 323 | + | |
323 | 324 |
| |
324 |
| - | |
325 |
| - | |
326 |
| - | |
327 |
| - | |
328 | 325 |
| |
329 | 326 |
| |
330 | 327 |
| |
331 | 328 |
| |
332 |
| - | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
333 | 353 |
| |
334 | 354 |
| |
335 | 355 |
| |
|
Lines changed: 11 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
88 | 88 |
| |
89 | 89 |
| |
90 | 90 |
| |
| 91 | + | |
91 | 92 |
| |
92 | 93 |
| |
93 | 94 |
| |
| |||
319 | 320 |
| |
320 | 321 |
| |
321 | 322 |
| |
322 |
| - | |
| 323 | + | |
323 | 324 |
| |
324 | 325 |
| |
325 | 326 |
| |
| |||
656 | 657 |
| |
657 | 658 |
| |
658 | 659 |
| |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
659 | 669 |
| |
660 | 670 |
| |
661 | 671 |
| |
|
0 commit comments
Comments
(0)