Skip to content
This repository has been archived by the owner on Aug 5, 2021. It is now read-only.

Support list of external JSON inventory files #408

Open
jordangov opened this issue Jan 17, 2018 · 2 comments
Open

Support list of external JSON inventory files #408

jordangov opened this issue Jan 17, 2018 · 2 comments

Comments

@jordangov
Copy link

Expected Behavior

I would like to be able to list external JSON files that other groups within my agency are maintaining so that the central office maintaining the primary JSON inventory file does not need to maintain all listed project releases.This would distribute the load of maintaining the inventory across an agency while still allowing the code.gov team to maintain a singular reference for inventory culling.

Current Behavior

Currently, all release information must be included in a single JSON file for an entire agency. However, some agencies have a significantly large number of sub-orgs and OSS projects that this becomes quite arduous to maintain.

Possible Solution

I would suggest that the schema support a list (array) of external inventory files to be included in the primary file. For example, an agency might define something like:

{
  externalReleases: [
    "https://someorg.gov/code.json",
    "https://anotherorg.gov/code.json",
    "https://onemorething.gov/code.json"
  ]
}

The code.gov site would need to grab the "primary" JSON file first from the identified agency primary URL/code.json file, then grab any referenced external releases and merge those releases into the primary file.

@DanielJDufour
Copy link
Contributor

@jordangov , thanks for the insightful point. We'll discuss this next time we have a major schema upgrade, which could be a while.

@DanielJDufour
Copy link
Contributor

In the interim, if you're looking at writing a script, I really like using node-fetch in JavaScript and requests in Python. Let me know if I can be of any further assistance.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants