databendlabs / databend

𝗗𝗮𝘁𝗮, 𝗔𝗻𝗮𝗹𝘆𝘁𝗶𝗰𝘀 & 𝗔𝗜. Modern alternative to Snowflake. Cost-effective and simple for massive-scale analytics. https://databend.com
https://docs.databend.com
Other
7.84k stars 750 forks source link

feature: Allow execute databend-query in AWS lambda #6726

Open flaneur2020 opened 2 years ago

flaneur2020 commented 2 years ago

Summary

there're some short run tasks like:

these tasks may requires the same role of the current tenant, like generating presign URLs, it needs the tenant's role to access the protected s3 prefix.

aws lambda supports:

I dunno whether aws lambda could fit databend-query for the short run tasks scenaries. maybe we could make an experiment about this.

Related Links

https://github.com/awslabs/aws-lambda-rust-runtime

Xuanwo commented 2 years ago

Providing a fn databend_query(sql: &str) -> Result<[u8]> seems really cool (even not for wasm or lambda).

We only need to fill service_fn: https://docs.rs/lambda_runtime/0.6.0/lambda_runtime/fn.service_fn.html