Updated file loading so that embedded directories are supported. #420
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this pull request do?
Enables loading RDF files from sub-directories, so that .n3 template refactoring can be implemented by using packages. Loading subdirectories only works in the case of everytime files, so that file graph loading won't be affected (they are implemented with different loading logic in mind).
What's new?
Changed RDFFilesLoader class (getPaths method) so that it supports loading files from sub-directories using visitor pattern. As mentioned above, this loading method only works if the loading directory is named "everytime", indicating that it contains dynapi .n3 templates.
How should this be tested?
Startup VIVO dynapi. You should include some .n3 templates that are split in (ideally with hierarchy > 1) packages, you can find few examples here. After startup, RDF files from sub-directories should be loaded and all functionality should be available to you whether through swagger documentation or some client mocking tool (eg. Postman, cURL...).
Interested parties
@litvinovg @chenejac @brianjlowe