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

Demo of projection database served over duckdbvfs barebone implementation #4

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

carlopi
Copy link
Owner

@carlopi carlopi commented Oct 3, 2024

Demo of projection database served over duckdbvfs barebone implementation.

To try this out:

  1. Generate proj.db
#include <stdio.h>
#include "spatial/src/spatial/proj/proj_db.c"

int main(void)
{
    for (unsigned int i = 0; i < proj_db_len; i++)
        putchar(proj_db[i]);
    return 0;
}

g++ file.cpp -o generate_proj && ./generate_proj > proj.db
(should this part of the Makefile? Or it's already there?)

  1. Launch http-server from the same folder where proj.db is

  2. python3 duckdb/scripts/run_tests_one_by_one.py ./build/release/test/unittest '/Users/carlo/duckdblabs/duckdb_spatial/test/sql/*

TODO:

  • Sort out context cleanup (see failure in unittester)
  • Make location configurable via DuckDB option (should there be a MAP[extension_name] -> (MAP[option_name] -> option_value) to store extension options needed at load time ?
  • Figure out whether proj.db should be fetched on load or anyhow proper strategy. Or maybe native have it backed in (who cares) but optionally configurable, and Wasm has it always remote

@carlopi
Copy link
Owner Author

carlopi commented Oct 3, 2024

Sizes for Wasm extensions [pre / post] [uncompressed / compressed]:

-rw-r--r--   1 carlo  staff  22808679 Oct  3 14:24 current_spatial.duckdb_extension.wasm
-rw-r--r--   1 carlo  staff   4420396 Oct  3 14:24 current_spatial.duckdb_extension.wasm.br
-rwxr-xr-x   1 carlo  staff  14502924 Oct  3 14:23 next_spatial.duckdb_extension.wasm
-rwxr-xr-x   1 carlo  staff   3340354 Oct  3 14:21 next_spatial.duckdb_extension.wasm.br

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

Successfully merging this pull request may close these issues.

1 participant