vesoft-inc/nebula-go

session pool error 'write: broken pipe'

zwkno1 opened this issue · 7 comments

There is a lot of errors of 'write: broken pipe' when the first time invoke SessionPool.Execute after a long idle time.

nebula-go version: v3.3.0

Aiee commented

Is the nebula service still alive?

Is the nebula service still alive?

yes. After a lot of errors i can invoke this method normally。

i got the same problem

lllfx commented

i got the same problem

I've met same error. I found that when there'a long idle time(8 hours by default in config file), TCP connection may be recycled.

Then client try to write a request to that connection after that, causing the EPIPE error.

is this why cleaner doesn't work?

if pool.conf.idleTime > 0 && pool.cleanerChan == nil {

means If configured idleTime, cleaner will clean dead conn automaticly, but
maxCleanSize := pool.idleSessions.Len() + pool.activeSessions.Len() - pool.conf.minSize

means If all sessions eventually expire, they may not be cleaned up because the number of sessions in pool did not exceed minSize

after this #279, the issue should be not existed.

when execute with error write: broken pipe, it would create a new session, and return the valid session into pool.