SuperAPI AI 工具集

ducklake-test

测试与质量

查看项目

更新于 10-16 08:07

技能介绍

用途:在本地以 DuckLake 配置启动 duckgres(S3 后端存储 + PostgreSQL 元数据),用于测试 duckgres 对 DuckLake 的支持或复现相关场景。

主要能力与做法:

  1. 启动依赖服务(PostgreSQL 元数据存储 + MinIO 对象存储):docker-compose up -d。
  2. 结束已有 duckgres 进程:pkill -f duckgres || true。
  3. 确保存在配置文件 duckgres_local_test.yaml,其中 host 为 0.0.0.0、port 为 35437、data_dir 为 ./data,用户 postgres/postgres,加载 ducklake 扩展,metadata_store 指向 postgres:host=localhost port=5433(用户 ducklake、密码 ducklake、库名 ducklake),object_store 为 s3://ducklake/data/,s3_endpoint 为 localhost:9000,访问密钥与密钥均为 minioadmin,region 为 us-east-1,禁用 SSL 并使用 path 风格。
  4. 构建并运行:go build -o duckgres . && ./duckgres --config duckgres_local_test.yaml。
  5. 在另一终端连接:PGPASSWORD=postgres psql "host=127.0.0.1 port=35437 user=postgres sslmode=require"。
  6. 清理:pkill -f duckgres && docker-compose down。

适用场景:本地端到端验证 duckgres 与 DuckLake 的读写与元数据行为、复现问题。

限制:资料未说明支持的操作系统、Go 版本、依赖端口冲突处理、生产可用性、认证与安全建议,也未提供收费、性能或效果信息,均暂未提供。