This week in Databend #25

Databend aimed to be an open source elastic and reliable cloud warehouse, it offers blazing fast query and combines elasticity, simplicity, low cost of the cloud, built to make the Data Cloud easy.

Big changes

Below is a list of some major changes that we don't want you to miss.

Features

Improvement

Build/Test/CI

Bug fixes

Experimental

A series of refactorings will be carried out at datavalues-dev branch to complete the migration. See RFC - new datavalues system design.

Tips

Let's learn a weekly tip from Databend.

Build/Test Databend with Dev container

In #3853 , we have introduced a development container to make it easy for contributors to build and test Databend.

build binary artifacts

./scripts/setup/run_docker.sh  make build

run test

./scripts/setup/run_docker.sh  make test

debug or get into dev container

./scripts/setup/run_docker.sh /bin/bash

Changlogs

You can check the changelogs of Databend nightly to learn about our latest developments.

Ecosystem/Upstream

From open source, for open source. Our team is also committed to contributing to the Rust ecosystem and upstream dependencies.

Meet Us

Please join the DatafuseLabs Community if you are interested in Databend.

We are looking forward to seeing you try our code. We have a strong team behind you to ensure a smooth experience in trying our code for your projects. If you are a hacker passionate about database internals, feel free to play with our code.

You can submit issues for any problems you find. We also highly appreciate any of your pull requests.

This week in Databend #24

Databend aimed to be an open source elastic and reliable cloud warehouse, it offers blazing fast query and combines elasticity, simplicity, low cost of the cloud, built to make the Data Cloud easy.

Big changes

Below is a list of some major changes that we don't want you to miss.

Features

Improvement

Bug fixes

Tips

Let's learn a weekly tip from Databend.

New datatype system design

We need to redesign the datatype system because current implementation had some shortcomes.

Now, DataType is an enum type:

  • We must use specific type after matching.
  • We can't use it as generic argument.
  • It may involve some nested datatypes.
  • And hard to put attributes into it.

Want to find out how we will improve the DataType system? Please check the RFC - New datatype system design.

Plan to jump to specific implementation and track progress? Databend#3794 might be for you.

Changlogs

You can check the changelogs of Databend nightly to learn about our latest developments.

Ecosystem/Upstream

From open source, for open source. Our team is also committed to contributing to the Rust ecosystem and upstream dependencies.

Meet Us

Please join the DatafuseLabs Community if you are interested in Databend.

We are looking forward to seeing you try our code. We have a strong team behind you to ensure a smooth experience in trying our code for your projects. If you are a hacker passionate about database internals, feel free to play with our code.

You can submit issues for any problems you find. We also highly appreciate any of your pull requests.

This week in Databend #23

Databend aimed to be an open source elastic and reliable cloud warehouse, it offers blazing fast query and combines elasticity, simplicity, low cost of the cloud, built to make the Data Cloud easy.

Big changes

Below is a list of some major changes that we don't want you to miss.

Features

Improvement

Performance Improvement

Bug fixes

Tips

Let's learn a weekly tip from Databend.

Tracing in Databend

Databend using Rust's tracing ecosystem tokio-tracing to do log and profile.

Distributed tracing with Jaeger

Jaeger, is a distributed tracing platform. It can be used for monitoring microservices-based distributed systems.

  • 4 steps to enable Jaeger monitor

    • build databend-query: cargo build --bin databend-query
    • run with DEBUG log level: LOG_LEVEL=DEBUG ./databend-query
    • start jaeger: docker run -d -p6831:6831/udp -p6832:6832/udp -p16686:16686 jaegertracing/all-in-one:latest
    • Open http://127.0.0.1:16686/
  • Jaeger Tracing Show

jaeger-tracing-show

  • Read More: https://databend.rs/dev/development/tracing#distributed-tracing-with-jaeger

Explore and diagnose with tokio-console

tokio-console is a diagnostics and debugging tool for asynchronous Rust programs.

  • 3 steps to enable console subscriber

    • build databend-query with rustflags & features: RUSTFLAGS="--cfg tokio_unstable" cargo build --bin databend-query --features tokio-console
    • run with the log level of TRACE: LOG_LEVEL=TRACE databend-query
    • run tokio-console
  • Run tokio-console to explore databend-query

query-console

  • Read More: https://databend.rs/dev/development/tracing#explore-and-diagnose-with-tokio-console

Changlogs

You can check the changelogs of Databend nightly to learn about our latest developments.

Ecosystem/Upstream

From open source, for open source. Our team is also committed to contributing to the Rust ecosystem and upstream dependencies.

Meet Us

Please join the DatafuseLabs Community if you are interested in Databend.

We are looking forward to seeing you try our code. We have a strong team behind you to ensure a smooth experience in trying our code for your projects. If you are a hacker passionate about database internals, feel free to play with our code.

You can submit issues for any problems you find. We also highly appreciate any of your pull requests.

This week in Databend #22

Databend aimed to be an open source elastic and reliable cloud warehouse, it offers blazing fast query and combines elasticity, simplicity, low cost of the cloud, built to make the Data Cloud easy.

Big changes

Below is a list of some major changes that we don't want you to miss.

Features

Improvement

Performance Improvement

  • improve performance of arithmetic plus functions by @zhyass (#3615)

Bug fixes

Tips

Let's learn a weekly tip from Databend.

Have fun with Databend UDF (User Defined Function)

In the last week we have introduced an experimental UDF engine, thanks @lianghanzhen. Let's try it out together.

Create a UDF

Databend supports the use of expressions as user defined functions. We can easily create a user-defined function in lambda-like style with CREATE FUNCTION <fn-name> AS (<fn-param0>, ...) -> <fn-expr>. Let's create a custom function to calculate the mean of two numbers together.

mysql> CREATE FUNCTION mean2number AS (x, y) -> (x + y) / 2;
Query OK, 0 rows affected (0.05 sec)
Read 0 rows, 0 B in 0.037 sec., 0 rows/sec., 0 B/sec.

Call a UDF

Calling UDF is the same as calling any other function. In the following example we have calculated the mean of 150 and 250.

mysql> SELECT mean2number(150, 250);
+-------------------+
| ((150 + 250) / 2) |
+-------------------+
|               200 |
+-------------------+
1 row in set (0.02 sec)
Read 1 rows, 1 B in 0.018 sec., 55.59 rows/sec., 55.59 B/sec.

Changlogs

You can check the changelogs of Databend nightly to learn about our latest developments.

Ecosystem/Upstream

From open source, for open source. Our team is also committed to contributing to the Rust ecosystem and upstream dependencies.

  • datafuselabs/openraft: An implementation of the Raft distributed consensus protocol using the Tokio framework. The async-raft fork, maintained by the databend team, fixes serious bugs.

Meet Us

Please join the DatafuseLabs Community if you are interested in Databend.

We are looking forward to seeing you try our code. We have a strong team behind you to ensure a smooth experience in trying our code for your projects. If you are a hacker passionate about database internals, feel free to play with our code.

You can submit issues for any problems you find. We also highly appreciate any of your pull requests.

This week in Databend #21

Databend aimed to be an open source elastic and reliable cloud warehouse, it offers blazing fast query and combines elasticity, simplicity, low cost of the cloud, built to make the Data Cloud easy.

This week, the migration of the Databend website to Docusaurus was completed; it is now hosted on a service sponsored by Vercel. Please enjoy it.

Big changes

Below is a list of some major changes that we don't want you to miss.

Features

Improvement

Performance Improvement

Bug fixes

Tips

Let's learn a weekly tip from Databend.

What's happening in Databend SQL layer

With #2983 ready for review, Databend's SQL layer will see the arrival of a new planner framework.

In fact, we have a number of plans for refactoring the SQL layer, which may even include a rewritten parser.

Changlogs

You can check the changelogs of Databend nightly to learn about our latest developments.

Ecosystem/Upstream

From open source, for open source. Our team is also committed to contributing to the Rust ecosystem and upstream dependencies.

Meet Us

Please join the DatafuseLabs Community if you are interested in Databend.

We are looking forward to seeing you try our code. We have a strong team behind you to ensure a smooth experience in trying our code for your projects. If you are a hacker passionate about database internals, feel free to play with our code.

You can submit issues for any problems you find. We also highly appreciate any of your pull requests.