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

Improve error message when metadata block added but Solr schema is not #2665

Closed
pdurbin opened this issue Oct 21, 2015 · 6 comments
Closed

Comments

@pdurbin
Copy link
Member

pdurbin commented Oct 21, 2015

It would be nice to have a more informative error message than this if you load a new metadata block tsv file and forget to update the Solr schema.xml that has the new fields in it:

screen shot 2015-10-21 at 4 25 55 pm

Dataset Save Failed - edu.harvard.iq.dataverse.engine.command.exception.CommandException: Command [DatasetCreate dataset:null] failed: null
The dataset could not be created. Please contact support.

Some of the error also appears in the log:

[2015-10-21T16:23:27.680-0400] [glassfish 4.1] [SEVERE] [] [edu.harvard.iq.dataverse.DatasetPage] [tid: _ThreadID=130 _ThreadName=http-listener-1(5)] [timeMillis: 1445459007680] [levelValue: 1000] [[
Command [DatasetCreate dataset:null] failed: null]]

For now the clue that Solr doesn't know about a new field is in its own log:

2932024941 [qtp918598659-2314] ERROR org.apache.solr.core.SolrCore – org.apache.solr.common.SolrException: ERROR: [doc=dataset_13_draft] unknown field 'hbgdkiStudyName'
at org.apache.solr.update.DocumentBuilder.toDocument(DocumentBuilder.java:174)
at org.apache.solr.update.AddUpdateCommand.getLuceneDocument(AddUpdateCommand.java:77)
at org.apache.solr.update.DirectUpdateHandler2.addDoc(DirectUpdateHandler2.java:215)

@pdurbin pdurbin added the Type: Suggestion an idea label Oct 21, 2015
@mercecrosas mercecrosas modified the milestone: In Review Nov 30, 2015
@scolapasta scolapasta modified the milestone: Not Assigned to a Release Jan 28, 2016
@pdurbin
Copy link
Member Author

pdurbin commented Oct 26, 2016

Here's a case of a user running into this user: https://groups.google.com/d/msg/dataverse-community/KZkD0PvDv8E/KDmwvFMPAgAJ

As I wrote there, the user in this case is probably a sysadmin who is standing up Dataverse for the first time and kicking the tires to see if it even works.

Our number 1 goal at http://dataverse.org/goals-roadmap-and-releases is "increase adoption (users, dataverses, datasets, installations, journals)" and resolving this issue might help lead to more sysadmins getting Dataverse stood up for the first time and showing it to their end users.

@shivadcedtu
Copy link

server.txt

sir, I have updated the schema.xml file but still cant add dataverse into it.
Please help me as I am stuck with this issue.

@pdurbin
Copy link
Member Author

pdurbin commented Oct 28, 2016

@shivadcedtu you must have seen my message at https://groups.google.com/d/msg/dataverse-community/KZkD0PvDv8E/KDmwvFMPAgAJ

When you look at the output of http://localhost:8983/solr/schema/fields (replace "localhost" with the name of your server, as necessary), do you see "dv" stuff like "dvAffiliation", "dvCategory", "dvDescription", etc? Here's a screenshot:

screen shot 2016-10-28 at 8 57 24 am

If you see all that "dv" stuff, your installation of Solr has the Dataverse-specific "schema.xml" file in place, the one I mentioned in that thread and that we explain at http://guides.dataverse.org/en/4.5.1/installation/prerequisites.html#solr . If you don't see all that "dv" stuff, please stop Solr and try again to put the "schema.xml" file in place. I hope the instructions are clear enough but I am very open to suggestions for improvement.

This is a URL we ask developers to check at http://guides.dataverse.org/en/4.5.1/developers/dev-environment.html#installing-and-running-solr

@shivadcedtu
Copy link

hey ,thank you very much.
I could resolve the issue.

@pdurbin
Copy link
Member Author

pdurbin commented Oct 31, 2016

@shivadcedtu fantastic! Thanks for letting us know! If there's something we should add to the Installation Guide, please let us know.

@pdurbin
Copy link
Member Author

pdurbin commented Jun 28, 2017

I guess people are surviving without any special messaging. We always indicate in our release notes when you need to update your Solr schema. Closing.

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

No branches or pull requests

5 participants