Giter VIP home page Giter VIP logo

trunk's Issues

[COR-838] Extension metadata stored in a trunk.toml file

Trunk CLI should use a trunk.toml file to store extension metadata. This will hold information currently passed as flags. Example:

[extension]
name = "my_extension"
version = "0.0.0"
description = "2021"
documentation = "documentation.my_extension.com"
repository = "github.com/my_extension"
license = "PostgreSQL"
homepage = "my_extension.com"
postgres_version = "15"
architecture = "x86_64"

From SyncLinear.com | COR-838

`trunk build` output should include `manifest.json`

trunk build output does not include manifest.json file. This file is required for trunk install. Outup file structure should look like:

❯ tar -tvf pgmq-0.2.1.tar.gz
-rw-rw-r-- ian/ian         279 2023-03-17 06:56 manifest.json
-rw-r--r-- ian/ian        2962 2023-03-16 14:25 pgmq--0.2.1.sql
-rwxr-xr-x ian/ian     2275640 2023-03-16 14:25 pgmq.so
-rw-r--r-- ian/ian         159 2023-03-16 14:25 pgmq.control

[COR-775] Add support for wider range of PGRX versions

❯ trunk build
Building from path .
Detected that we are building a pgrx extension
Detected pgrx version range =0.8.2
Using pgrx version 0.8.2
Building pgrx extension at path .
Step 1/10 : ARG PG_VERSION=15
Step 2/10 : ARG PGRX_VERSION=0.8.2
Step 3/10 : FROM quay.io/coredb/pgrx-builder:pg${PG_VERSION}-pgrx${PGRX_VERSION}
[/home/ian/.cargo/registry/src/github.com-1ecc6299db9ec823/pg-trunk-0.4.7/src/commands/containers.rs:306] &err = DockerStreamError {
    error: "unknown: Tag pg15-pgrx0.8.2 was deleted or has expired. To pull, revive via time machine",
}
thread 'main' panicked at 'error occurred: Other error: Docker stream error

Caused by:
    Docker stream error', /home/ian/.cargo/registry/src/github.com-1ecc6299db9ec823/pg-trunk-0.4.7/src/main.rs:51:6
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

We need to define a process for building and publishing PGRX-builder images. We need to support the latest version of PGRX in our builder images.

From SyncLinear.com | COR-775

[COR-844] Test Extensions with Trunk CLI

Users should be able to test their extensions via Trunk CLI with a command like trunk test. Initially, tests should cover the following:

  • Test extension can be installed in a local, containerized postgres instance with trunk install
  • Test extension can be enabled with CREATE EXTENSION CASCADE;
  • Test we're able to run some function the extension provides (this might come later)

This will help avoid publishing extensions that do not function as expected.

From SyncLinear.com | COR-844

[COR-772] Route for extension version history

Create a route that returns version history for a given extension:

  • /extensions/detail/{extension_name}/

  • array of versions for a given extension

    [
      {
        "createdAt": "2023-04-20 4:29:18.52241 +00:00:00",
        "description": "My incredible extension",
        "documentation": null,
        "homepage": "coredb.io",
        "version": "0.0.2",
        "license": "Apache-2.0",
        "name": "pgmq",
        "owners": [
          {
            "userId": "user_2PXTvcubP95TyEvTXZJOpzHjdJn",
            "userName": "coredb-service-user"
          }
        ],
        "repository": "https://github.com/CoreDB-io/coredb",
        "updatedAt": "2023-04-20 23:41:39.467896 +00:00:00"
        "publisher": "dummy"
      },
      {
        "createdAt": "2023-04-19 4:29:18.52241 +00:00:00",
        "description": "My incredible extension",
        "documentation": null,
        "homepage": "coredb.io",
        "version": "0.0.0",
        "license": "Apache-2.0",
        "name": "pgmq",
        "owners": [],
        "repository": "https://github.com/CoreDB-io/coredb",
        "updatedAt": "2023-04-20 22:41:39.467896 +00:00:00"
        "publisher": "dummy"
      },
      {
        "createdAt": "2023-04-18 4:29:18.52241 +00:00:00",
        "description": "My incredible extension",
        "documentation": null,
        "homepage": "coredb.io",
        "version": "0.0.0",
        "license": "Apache-2.0",
        "name": "pgmq",
        "owners": [],
        "repository": "https://github.com/CoreDB-io/coredb",
        "updatedAt": "2023-04-20 21:41:39.467896 +00:00:00"
        "publisher": "anotherdummy"
      },
    ]
    

From SyncLinear.com | COR-772

Tracking

Let's instrument cli to track events, so that we can show usage metrics on the web page for each extension

Create and design database for supporting extension directory

The goal is to create and design a database used to support a postgreSQL extension directory. Conceptually-speaking, this would be a postgreSQL equivalent to npmjs.org (JavaScript), pypi.org (Python), and crates.io (Rust).

This would be a backend storage, to which source and built binary distributions would be published and indexed.

  • Where will the packages be physically stored?
  • How to best organize metadata (e.g., author(s), versions)
  • Defined steps to publish extensions

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.