GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - plproxy/plproxy: PL/Proxy development

BranchesTags
Open more actions menu

Latest commit

 

History

397 Commits
397 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
config
config
 
 
doc
doc
 
 
sql
sql
 
 
src
src
 
 
test
test
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
AUTHORS
AUTHORS
 
 
COPYRIGHT
COPYRIGHT
 
 
META.json
META.json
 
 
Makefile
Makefile
 
 
NEWS.md
NEWS.md
 
 
README.md
README.md
 
 
plproxy.control
plproxy.control
 
 

Repository files navigation

PL/Proxy

PL/Proxy is a PostgreSQL procedural language (PL) handler that allows to do remote procedure calls between PostgreSQL databases, with optional sharding.

Features

Language has four statements:

  • Pick remote database:
    • CLUSTER <name> - use pre-configured cluster that has many databases
    • CONNECT <connstr> - use connstr directly
  • Set execution type:
    • RUN ON ALL - query is run on all databases in parallel
    • RUN ON ANY - pick server randomly
    • RUN ON <hash> - map hash to database
  • Replace default query:
    • SELECT ...

Example:

CREATE FUNCTION get_user_settings(i_username text) RETURNS SETOF user_settings AS $$
    RUN ON namehash(i_username):
$$ LANGUAGE plproxy;

It will run function with same name in remote database and fetch user_settings record.

Installation

For installation there must be PostgreSQL dev environment installed and pg_config in the PATH. Then just run:

$ make
$ make install

To run regression tests:

$ make installcheck

Location to pg_config can be set via PG_CONFIG variable:

$ make PG_CONFIG=/path/to/pg_config
$ make install PG_CONFIG=/path/to/pg_config
$ make installcheck PG_CONFIG=/path/to/pg_config

Note: Encoding regression test fails if the Postgres instance is not created with C locale. It can be considered expected failure then.

About

PL/Proxy development

plproxy.github.io/

Resources

Readme
License
Activity
Custom properties

Stars

198 stars

Watchers

18 watching

Forks

43 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.