Skip to content

[resolve] Add cache mode - #5304

Closed
pkriens wants to merge 2 commits into
bndtools:masterfrom
pkriens:master
Closed

pkriens wants to merge 2 commits into
bndtools:masterfrom
pkriens:master

Conversation

@pkriens

@pkriens pkriens commented Jun 30, 2022

Copy link
Copy Markdown
Member

cache – Will use a cache file in the workspace cache. If that file is stale relative to the workspace or project or it does not exist, then the bnd(run) file will be resolved and the result is stored in the cache file.

Signed-off-by: Peter Kriens [email protected]

cache – Will use a cache file in the workspace cache. If that file is stale relative to the workspace or project or it does not exist, then the bnd(run) file will be resolved and the result is stored in the cache file.




Signed-off-by: Peter Kriens <[email protected]>

@bjhargrave bjhargrave 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.

Some comments/questions.

}

private Collection<Container> cache() throws Exception {
File ours = getPropertiesFile();

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.

What about included files in the bndrun file and in the workspace?

In the gradle plugin all of the files factor in to out-of-date checks:

private ConfigurableFileCollection bndConfiguration() {
Workspace bndWorkspace = bndProject.getWorkspace();
return objects.fileCollection()
.from(bndWorkspace.getPropertiesFile(), bndWorkspace.getIncluded(), bndProject.getPropertiesFile(),
bndProject.getIncluded());
}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

makes sense

Comment thread biz.aQute.resolve/src/biz/aQute/resolve/Bndrun.java Outdated
Comment thread biz.aQute.resolve/src/biz/aQute/resolve/Bndrun.java Outdated
- Uses the project/workspace lastmodifiedtime, which includes include files
- Removed removal of container errors in test, uses a resolve file that has proper dependencies
- Added a testReason so the caching choice could be tested from outside
- Increased test coverage

Signed-off-by: Peter Kriens <[email protected]>
@pkriens pkriens mentioned this pull request Jul 1, 2022
@bjhargrave

Copy link
Copy Markdown
Member

I guess we can close this PR since you merged #5305.

@bjhargrave bjhargrave closed this Jul 1, 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.

2 participants