Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of extension via install statement #20

Open
soerenwolfers opened this issue Jun 13, 2024 · 2 comments
Open

Use of extension via install statement #20

soerenwolfers opened this issue Jun 13, 2024 · 2 comments

Comments

@soerenwolfers
Copy link

Sorry that this issue is not really specific to this extension, but this is just the first time I am trying to use an extension:

Can this extension be used using a

INSTALL extensionname FROM 'URL'

statement in duckdb for some choice of URL?

If there is no public URL for this yet, which files would I have to make available on a server to enable this?

@AntiKnot
Copy link

AntiKnot commented Aug 6, 2024

It depends on extension type. <core | community | unsigned custom third-party>
Some unsigned, custom third-party extensions do not support URL downloads.
Installation Location is a better solution.

For vss, it's member of core extension. just INSTALL vss;
For community, INSTALL <name> FROM community;
For Cloud Service, download from S3.

@carlopi
Copy link
Contributor

carlopi commented Sep 10, 2024

@szarnyasg: I think this can be moved to duckdb/duckdb, given it's a general developer question, and eventually moved over to the documentation.


Basic answer is that those are (at the moment) the only requirements I am aware of:

  • INSTALL name FROM 'http://some.url' will look for a file at http://some.url/DUCKDB_VERSION/DUCKDB_PLATFORM/name.duckdb_extension.gz
  • if not found, and protocol is NOT http, it will try also name.duckdb_extension
  • if in duckdb-wasm, path is expected to be name.duckdb_extension.wasm

Other info:

  • INSTALL name FROM repo_name will expect repo_name to be a known shorthand for a repository (basically core, core-nightly or community)
  • INSTALL name FROM 'quoted_name' implies quoted_name is either a local (relative or absolute) path or remote one. s3-based or azure-based will also work (even though it's not really tested)
  • httpfs is special, in the sense that when needed to fetch extensions over https or s3 it will be (if not present locally) installed from core repository over http.

That is basically it, there is at the moment no metadata or index, and even if introduced it will likely be optional.

Note that building duckdb locally, say CORE_EXTENSIONS="httpfs;fts;inet" GEN=ninja make will also build a local extension repository in build/release/repository. That repository is NOT gzipped, but that's currently the only difference between hosted and the relevant build repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants