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

MDTranslator ISO19115-2 to DCATUS: Language #4888

Open
1 task
Jin-Sun-tts opened this issue Sep 16, 2024 · 4 comments
Open
1 task

MDTranslator ISO19115-2 to DCATUS: Language #4888

Jin-Sun-tts opened this issue Sep 16, 2024 · 4 comments
Assignees
Labels
H2.0/Harvest-Transform Transform Logic for Harvesting 2.0

Comments

@Jin-Sun-tts
Copy link
Contributor

Jin-Sun-tts commented Sep 16, 2024

User Story

In order to transform ISO19115-2 documents into DCATUS using mdtranslator, datagov wants to add processing for Language

Acceptance Criteria

  • GIVEN the DCATUS Language field
    AND how the DCATUS writer expects to find the data within the internal metadata object
    WHEN the associated ISO19115-2 reader ruby modules are created
    THEN Language should be transformed from ISO19115-2 to DCATUS

Background

  • related to #4862
  • We process 291017 ISO19115-2 datasets. We want all our datasets to be in DCATUS.
  • This reader is not intended to be feature complete according to the ISO19115-2 standard. All we're looking to read is as much as the DCATUS writer expects.
  • ISO19115-3 development workflow

Security Considerations (required)

None

Sketch

  • field mapping relationship ISO19115-2 -> MDJSON -> DCATUS
    • .//gmd:MD_DataIdentification//gmd:resourceConstraints//gmd:MD_Constraints//gmd:useLimitation
    • intObj[:metadata][:metadataInfo][:defaultMetadataLocale][:languageCode] + [:otherMetadataLocales][:languageCode]
    • language
  • add processing in resourceInfo to read keywords from gmd:MD_DataIdentification
  • create a transformation test demonstrating how the value went from the ISO19115-2 document into the DCATUS json
  • create a response object message test verifying when required elements are missing
@Jin-Sun-tts Jin-Sun-tts added the H2.0/Harvest-Transform Transform Logic for Harvesting 2.0 label Sep 16, 2024
@Jin-Sun-tts Jin-Sun-tts self-assigned this Sep 16, 2024
@Jin-Sun-tts
Copy link
Contributor Author

dcatus writer looking for[:metadata][:metadataInfo][:defaultMetadataLocale][:languageCode]and optional [:otherMetadataLocales][:languageCode]

ISO19115-2 doesn't include default and other metadata locales:

<gmi:MI_Metadata
  <gmd:locale>
    <gmd:PT_Locale>
      <gmd:languageCode>
        <gmd:LanguageCode 

need suggestions on how to mapping this situation.

@btylerburton
Copy link
Contributor

would setting a default in dcat-us writer be the way to go, @rshewitt?

@rshewitt
Copy link
Contributor

rshewitt commented Sep 18, 2024

@btylerburton iso19115-3 has 2 kinds of locales: mdb:defaultLocale and mdb:otherLocale. iso19115-2 appears to only have 1 type of locale: gmd:locale. one path forward is to use the first locale as the default and the remaining ones as others. this would bypass editing the dcat-us language module and instead be handled within module_locale of the iso19115-2 reader. frankly, i don't feel confident enough to run with that decision so we should bounce it off of chris

@FuhuXia
Copy link
Member

FuhuXia commented Sep 19, 2024

looking at XML we have on catalog, it is predominately

<gmi:MI_Metadata>
    <gmd:language>
    <gco:CharacterString>eng</gco:CharacterString>
    </gmd:language>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
H2.0/Harvest-Transform Transform Logic for Harvesting 2.0
Projects
Status: 📡 Blocked
Development

No branches or pull requests

4 participants