GithubHelp home page GithubHelp logo

Version detection about postgrest-openapi HOT 5 OPEN

postgrest avatar postgrest commented on May 18, 2024
Version detection

from postgrest-openapi.

Comments (5)

laurenceisla avatar laurenceisla commented on May 18, 2024 1

@steve-chavez For the Info Object it's mostly to get the same result as the core repo. But it may be also needed to generate the documentarion URL (although this one needs a simplified version).

Edit: Btw I mistakenly said "PostgreSQL" version instead of "PostgREST" version.

from postgrest-openapi.

steve-chavez avatar steve-chavez commented on May 18, 2024

Hm, what's the need for the version?

from postgrest-openapi.

steve-chavez avatar steve-chavez commented on May 18, 2024

Got it. So I guess the same problem exists for the server_proxy_uri too:

create or replace function get_postgrest_openapi_spec(
schemas text[],
server_proxy_uri text default 'http://0.0.0.0:3000',
version text default null

While the schemas can be obtained from our tx-settings.


Maybe we need a concept of session-scoped settings on PostgREST to make this work. So each config option (coming from file or env var) gets a set_config($,$, false) thus is always available. Unlike tx-settings this wouldn't have a perf cost impact.

from postgrest-openapi.

wayland avatar wayland commented on May 18, 2024

What are tx-settings? I'm assuming it means transaction settings? Is this set_config within a transaction or something?

from postgrest-openapi.

steve-chavez avatar steve-chavez commented on May 18, 2024

I'm assuming it means transaction settings? Is this set_config within a transaction or something?

@wayland Yes, basically set_config(.., .., true). We use them like mentioned on PostgREST/postgrest#3019

from postgrest-openapi.

Related Issues (16)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.