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

externalize files information to different file #46

Open
Ginxo opened this issue Nov 17, 2022 · 2 comments
Open

externalize files information to different file #46

Ginxo opened this issue Nov 17, 2022 · 2 comments

Comments

@Ginxo
Copy link
Collaborator

Ginxo commented Nov 17, 2022

caused by: #44

after #44 the data/latest.json file has increased size, I recommend to externalize files object to different file (something like files-latest.json and the one by date).
The get files-latest.json mechanism will be perform once latest data is already loaded, just consider branch comparison as a secondary functionallity

I would recommend to solve this issue before #29

@lampajr
Copy link
Member

lampajr commented Nov 17, 2022

I propose to generate a new file files-latest.json having a structure like this one:

{
  "metadata": {
    ...
  },
  "branchesComparison": {
    "7.67.x": {
      "main": {
        "owner/project1": ["sha11", "sha12"],
        "owner/project2": ["sha21", "sha22"],
        ...
      },
      "7.67.x-blue": {
        "owner/project1": ["sha13", "sha14"],
        "owner/project2": ["sha23", "sha24"],
        ...
      }
    },
    "7.67.x-blue": {
      "main": {
        "owner/project1": ["sha15", "sha16"],
        "owner/project2": ["sha25", "sha26"],
        ...
      },
      "7.67.x": {
        "owner/project1": ["sha13", "sha14"],
        "owner/project2": ["sha23", "sha24"],
        ...
      }
    },
    ...
  },
  "files": {
    "sha11": {
      "filename": "",
      "blob_url": "",
      "content_url": ""
    },
    "sha12": {
      "filename": "",
      "blob_url": "",
      "content_url": ""
    },
    ...
  }
}
  • metadata: contains additional information, if needed.
  • files: contains files information, like its name. Files are uniquely identified by their sha.
  • branchesComparison: provide all project's different files given base and head branches to compare. The tree structure is accessible starting from the branches itself.

@Ginxo wdyt?

@Ginxo
Copy link
Collaborator Author

Ginxo commented Nov 17, 2022

thanks @lampajr

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

2 participants