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

Use schema from schemaLocation URL #72

Merged
merged 4 commits into from
Dec 9, 2021
Merged

Use schema from schemaLocation URL #72

merged 4 commits into from
Dec 9, 2021

Conversation

tdddblog
Copy link
Contributor

@tdddblog tdddblog commented Dec 9, 2021

🗒️ Summary

Use schema from schemaLocation URL
(See NASA-PDS/registry-mgr#31)

⚙️ Test Instructions

  • Delete old registry. Create new registry. (Use the latest version of registry-manager on schema branch)
  • Run harvest with the following data file (mvn_swe_l2_arc3d_20210102_v04_r03.zip)
  • Output folder should have missing_fields.txt and missing_xsds.txt files.

♻️ Related Issues

NASA-PDS/registry-mgr#31
NASA-PDS/registry-mgr#39

public Set<String> parse(HttpEntity entity) throws IOException
{
InputStream is = entity.getContent();
rd = new JsonReader(new InputStreamReader(is));
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DefaultCharset: Implicit use of the platform default charset, which can result in differing behaviour between JVM executions or incorrect behavior if the encoding of the data source doesn't match expectations. (details)
(at-me in a reply with help or ignore)

protected void saveMissingXsds() throws IOException
{
File file = new File(outDir, "missing_xsds.txt");
FileWriter wr = new FileWriter(file);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DefaultCharset: Implicit use of the platform default charset, which can result in differing behaviour between JVM executions or incorrect behavior if the encoding of the data source doesn't match expectations. (details)
(at-me in a reply with help or ignore)

*/
public class SchemaDao
{
private Logger log;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UnusedVariable: The field 'log' is never read. (details)
(at-me in a reply with help or ignore)

@tloubrieu-jpl
Copy link
Member

Hi @tdddblog , I am testing the schema pull requests and I am having a message with harvest, missing harvest/registry. I am guessing I should have in my configuration the url of the elasticsearch. How should that be done ? Thanks

Copy link
Member

@tloubrieu-jpl tloubrieu-jpl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That works, thanks Eugene

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

Successfully merging this pull request may close these issues.

3 participants