Skip to content
This repository was archived by the owner on Mar 12, 2026. It is now read-only.

refactor: conditionally compile wal impls #1272

Merged
ShiKaiWi merged 17 commits into
apache:mainfrom
tisonkun:cond-wals
Oct 21, 2023
Merged

refactor: conditionally compile wal impls #1272
ShiKaiWi merged 17 commits into
apache:mainfrom
tisonkun:cond-wals

Conversation

@tisonkun

@tisonkun tisonkun commented Oct 19, 2023

Copy link
Copy Markdown
Member

Rationale

Supersede #1231

After compile time with clean -

    Finished dev [unoptimized + debuginfo] target(s) in 2m 18s

Detailed Changes

Conditionally compile wal impls with feature flags.

Test Plan

Code refactor. All existing tests should pass.

Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Signed-off-by: tison <wander4096@gmail.com>
Comment thread analytic_engine/Cargo.toml Outdated
Signed-off-by: tison <wander4096@gmail.com>
@jiacai2050

Copy link
Copy Markdown
Contributor

@tisonkun How big is the final binary?

Current size is 1.3G, which is a pain for distribution.

@tisonkun

Copy link
Copy Markdown
Member Author

@jiacai2050 with make release-slim it gives:

l target/release-slim/ceresdb-server 
-rwxr-xr-x  1 tison  staff    83M Oct 20 15:01 target/release-slim/ceresdb-server

@tisonkun

tisonkun commented Oct 20, 2023

Copy link
Copy Markdown
Member Author

Updated. PTAL again @jiacai2050 @ShiKaiWi

Signed-off-by: tison <wander4096@gmail.com>
@ShiKaiWi

Copy link
Copy Markdown
Member

The default feature should include all the WAL implementations, to avoid any possible confusion about data loss, config not working, etc.

@tisonkun If we turn on all the implementations in the default features, it will be better, and there is no need to update the dockerfile and the ci. 😄

Signed-off-by: tison <wander4096@gmail.com>
@tisonkun

Copy link
Copy Markdown
Member Author

Updated. PTAL again.

BTW, golang related CI failed with a new issue:

server/coordinator/scheduler/static/scheduler.go:6:2: package cmp is not in GOROOT (/opt/hostedtoolcache/go/1.20.10/x64/src/cmp)
note: imported by a module that requires go 1.21
server/coordinator/scheduler/rebalanced/scheduler.go:8:2: package maps is not in GOROOT (/opt/hostedtoolcache/go/1.20.10/x64/src/maps)
note: imported by a module that requires go 1.21
server/coordinator/scheduler/nodepicker/hash/consistent_uniform.go:38:2: package slices is not in GOROOT (/opt/hostedtoolcache/go/1.20.10/x64/src/slices)
note: imported by a module that requires go 1.21
make[1]: *** [Makefile:37: build-meta] Error 1
make[1]: Leaving directory '/home/runner/work/ceresdb/ceresdb/integration_tests'

@tisonkun

Copy link
Copy Markdown
Member Author

Perhaps we should setup go toolchain in the CI env.

@tisonkun

tisonkun commented Oct 21, 2023

Copy link
Copy Markdown
Member Author

CI passed. PTAL @jiacai2050 @ShiKaiWi

@ShiKaiWi ShiKaiWi left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@ShiKaiWi ShiKaiWi merged commit 31c9edf into apache:main Oct 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants