Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: improve onebox work dirs #1899

Merged
merged 4 commits into from
May 28, 2022
Merged

fix: improve onebox work dirs #1899

merged 4 commits into from
May 28, 2022

Conversation

auula
Copy link
Contributor

@auula auula commented May 27, 2022

  • What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
  1. fix scripts: improve onebox script #1328
  • What is the current behavior? (You can also link to an open issue here)
  1. The log output by the onebox script is not in the unified directory.
  • What is the new behavior (if this is a feature change)?
  1. The subdirectory can be set through the environment variable ONEBOX_WORKDIR.
  2. Log unified directory.


IP=127.0.0.1

# work unified file directory
if [ ! -n "$workspace" ]; then
Copy link
Collaborator

Choose a reason for hiding this comment

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

pls resolve shellcheck errors


IP=127.0.0.1

# work unified file directory
if [ ! -n "$workspace" ]; then
Copy link
Collaborator

Choose a reason for hiding this comment

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

I recommend workspace default to a subdirectory inside onebox/

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I recommend workspace default to a subdirectory inside onebox/
review code :760ff33

# default work directory
workspace="workspace"
rm -rf $workspace/logs/
mkdir -p $workspace/logs
Copy link
Collaborator

Choose a reason for hiding this comment

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

should mkdir for other workspace too

Copy link
Contributor Author

Choose a reason for hiding this comment

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

should mkdir for other workspace too

review code :760ff33

@codecov
Copy link

codecov bot commented May 27, 2022

Codecov Report

Merging #1899 (c547f44) into main (555077f) will increase coverage by 0.03%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##               main    #1899      +/-   ##
============================================
+ Coverage     75.69%   75.72%   +0.03%     
  Complexity      347      347              
============================================
  Files           613      613              
  Lines        117018   117018              
  Branches       1024     1024              
============================================
+ Hits          88574    88616      +42     
+ Misses        28235    28193      -42     
  Partials        209      209              
Impacted Files Coverage Δ
src/catalog/tablet_catalog.cc 72.91% <0.00%> (-1.73%) ⬇️
src/replica/replicate_node.cc 76.53% <0.00%> (-1.68%) ⬇️
src/zk/dist_lock.cc 81.81% <0.00%> (-1.52%) ⬇️
src/client/tablet_client.cc 55.11% <0.00%> (-0.23%) ⬇️
src/sdk/sql_cluster_router.cc 54.84% <0.00%> (-0.13%) ⬇️
src/log/log_reader.cc 79.11% <0.00%> (ø)
src/nameserver/name_server_impl.cc 42.86% <0.00%> (+0.12%) ⬆️
hybridse/src/codec/fe_row_codec.cc 78.49% <0.00%> (+0.15%) ⬆️
src/zk/zk_client.cc 83.55% <0.00%> (+0.26%) ⬆️
src/tablet/tablet_impl.cc 59.49% <0.00%> (+0.32%) ⬆️
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 555077f...c547f44. Read the comment docs.

@vagetablechicken vagetablechicken changed the title add: onebox work unified file directory. fix: improve onebox work dirs May 27, 2022
@github-actions
Copy link
Contributor

github-actions bot commented May 27, 2022

SDK Test Report

  75 files    75 suites   7m 8s ⏱️
163 tests 161 ✔️ 2 💤 0
204 runs  202 ✔️ 2 💤 0

Results for commit c547f44.

♻️ This comment has been updated with latest results.

rm -rf logs/
mkdir -p logs
# rm -rf logs/
# mkdir -p logs
Copy link
Collaborator

Choose a reason for hiding this comment

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

remove the comments, line 22-23

Copy link
Contributor Author

Choose a reason for hiding this comment

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

remove the comments, line 22-23

remove comments: c547f44

# mkdir -p logs

# The subdirectory can be set through the environment variable ONEBOX_WORK
workspace=$ONEBOX_WORK
Copy link
Collaborator

Choose a reason for hiding this comment

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

You can use WORKSPACE=${ONEBOX_WORKDIR:-onebox/workspace}
No need to do if ! -n "$workspace"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You can use WORKSPACE=${ONEBOX_WORKDIR:-onebox/workspace} No need to do if ! -n "$workspace"

review code :760ff33

@github-actions
Copy link
Contributor

github-actions bot commented May 27, 2022

Linux Test Report

       57 files       187 suites   1h 1m 3s ⏱️
  8 503 tests   8 499 ✔️ 4 💤 0
12 489 runs  12 485 ✔️ 4 💤 0

Results for commit c547f44.

♻️ This comment has been updated with latest results.

@aceforeverd aceforeverd enabled auto-merge (squash) May 28, 2022 08:10
@aceforeverd aceforeverd disabled auto-merge May 28, 2022 08:10
@aceforeverd aceforeverd merged commit 2229a68 into 4paradigm:main May 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

scripts: improve onebox script
3 participants