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

Refactor AbstractDBBuilder hierarchy and check if targetDbFile needs to be explicitly set as writable #1399

Open
marekhorst opened this issue May 12, 2023 · 0 comments

Comments

@marekhorst
Copy link
Member

marekhorst commented May 12, 2023

It looks like all implementations of AbstractDBBuilder#initializeProcess() in the following subclasses:

  • CommunityDBBuilder
  • DatasetDBBuilder
  • ServiceDBBuilder
  • PatentDBBuilder
  • ProjectDBBuilder
  • ResearchInitiativeDBBuilder
  • SoftwareHeritageOriginDBBuilder

are quite similar and it should be possible to refactor it and put most of the code in a shared method.

We should also check if targetDbFile.setWritable(true); is really needed and justified since it doesn't work for non-existing files. We should check if it is possible this file could be already created e.g. by previous execution of this process on the same datanode. This was referenced in #1398 (comment) as a part of CR process.

@marekhorst marekhorst changed the title Refactor AbstractDBBuilder hierarchy and check if targetDbFile needs to be explicitly set as writeable Refactor AbstractDBBuilder hierarchy and check if targetDbFile needs to be explicitly set as writable May 12, 2023
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

No branches or pull requests

1 participant