unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Mathieu Othacehe <othacehe@gnu.org>
To: 42548@debbugs.gnu.org
Subject: bug#42548: Cuirass 504 errors
Date: Tue, 04 Aug 2020 18:48:24 +0200	[thread overview]
Message-ID: <87bljq8ihz.fsf@gnu.org> (raw)
In-Reply-To: <87mu3jheme.fsf@gnu.org> (Mathieu Othacehe's message of "Tue, 28 Jul 2020 16:56:57 +0200")


Hello,

> that suggests that we try to write something to a closed file.
>
> To be investigated :)

Ok, so I have a better grasp on what's going on. Cuirass web server is
receiving some requests such as "/builds/1234)" which were not rejected,
but worst, caused SQL queries such as "select * from Builds".

As the table is quite large, it caused some of the DB workers to
hang. Once all DB workers were hanging, the queries started to
accumulate until the open fd limit (1024) was reached.

I did consolidate the HTTP queries validation, and Cuirass web server is
now running since 48 hours, which has not happened in months I think.

I also added some warnings to detect DB workers hanging for more than 5
seconds. The next step is to log all SQL queries using[1]. This should
allow us to spot this kind of issues more easily. Logging the duration
of each query should also help us to optimize the queries.

I'm still waiting a few days before closing this issue.

Thanks,

Mathieu

[1]: https://notabug.org/guile-sqlite3/guile-sqlite3/pulls/16 




  reply	other threads:[~2020-08-04 16:49 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-26 16:10 bug#42548: Cuirass 504 errors Mathieu Othacehe
2020-07-27 22:11 ` zimoun
2020-07-28  7:32   ` Mathieu Othacehe
2020-07-28  8:49     ` zimoun
2020-07-28 14:56       ` Mathieu Othacehe
2020-08-04 16:48         ` Mathieu Othacehe [this message]
2020-08-06  8:16           ` Mathieu Othacehe
2020-07-30 14:47 ` Mathieu Othacehe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bljq8ihz.fsf@gnu.org \
    --to=othacehe@gnu.org \
    --cc=42548@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).