Autoclosing topic causes 50x errors


(loopback0 - TDWTF) #1

As spotted over yonder.

At least 3 instances today where, as the autoclosure time hits, the server experiences “issues” with 500, 502, 504 errors being thrown for approx 10-15minutes.


(Jeff Atwood) #2

Hmm, we don’t see that here with autoclosing topics. Perhaps a volume of autoclose issue.


(loopback0 - TDWTF) #3

We’ve had (that I can see) 4 topics autoclose today.


(Sam Saffron) #4

I think something bad is happening on your instance unrelated to this. trying to debug again now.


(from TDWTF) #5

Let me rephrase that a bit:

Today we had multiple occasions of 504-errors with varying length over at our instance of Discourse. We noticed that every time the errors occured a topic had been closed (and sometimes people tried to write in said closed topic).
So we came to the conclusion that the closure of topics was probably the thing causing the problem.
We would appreciate if some dev could check any logs and either verify or deny our suspicion.

Thanks in advance,

TDWTF

Addendum: Now @Sam has already replied and seems to checking things out. I will post this regardless as phrasing it took effort


(Sam Saffron) #6

This is super odd @codinghorror we are also seeing this on BBS and bbs has the “auto closure” in common with WTF.

I am going to dig in to this code now.


(Sam Saffron) #7

This particular issue with auto close is now fixed:

https://github.com/discourse/discourse/commit/7e259375e993d7c17b41e949d8a8668be0ada12f

Leaving this open while I investigate if I can speed up the global consistency check


(Sam Saffron) #8

Closing as TopicUser.ensure_consistncy never fires outside of pretend_read, ensure_db_consistency is skipping it.

I still want to speed it up, but this issue is fixed


(Sam Saffron) #9