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

RequestError in adding a new object to collection #268

Closed
pkikawa opened this issue Nov 26, 2019 · 6 comments
Closed

RequestError in adding a new object to collection #268

pkikawa opened this issue Nov 26, 2019 · 6 comments
Assignees

Comments

@pkikawa
Copy link
Collaborator

pkikawa commented Nov 26, 2019

RequestError at ui_entity_ddr-testing-40300_new-idservice.zip

master 4.0.0

clicked add object in ddr-testing-40300 a known good testing collection

Entiat workstation

@gjost
Copy link
Member

gjost commented Nov 26, 2019

When you save objects the editor tries to index them with the local Elasticsearch. I think the error is because the new Elasticsearch7 code is trying to interact with an old Elasticsearch2.* server.

The solution is to edit /etc/ddr/ddrlocal-local.cfg and change [local] docstore_host to point to an Elasticsearch7 server.

@gjost
Copy link
Member

gjost commented Nov 27, 2019

See #269

This happens when using the current DDR with an old Elasticsearch server e.g. 2.4. I can't fix having the wrong server but ddr-local commit 9d16e3d for package ddrlocal-rc_4.0.0-rc3~deb9 should catch the RequestErrors so the program doesn't crash. Records in the local Elasticsearch will not be updated of course.

@gjost gjost added the fixed label Nov 27, 2019
@pkikawa
Copy link
Collaborator Author

pkikawa commented Dec 2, 2019

error in adding objects to collection
Error: {'error': RequestError(400, u'invalid_type_name_exception', {u'status': 400, u'error': {u'root_cause': [{u'reason': u"Document mapping type name can't start with ''", u'type': u'invalid_type_name_exception'}], u'type': u'invalid_type_name_exception', u'reason': u"Document mapping type name can't start with ''"}})}

@pkikawa pkikawa removed the fixed label Dec 2, 2019
@sarabeckman
Copy link
Collaborator

Error in adding objects to collection
RequestError(400, u'invalid_type_name_exception', {u'status': 400, u'error': {u'root_cause': [{u'reason': u"Document mapping type name can't start with ''", u'type': u'invalid_type_name_exception'}], u'type': u'invalid_type_name_exception', u'reason': u"Document mapping type name can't start with ''"}}) is not JSON serializable

I'm getting a full page Error not just in the git status messages. After getting the full page error I can't load any other page in Editor UI. I get the page RequestError400 when trying to load any page in Editor. (Main Editor UI page, collection list page)

@pkikawa
Copy link
Collaborator Author

pkikawa commented Dec 2, 2019

rc3 for both me and sara

@gjost
Copy link
Member

gjost commented Dec 2, 2019

I set up a fresh Debian 9 VM, installed ddrlocal-rc_4.0.0-rc3~deb9_amd64.deb on it, pointed it at another VM that's running Elasticsearch 7, and was able to successfully create and edit entities, segments, and files.
NOTE: DDR no longer works with Elasticsearch 2.4
NOTE: You need to set up an Elasticsearch 7.4 server, then edit /etc/ddr/ddrlocal-local.cfg on the VM, setting [local] docstore_host to point to the new ES7.

@gjost gjost added the fixed label Dec 2, 2019
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

4 participants