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

builder: split out builder into a dedicated crate #1321

Merged
merged 1 commit into from
Jun 16, 2023

Conversation

jiangliu
Copy link
Collaborator

@jiangliu jiangliu commented Jun 15, 2023

Split out builder into a dedicate nydus-builder crate, to reduce dependencies of the nydus-rafs crate.

Relevant Issue (if applicable)

If there are Issues related to this PullRequest, please list it.

Details

Please describe the details of PullRequest.

Types of changes

What types of changes does your PullRequest introduce? Put an x in all the boxes that apply:

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update (if none of the other choices apply)

Checklist

Go over all the following points, and put an x in all the boxes that apply.

  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.

@jiangliu jiangliu requested a review from a team as a code owner June 15, 2023 15:52
@jiangliu jiangliu requested review from bergwolf, imeoer and luodw and removed request for a team June 15, 2023 15:52
@anolis-bot
Copy link
Collaborator

@jiangliu , a new test job has been submitted. Please wait in patience. The test job url: https://tone.openanolis.cn/ws/nrh4nnio/test_result/78692

@anolis-bot
Copy link
Collaborator

@jiangliu , the title has been updated, so a new test job has been submitted. Please wait in patience. The test job url: https://tone.openanolis.cn/ws/nrh4nnio/test_result/78693

@codecov
Copy link

codecov bot commented Jun 15, 2023

Codecov Report

Merging #1321 (75f1d0e) into master (3ab3a75) will increase coverage by 0.00%.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1321   +/-   ##
=======================================
  Coverage   45.67%   45.68%           
=======================================
  Files         123      123           
  Lines       37254    37255    +1     
  Branches    37254    37255    +1     
=======================================
+ Hits        17017    17020    +3     
+ Misses      19338    19337    -1     
+ Partials      899      898    -1     
Impacted Files Coverage Δ
builder/src/compact.rs 0.00% <ø> (ø)
builder/src/core/blob.rs 14.08% <ø> (ø)
builder/src/core/bootstrap.rs 72.84% <ø> (ø)
builder/src/core/chunk_dict.rs 65.24% <ø> (ø)
builder/src/core/context.rs 44.18% <ø> (ø)
builder/src/core/feature.rs 87.23% <ø> (ø)
builder/src/core/layout.rs 0.00% <ø> (ø)
builder/src/core/node.rs 41.95% <ø> (ø)
builder/src/core/overlay.rs 0.00% <ø> (ø)
builder/src/core/prefetch.rs 43.82% <ø> (ø)
... and 12 more

... and 2 files with indirect coverage changes

@anolis-bot
Copy link
Collaborator

@jiangliu , The CI test is completed, please check result:

Test CaseTest Result
build rust golang image✅ SUCCESS
compile nydusd✅ SUCCESS
compile ctr remote✅ SUCCESS
compile nydus snapshotter✅ SUCCESS
run container with rafs✅ SUCCESS
run container with zran✅ SUCCESS
run container with rafs and compile linux✅ SUCCESS

Congratulations, your test job passed!

@anolis-bot
Copy link
Collaborator

@jiangliu , The CI test is completed, please check result:

Test CaseTest Result
build rust golang image✅ SUCCESS
compile nydusd✅ SUCCESS
compile ctr remote✅ SUCCESS
compile nydus snapshotter✅ SUCCESS
run container with rafs✅ SUCCESS
run container with zran✅ SUCCESS
run container with rafs and compile linux✅ SUCCESS

Congratulations, your test job passed!

@bergwolf
Copy link
Member

Why is this a breaking change :)

@jiangliu
Copy link
Collaborator Author

Why is this a breaking change :)

This PR introduces new crates, so existing code may fail to compile, so marked as "breaking changes".
It doesn't mean incompatibility,

#assert_matches = "1.5.0"

[features]
#fusedev = ["fuse-backend-rs/fusedev"]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is it necessary to keep it?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

They should be removed:)

Split out builder into a dedicate nydus-builder crate, to reduce
dependencies of the nydus-rafs crate.

Signed-off-by: Jiang Liu <gerry@linux.alibaba.com>
@anolis-bot
Copy link
Collaborator

@jiangliu , the code has been updated, so a new test job has been submitted. Please wait in patience. The test job url: https://tone.openanolis.cn/ws/nrh4nnio/test_result/78716

@anolis-bot
Copy link
Collaborator

@jiangliu , The CI test is completed, please check result:

Test CaseTest Result
build rust golang image✅ SUCCESS
compile nydusd✅ SUCCESS
compile ctr remote✅ SUCCESS
compile nydus snapshotter✅ SUCCESS
run container with rafs✅ SUCCESS
run container with zran✅ SUCCESS
run container with rafs and compile linux✅ SUCCESS

Congratulations, your test job passed!

@@ -0,0 +1,50 @@
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this file specially added?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The builder has a ut case, which uses this file, though it's ignored currently.

   #[ignore]
    #[test]
    fn test_build_stargz_toc() {
        let tmp_dir = vmm_sys_util::tempdir::TempDir::new().unwrap();
        let tmp_dir = tmp_dir.as_path().to_path_buf();
        let root_dir = &std::env::var("CARGO_MANIFEST_DIR").expect("$CARGO_MANIFEST_DIR");
        let source_path =
            PathBuf::from(root_dir).join("../tests/texture/stargz/estargz_sample.json");

@imeoer imeoer merged commit cce78d4 into dragonflyoss:master Jun 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants