JeremyHi
4fdee5ea3c
feat: deal with node epoch ( #1795 )
...
* feat: deal with node epoch
* feat: dn send node_epoch
* Update src/meta-srv/src/handler/persist_stats_handler.rs
Co-authored-by: dennis zhuang <killme2008@gmail.com >
* Update src/meta-srv/src/service/store/ext.rs
Co-authored-by: dennis zhuang <killme2008@gmail.com >
* chore: by cr
---------
Co-authored-by: dennis zhuang <killme2008@gmail.com >
2023-06-20 07:07:05 +00:00
dennis zhuang
30472cebae
feat: prepare supports caching logical plan and infering param types ( #1776 )
...
* feat: change do_describe function signature
* feat: infer param type and cache logical plan for msyql prepared statments
* fix: convert_value
* fix: forgot helper
* chore: comments
* fix: typo
* test: add more tests and test date, datatime in mysql
* chore: fix CR comments
* chore: add location
* chore: by CR comments
* Update tests-integration/tests/sql.rs
Co-authored-by: Ruihang Xia <waynestxia@gmail.com >
* chore: remove the trace
---------
Co-authored-by: Ruihang Xia <waynestxia@gmail.com >
2023-06-20 04:07:28 +00:00
LFC
2dd86b686f
feat: extend region leases in Metasrv ( #1784 )
...
* feat: extend region leases in Metasrv
* fix: resolve PR comments
2023-06-19 19:55:59 +08:00
LFC
128c6ec98c
feat: region alive keeper in Datanode ( #1780 )
2023-06-19 14:50:33 +08:00
dennis zhuang
09747ea206
feat: use DataFrame to replace SQL for Prometheus remote read ( #1774 )
...
* feat: debug QueryEngineState
* feat: impl read_table to create DataFrame for a table
* fix: clippy warnings
* feat: use DataFrame to handle prometheus remote read quries
* Update src/frontend/src/instance/prometheus.rs
Co-authored-by: LFC <bayinamine@gmail.com >
* chore: CR comments
---------
Co-authored-by: LFC <bayinamine@gmail.com >
2023-06-14 07:39:28 +00:00
Yingwen
5b8e54e60e
feat: Add HTTP API for cpu profiling ( #1694 )
...
* chore: print source error in mem-prof
* feat(common-pprof): add pprof crate
* feat(servers): Add pprof handler to router
refactor the mem_prof handler to avoid checking feature while
registering router
* feat(servers): pprof handler support different output type
* docs(common-pprof): Add readme
* feat(common-pprof): Build guard using code in pprof-rs's example
* feat(common-pprof): use prost
* feat: don't add timeout to perf api
* feat: add feature pprof
* feat: update readme
* test: fix tests
* feat: close region in TestBase
* feat(pprof): addres comments
2023-06-07 15:25:16 +08:00
Lei, HUANG
8cda1635cc
feat: make jemalloc the default allocator ( #1733 )
...
* feat: add jemalloc metrics
* fix: dep format
2023-06-06 12:11:22 +00:00
Lei, HUANG
f63ddb57c3
fix: parquet time range predicate panic ( #1735 )
...
fix: parquet reader should use store schema to build time range predicate
2023-06-06 19:11:45 +08:00
Yingwen
1b4976b077
feat: Adds some metrics for write path and flush ( #1726 )
...
* feat: more metrics
* feat: Add preprocess elapsed
* chore(storage): rename metric
* test: fix tests
2023-06-05 21:35:44 +08:00
Lei, HUANG
166fb8871e
chore: bump greptimedb version 0.4.0 ( #1724 )
2023-06-05 18:41:53 +08:00
JeremyHi
3d7185749d
feat: insert with stream ( #1703 )
...
* feat: insert with stream
* chore: by CR
2023-06-03 03:58:00 +00:00
LFC
5004cf6d9a
feat: make grpc insert requests in a batch ( #1687 )
...
* feat: make Prometheus remote write in a batch
* rebase
* fix: resolve PR comments
* fix: resolve PR comments
* fix: resolve PR comments
2023-06-02 09:06:48 +00:00
Ruihang Xia
8e69aef973
feat: serialize/deserialize support for PromQL plans ( #1684 )
...
* implement serializer
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy and CR comments
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix compile error
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* register registry
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* enable promql plan for dist planner
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
2023-06-02 16:14:05 +08:00
Ruihang Xia
2615718999
feat: merge scan for distributed execution ( #1660 )
...
* generate exec plan
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* move DatanodeClients to client crate
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* wip MergeScanExec::to_stream
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix compile errors
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix default catalog
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix expand order of new stage
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* move sqlness cases contains plan out of common dir
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* refactor information schema to allow duplicated scan call
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix: ignore two cases due to substrait
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* reorganise sqlness common cases
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix typos
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* redact round robin partition number
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* Apply suggestions from code review
Co-authored-by: Yingwen <realevenyag@gmail.com >
* skip tranforming projection
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update sqlness result
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* revert common/order
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* Update src/query/src/dist_plan/merge_scan.rs
Co-authored-by: JeremyHi <jiachun_feng@proton.me >
* update sqlness result
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update sqlness result again
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* resolve CR comments
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* ignore region failover IT
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update sqlness result again and again
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* unignore some tests about projection
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* enable failover tests
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
Co-authored-by: Yingwen <realevenyag@gmail.com >
Co-authored-by: JeremyHi <jiachun_feng@proton.me >
2023-06-02 06:42:54 +00:00
fys
fe6e3daf81
fix: failed to insert data with u8 ( #1701 )
...
* fix: failed to insert data with u8 field
* remove unused code
* fix cr
2023-06-02 06:01:59 +00:00
Weny Xu
f811ae4665
fix: enable region failover test ( #1699 )
...
fix: fix region failover test
2023-06-02 12:05:37 +08:00
Ruihang Xia
e5b6f8654a
feat: optimizer rule to pass expected output ordering hint ( #1675 )
...
* move type convertsion rule into optimizer dir
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* implement order_hint rule
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* add test
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* it works!
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* use column name instead
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* accomplish test case
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update lock file
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
2023-06-02 03:43:51 +00:00
fys
86adac1532
chore: reject table creation when partitions exceeds peer number ( #1654 )
...
* chore: table creation is rejected, when partition_num exceeds peer_num
* chore: modify no_active_datanode error msg
* fix: ut
* fix sqlness test and add limit for select peer in region_failover
* upgrade greptime-proto
* self cr
* fix: cargo sqlness
* chore: add table info in select ctx for failover
* fix sqlness
2023-06-01 09:05:17 +00:00
Ning Sun
e7a410573b
test: fix sqlx compatibility and adds integration test for sqlx ( #1686 )
...
* test: fix sqlx compatibility and adds integration test for sqlx
* test: correct insert statements
2023-06-01 15:43:13 +08:00
Yingwen
548f0d1e2a
feat: Add app version metric ( #1685 )
...
* feat: Add app version metric
* chore: use greptimedb instead of greptime
2023-06-01 14:31:08 +08:00
Zheming Li
5467ea496f
feat: Add column supports at first or after the existing columns ( #1621 )
...
* feat: Add column supports at first or after the existing columns
* Update src/common/query/Cargo.toml
---------
Co-authored-by: dennis zhuang <killme2008@gmail.com >
2023-06-01 02:13:00 +00:00
dennis zhuang
ae8203fafa
fix: prepare statement doesn't support insert clause ( #1680 )
...
* fix: insert clause doesn't support prepare statement
* fix: manifeste dir
* fix: format
* fix: temp path
2023-05-31 20:14:58 +08:00
Ruihang Xia
ac3666b841
chore(deps): bump arrow/parquet to 40.0, datafuson to the latest HEAD ( #1677 )
...
* fix compile error
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* remove deprecated substrait
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update deps
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* downgrade opendal to 0.33.1
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* change finish's impl
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* update test results
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* ignore failing cases
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
2023-05-31 18:55:02 +08:00
Xuanwo
6b08a5f94e
chore: Bump OpenDAL to v0.36 ( #1678 )
...
* chore: Bump OpenDAL to v0.36
Signed-off-by: Xuanwo <github@xuanwo.io >
* Fix
Signed-off-by: Xuanwo <github@xuanwo.io >
---------
Signed-off-by: Xuanwo <github@xuanwo.io >
2023-05-31 11:12:40 +08:00
Yingwen
c5f6d7c99a
refactor: update proto and rename incorrect region_id fields ( #1670 )
2023-05-30 15:19:04 +09:00
dennis zhuang
ab5dfd31ec
feat: sql dialect for different protocols ( #1631 )
...
* feat: add SqlDialect to query context
* feat: use session in postgrel handlers
* chore: refactor sql dialect
* feat: use different dialects for different sql protocols
* feat: adds GreptimeDbDialect
* refactor: replace GenericDialect with GreptimeDbDialect
* feat: save user info to session
* fix: compile error
* fix: test
2023-05-30 09:52:35 +08:00
Ruihang Xia
b27c569ae0
refactor: add scan_to_stream() to Table trait to postpone the stream generation ( #1639 )
...
* add scan_to_stream to Table
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* impl parquet stream
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* reorganise adapters
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* implement scan_to_stream for mito table
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* clean up
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* add location info
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix: table scan
* UT pass
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* impl project record batch
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix information schema
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix clippy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* resolve CR comments
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* remove one todo
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix errors generated by merge commit
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* add output_ordering method to record batch stream
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* fix rustfmt
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* enhance error types
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
Co-authored-by: Lei, HUANG <mrsatangel@gmail.com >
2023-05-29 20:03:47 +08:00
Weny Xu
0eaae634fa
fix: invalidate table route cache ( #1663 )
2023-05-29 18:49:23 +08:00
Lei, HUANG
78fab08b51
feat: window inferer ( #1648 )
...
* feat: window inferer
* doc: add some doc
* test: add a long missing unit test case for windowed reader
* add more tests
* fix: some CR comments
2023-05-29 14:41:00 +08:00
Yingwen
89366ba939
refactor: Holds histogram in the timer to avoid clone labels if possible ( #1653 )
...
* feat: use Histogram struct to impl Timer
* fix: fix compile errors
* feat: downgrade metrics-process
* fix: compiler errors
2023-05-26 17:12:03 +08:00
Yingwen
c042723fc9
feat: Record process metrics ( #1646 )
...
* feat(servers): Export process metrics
* chore: update metrics related deps to get the process-metrics printed
The latest process-metrics crate depends on metrics 0.21, we use metrics
0.20. This cause the process-metrics crate doesn't record the metrics
when use metrics macros
2023-05-26 11:51:01 +08:00
Ning Sun
332b3677ac
feat: add metrics for ingested row count ( #1645 )
2023-05-26 10:57:27 +08:00
fys
8f9e9686fe
chore: add metrics for table route getting ( #1636 )
...
chore: add metrics for getting table_route
2023-05-25 10:02:59 +08:00
Weny Xu
74a6517bd0
refactor: move the common part of the heartbeat response handler to common ( #1627 )
...
* refactor: move heartbeat response handler to common
* chore: apply suggestions from CR
2023-05-24 07:55:06 +00:00
fys
fa4a497d75
feat: add cache for catalog kv backend ( #1592 )
...
* feat: add kvbackend cache
* fix: cargo fmt
2023-05-24 15:07:29 +08:00
dennis zhuang
7c55783e53
feat!: reorganize the storage layout ( #1609 )
...
* feat: adds data_home to DataOptions
* refactor: split out object store stuffs from datanode instance
* feat: move data_home into FileConfig
* refactor: object storage layers
* feat: adds datanode path to procedure paths
* feat: temp commit
* refactor: clean code
* fix: forgot files
* fix: forgot files
* Update src/common/test-util/src/ports.rs
Co-authored-by: Yingwen <realevenyag@gmail.com >
* Update tests/runner/src/env.rs
Co-authored-by: Yingwen <realevenyag@gmail.com >
* fix: compile error
* chore: cr comments
* fix: dependencies order in cargo
* fix: data path in test
---------
Co-authored-by: Yingwen <realevenyag@gmail.com >
2023-05-23 13:58:26 +08:00
JeremyHi
1225edb065
refactor: move rpc's commons to common-meta ( #1625 )
2023-05-23 10:07:24 +08:00
LFC
f64527da22
feat: region failover procedure ( #1558 )
...
* feat: region failover procedure
2023-05-22 19:54:52 +08:00
Ning Sun
067c5ee7ce
feat: time_zone variable for mysql connections ( #1607 )
...
* feat: add timezone info to query context
* feat: parse mysql compatible time zone string
* feat: add method to timestamp for rendering timezone aware string
* feat: use timezone from session for time string rendering
* refactor: use querycontectref
* feat: implement session/timezone variable read/write
* style: resolve toml format
* test: update tests
* Apply suggestions from code review
Co-authored-by: dennis zhuang <killme2008@gmail.com >
* Update src/session/src/context.rs
Co-authored-by: dennis zhuang <killme2008@gmail.com >
* refactor: address review issues
---------
Co-authored-by: dennis zhuang <killme2008@gmail.com >
2023-05-22 18:30:23 +08:00
Yingwen
32ad358323
fix(table-procedure): Open table in RegisterCatalog state ( #1617 )
...
* fix(table-procedure): on_register_catalog should use open_table
* test: Test recover RegisterCatalog state
* test: Fix subprocedure does not execute in test
* feat(mito): adjust procedure log level
* refactor: rename execute_parent_procedure
execute_parent_procedure -> execute_until_suspended_or_done
2023-05-22 17:54:02 +08:00
Ruihang Xia
e5aad0f607
feat: distributed planner basic ( #1599 )
...
* basic skeleton
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* clean up
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* change QueryEngineState's constructor
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* install extension planner
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
* tidy
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
---------
Signed-off-by: Ruihang Xia <waynestxia@gmail.com >
2023-05-22 11:48:03 +08:00
localhost
a6ec79ee30
chore: add a uniform prefix to the metrics using the official recommendation of ( #1590 )
2023-05-17 11:08:49 +08:00
WU Jingdi
fb1ac0cb9c
feat: support user config manifest compression ( #1579 )
...
* feat: support user config manifest compression
* chore: change style
* chore: enhance test
2023-05-16 11:02:59 +08:00
fys
027707d969
feat: support frontend-meta heartbeat ( #1555 )
...
* feat: support frontend heartbeat
* fix: typo "reponse" -> "response"
* add ut
* enable start heartbeat task
* chore: frontend id is specified by metasrv, not in the frontend startup parameter
* fix typo
* self-cr
* cr
* cr
* cr
* remove unnecessary headers
* use the member id in the header as the node id
2023-05-15 09:54:45 +00:00
LFC
4ae0b5e185
test: move instances tests to "tests-integration" ( #1573 )
...
* test: move standalone and distributed instances tests from "frontend" crate to "tests-integration"
* fix: resolve PR comments
2023-05-15 12:00:43 +08:00
zyy17
4fc173acf0
refactor: support layered configuration ( #1535 )
...
* refactor: add a layered configuration by using config-rs
Signed-off-by: zyy17 <zyylsxm@gmail.com >
* refactor: add 'env_var_prefix' for 'load_options()' and remove duplicate default construction in frontend
* refactor: add test_config_precedence_order in standalone
* refactor: add 'test_config_precedence_order()' test case in metasrv
* refactor: add 'test_config_precedence_order()' test case in datanode
* refactor: refine the naming '*_env_var_*' -> '*_env_vars_*'
* refactor: fix clippy error
* refactor: refine error naming 'LoadConfig' -> 'LoadLayeredConfig' and add Location
* refactor: move 'env_vars_prefix' to clap options
* fix: use '__' as envrionment variables separator and simplify load_layered_options()
* refactor: derive 'Default' for StartCommand and use default function to simplify the test cases
* fix: clippy error
* chore: update comments
* chore(deps): update deps info
* refactor(naming): 'env_vars_prefix' -> 'env_prefix'
* refactor: simplify the code
* refactor: change some argument type of 'load_layered_options()'
* refactor: simplify the code
* refactor: remove unnecessary 'clone()'
* refactor: add 'GREPTIMEDB_*' prefix for env_prefix
* refactor: modify configuration precedence order: cli > config file > environment variables > default values
---------
Signed-off-by: zyy17 <zyylsxm@gmail.com >
2023-05-13 22:37:47 +08:00
LFC
8fef32f8ef
feat: enable tokio console in cluster mode ( #1512 )
...
* feat: enable tokio console subscriber
* fix: resolve PR comments
* fix: resolve PR comments
* fix: resolve PR comments
2023-05-11 14:35:06 +08:00
Weny Xu
44aef6fcbd
feat(datanode): iImplement the heartbeat response handler ( #1547 )
...
* feat(datanode): implement instruction handler
* chore: apply suggestion from CR
* refactor: refactor heartbeat response handler
2023-05-11 09:27:13 +08:00
WU Jingdi
486bb2ee8e
feat: Compress manifest and checkpoint ( #1497 )
...
* feat: Compress manifest and checkpoint
* refactor: use file extention infer compression type
* chore: apply suggestions from CR
* Update src/storage/src/manifest/storage.rs
Co-authored-by: Yingwen <realevenyag@gmail.com >
* chore: CR advices
* chore: Fix bugs, strengthen test
* chore: Fix CR, strengthen test
---------
Co-authored-by: dennis zhuang <killme2008@gmail.com >
Co-authored-by: Yingwen <realevenyag@gmail.com >
2023-05-10 07:53:06 +00:00
Weny Xu
020c55e260
refactor: change mailbox_messages to mailbox_message ( #1557 )
2023-05-10 07:17:11 +00:00