This message was deleted.
# community-help
s
This message was deleted.
k
Sounds like a race condition to me. Ideally this should not happen and especially when network latencies are considered but I wonder if there is a bug lurking that's manifesting on local when you delete and create a collection fast like that. How often does this occur? Every time or rarely?
i
Randomly. I would say once a month or so
k
Got it. Seems like a race condition. Will look and get back to you. Thanks for reporting it!
i
Yeah no problem. Cheers
k
One thing to be aware of is the client timeout
i
maybe this will help: Typesense-Controller: Importing entries (18015) to collection annotations Request #1695201562586: Request to Node 0 failed due to "ECONNRESET socket hang up"
The
ECONNRESET socket hang up
could maybe trigger inserting everything again?
k
Yeah looks like connection is timed out because of the timeout value in the client.
And when that happens request can be retried
So import happens twice! Just set a larger connection timeout value so that premature disconnect doesn't happen.
i
ah super
thank you very much. I will try that
Setting connectionTimeoutSeconds or timeoutSeconds when creating a new client does not seem to have an effect
Still get the Request to Node 0 failed due to "ECONNRESET socket hang up error after about 10 seconds
k
Any errors in Typesense server logs?
i
running typesense in a docker container
can you please remind me where the logs are stored
never-mind got it
Nothing pops out when looking over the logs
I am just chunking the imports now. Sets of 5000
for the first import the hang up error still occurs, but then for the remaining ones it does not
[20-09-2023 114303] - info: Typesense-Controller: Importing entries (5000) Request #1695206583183: Request to Node 0 failed due to "ECONNRESET socket hang up" Request #1695206583183: Sleeping for 0.1s and then retrying request... [20-09-2023 114323] - info: Typesense-Controller: Importing entries (5000) [20-09-2023 114331] - info: Typesense-Controller: Importing entries (5000) [20-09-2023 114334] - info: Typesense-Controller: Importing entries (2987)
Setting the batches down to 500 got rid of the error altogether. (makes sense)