You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We can run following command to reindex a package ckan search-index rebuild [dataset_name]
When running the command on a Catalog harvest source, it generates an SearchIndexError, then the harvest source disappears from the UI.
How to reproduce
Create a data.json harvest source named, e.g. test-json-source, in a test organization on Catalog ( replicated on sandbox and staging)
Run a harvest job
SSH into harvester instance, run the command ckan search-index rebuild test-json-source
Expected behavior
Command runs successfully.
Actual behavior
It generates a SearchIndexError.
Harvest source test-json-source is removed from its organization.
Solr responded with an error (HTTP 400): [Reason: Error parsing JSON field value.
Unexpected OBJECT_START at [3098], field=status]
The text was updated successfully, but these errors were encountered:
The cause of this issue is a bug found in pysolr. It only happens to harvest source that contains at least one harvest job run, making the pkg_dict sent to solr a multi-level nested JSON object.
For the fresh harvest source with 0 harvest job, the last_job is None, we don't see this issue. It only happens to catalog.data.gov fcs branch where we upgraded pysolr version from CKAN default 3.6.0 to 3.9.0 for performance reason.
Since rebuild command is actually delete and add again, the record is deleted from solr index and not added back, the harvest source disappears from the UI.
We can run following command to reindex a package
ckan search-index rebuild [dataset_name]
When running the command on a Catalog harvest source, it generates an SearchIndexError, then the harvest source disappears from the UI.
How to reproduce
test-json-source
, in a test organization on Catalog ( replicated on sandbox and staging)ckan search-index rebuild test-json-source
Expected behavior
Command runs successfully.
Actual behavior
It generates a SearchIndexError.
Harvest source
test-json-source
is removed from its organization.The text was updated successfully, but these errors were encountered: