Elasticsearch indexing not working with Zincsearch #543

Closed
opened 2023-05-20 16:36:18 +00:00 by Kris · 5 comments

I am trying to get the Elastic search support working with Zincsearch (a mostly API compatible but fully FOSS alternative, see: https://github.com/zincsearch/zincsearch ).

So far everything looks good, but when I do the final step of the process:

mix pleroma.search import activities

I get the following error:

** (ArgumentError) errors were found at the given arguments:

  * 1st argument: the table identifier does not refer to an existing ETS table

    (stdlib 4.3) :ets.lookup(Pleroma.Search.Elasticsearch.Cluster.Config, :config)
    (elasticsearch 1.0.1) lib/elasticsearch/cluster/cluster.ex:218: Elasticsearch.Cluster.read_config/1
    (elasticsearch 1.0.1) lib/elasticsearch/indexing/bulk.ex:99: Elasticsearch.Index.Bulk.upload/4
    (mix 1.14.3) lib/mix/task.ex:421: anonymous fn/3 in Mix.Task.run_task/4
    (mix 1.14.3) lib/mix/cli.ex:84: Mix.CLI.run_task/2

Which sadly doesn't help me at all in understanding better what the cause might be.

This might very well be a Zincsearch API issue, but without any idea what the cause might be I can't really open an issue upstream. Other Elasticsearch integrations like the one from Gitea seem to work fine with Zinc, so in general the API is pretty compatible.

Thanks for the help.

Edit: I am running Akkoma in a Docker container.

I am trying to get the Elastic search support working with Zincsearch (a mostly API compatible but fully FOSS alternative, see: https://github.com/zincsearch/zincsearch ). So far everything looks good, but when I do the final step of the process: `mix pleroma.search import activities` I get the following error: ``` ** (ArgumentError) errors were found at the given arguments: * 1st argument: the table identifier does not refer to an existing ETS table (stdlib 4.3) :ets.lookup(Pleroma.Search.Elasticsearch.Cluster.Config, :config) (elasticsearch 1.0.1) lib/elasticsearch/cluster/cluster.ex:218: Elasticsearch.Cluster.read_config/1 (elasticsearch 1.0.1) lib/elasticsearch/indexing/bulk.ex:99: Elasticsearch.Index.Bulk.upload/4 (mix 1.14.3) lib/mix/task.ex:421: anonymous fn/3 in Mix.Task.run_task/4 (mix 1.14.3) lib/mix/cli.ex:84: Mix.CLI.run_task/2 ``` Which sadly doesn't help me at all in understanding better what the cause might be. This might very well be a Zincsearch API issue, but without any idea what the cause might be I can't really open an issue upstream. Other Elasticsearch integrations like the one from Gitea seem to work fine with Zinc, so in general the API is pretty compatible. Thanks for the help. Edit: I am running Akkoma in a Docker container.

for the record, this should not have been an issue, support for "zincsearch" has never been mentioned

if you are doing things outside the bounds of supported functionality, you will be largely on your own when it comes to debugging, no more in-depth support will be forthcoming

that said, to quote the documentation

To use elasticsearch, set the search module to Pleroma.Search.Elasticsearch:

    config :pleroma, Pleroma.Search, module: Pleroma.Search.Elasticsearch

you almost certainly have not started the elasticsearch OTP application, which is set to automatically start if the search module is correctly set

for the record, this should not have been an issue, support for "zincsearch" has never been mentioned if you are doing things outside the bounds of supported functionality, you will be largely on your own when it comes to debugging, no more in-depth support will be forthcoming that said, to quote the documentation ``` To use elasticsearch, set the search module to Pleroma.Search.Elasticsearch: config :pleroma, Pleroma.Search, module: Pleroma.Search.Elasticsearch ``` you almost certainly have not started the elasticsearch OTP application, which is set to automatically start if the search module is correctly set
Author

I understand that Zincsearch isn't supported directly, but it seems to be a more general issue with the Elasticsearch support.

I did enable the Elasticsearch module as instructed in the documentation via admin-fe. However I am not using the OTP release, so I guess I am missing this Elastic search application and need to install it manually? This seems to be not mentioned in the documentation for non-OTP setups?

Thanks!

I understand that Zincsearch isn't supported directly, but it seems to be a more general issue with the Elasticsearch support. I did enable the Elasticsearch module as instructed in the documentation via admin-fe. However I am not using the OTP release, so I guess I am missing this Elastic search application and need to install it manually? This seems to be not mentioned in the documentation for non-OTP setups? Thanks!

OTP refers to the system on which erlang and elixir run, not to the release

as stated in the documentation, admin-fe does not apply settings on boot but shortly after, please follow the instructions above

OTP refers to the system on which erlang and elixir run, not to the release as stated in the documentation, admin-fe does not apply settings on boot but shortly after, please follow the instructions above

additionally I am assuming you are using the correct mix env setting

additionally I am assuming you are using the correct mix env setting
Author

Yeah that seems to have solved it. Thanks.

I am still not quite getting it to work with Zinc, as it seems to work on building the index but times out at some point or so with no error, but that is more likely a Zinc specific issue.

Edit: couldn't get this to work in the end and went with Meilisearch which was easier to get working. I am actually not sure if the Elasticsearch backend works at all anymore ;)

Yeah that seems to have solved it. Thanks. I am still not quite getting it to work with Zinc, as it seems to work on building the index but times out at some point or so with no error, but that is more likely a Zinc specific issue. Edit: couldn't get this to work in the end and went with Meilisearch which was easier to get working. I am actually not sure if the Elasticsearch backend works at all anymore ;)
Kris closed this issue 2023-05-20 23:27:20 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: AkkomaGang/akkoma#543
No description provided.