-
Notifications
You must be signed in to change notification settings - Fork 1
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
Make sure that landing-page information is present in MMD and that it is a valid url #126
Comments
is something like adding a check for the landing page in full_check (/~https://github.com/metno/discovery-metadata-catalog-ingestor/blob/main/dmci/tools/check_mmd.py#L281) enough? and what is the name of the attribute? I cannot find anything like |
Yes, I think so. Landing page is an MMD "related_information" field with
Example:
The url should be pointing to our production server, or maybe be dynamically created. The latter is maybe best, but then we have to handle this in dmci itself. This could be done based on the environment (dev, staging or production) and the dataset uuid. In this case, we need to add the field to the MMD string before distribution to file, pycsw and solr.
Not sure what you mean, but I think we can only check the url pattern. Anyway, the check is maybe not that important if the landing page field is added by dmci itself. |
|
Yes, it could be done in py-mmd-tools but when I think about it, it may be better in dmci since it is strongly connected to the data site/system which is "known" in the dmci service. @johtoblan - what do you think? In that case, we can close metno/py-mmd-tools#225.
Ok, then that may be enough. |
Discussed in review meeting now. We add data.met.no in the MMD files. This can be changed in dmci to adjust for dev and staging envs. |
Update: the landing page should be set by dmci for all envs (dev, staging and prod), since this is the entry point for the data management service. See metno/py-mmd-tools#225 |
should this happen only for |
It should be only the insert/create and possibly the update cases. |
So you use validate, get a Everything is ok, and then it fails on update/insert? |
mmh I do not fully understand how |
Why should it fail on update/insert? |
It needs to be in the right place in the MMD because of how the xsd is defined. Check
I think you'll need to replace it if it's already there, or check and replace if it is incorrect. |
If we add validation to the update/insert that is not present in validate |
But that shouldn't be a problem as long as we know the internal functionality is correct? We can make sure it works using unit tests..? |
you mean for reference, I was assuming at the end like
|
/~https://github.com/metno/mmd/blob/master/xsd/mmd_strict.xsd |
The host url for the landingpages should also change with respect to environments. Now new precessed mmd-files sendt to mmd-xml-dev, still have https://data.met.no/dataset/ |
yeah, that will be read from the config |
@magnarem - should we also change the |
as far as I understand the order in a xsd template matters only inside of the |
I'm not sure what you should do but you can make a unit test which checks the final MMD against |
does this mean that we assume a new entry in the config? e.g.
? |
@charlienegri - I suggest changing the config vars to something more explicit, e.g.,
to
"overrides" means that we will override the content of the input MMD file.. What do you think? |
sure @mortenwh, fine by me, the idea of having something |
but anyway I'll change from |
Sounds good! In case others want to use dmci, I guess the full namespace (e.g., |
No description provided.
The text was updated successfully, but these errors were encountered: