-
Notifications
You must be signed in to change notification settings - Fork 2
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
Generate changelog between 2 repo versions #1814
Comments
Updated changelog approach based on discussion with Andy and the OpenMRS squad: For all concepts in one of the repo version(s), changes to mappings should be grouped together as concept changes (using mapping.from_concept). Only if mapping.from_concept is not a member of one of the repo versions should it be separated out into the Mapping Change Log. Note: This approach means that the change log may need to retrieve concept summaries for concepts that did not change, because their mappings changed. Concept Change Log (includes all concept changes plus mapping changes to any concepts in one of the repos, e.g. mapping.from_concept == concept.id)
Mapping Change Log (where mapping.from_concept is not associated with a concept in the repos)
|
@snyaggarwal This is ready for your review |
|
Note: The current diff/changelog approach is applicable to source-based repo types (source, code system, concept map). It does not yet cover collection-based repo-types (e.g. collection, value set, dictionary with linked source). Until then, a diff or changelog for a collection-based repo type will only look at concepts and mappings, not references/expansions. |
…nly mappings changes
|
Version Diff APIs:
Request
Response
Request
Response
Request
Response
Version Changelog APIs:
Request
Response
Request
Response
|
@paynejd this is deployed on QA |
@paynejd This is also on Staging |
Changelog Fixes
Proposed changes to the diff output
{
"meta": {
"version1": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-05-01/",
"concepts": 55037,
"mappings": 231154
},
"version2": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-03-14/",
"concepts": 54904,
"mappings": 230711
}
},
"concepts": {
"new": 133,
"removed": 0,
"changed-total": 24,
"changed-retired": 3,
"changed-major": 19,
"changed-minor": 2
},
"mappings": {
"new": 450,
"removed": 0,
"changed-total": 7,
"changed-retired": 7,
"changed-major": 0,
"changed-minor": 0
}
} Proposed changelog outputUse the same structure as the diff with 2 exceptions:
{
"meta": {
"version1": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-05-01/",
"concepts": 55037,
"mappings": 231154
},
"version2": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-03-14/",
"concepts": 54904,
"mappings": 230711
},
"diff": {
"concepts": {
"new": 133,
"removed": 0,
"changed-total": 24,
"changed-retired": 3,
"changed-major": 19,
"changed-minor": 2
},
"mappings": {
"new": 450,
"removed": 0,
"changed-total": 7,
"changed-retired": 7,
"changed-major": 0,
"changed-minor": 0
}
},
"concepts": {
"new": {},
"removed": {},
"changed-retired": {},
"changed-major": {},
"changed-minor": {},
"changed-mappings-only": {}
},
"mappings": {
"new": {},
"removed": {},
"changed-retired": {},
"changed-major": {},
"changed-minor": {}
}
} Questions
|
…added diff with verbosity
@paynejd These changes are deployed on QA/Staging |
@paynejd Updated changelog with diff https://json.link/NTyBdEbTWa.json |
…toring and added tests
Definitions
Example: {
"meta": {
"version1": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-05-01/",
"concepts": 55037,
"mappings": 231154
},
"version2": {
"uri": "/orgs/CIEL/sources/CIEL/v2024-03-14/",
"concepts": 54904,
"mappings": 230711
},
"diff": {
"concepts": {
"new": 133,
"removed": 0,
"changed_total": 21,
"changed_retired": 0,
"changed_major": 19,
"changed_minor": 2
},
"mappings": {
"new": 450,
"removed": 0,
"changed_total": 7,
"changed_retired": 7,
"changed_major": 0,
"changed_minor": 0
}
}
},
"concepts": {
"new": [],
"changed_major": [],
"changed_minor": []
},
"mappings":{
} |
@paynejd This is deployed everywhere. Anything else should be recorded on new ticket, closing this |
We want OCL to be able to use the results of OCL's
compare
operation to generate a change log between 2 versions of a repo. Here is a proposal for an MVP that closely matches ourThis version of a change log matches the structure of the
compare
output, with the hope that it is straightforward to generate. It does not, however, provide a diff analysis that groups a concept with its mappings. But this still could be a great place to start.smart changed
): list ID, display name, update_comment, changesstandard changed
): list ID, display name, update_comment, changesExpected output:
Resources:
The text was updated successfully, but these errors were encountered: