Commit graph

14 commits

Author SHA1 Message Date
Stan Hu
324b3bbaca Memoize GitLab logger to reduce open file descriptors
We see that in gitlab-org/gitlab-ee#3664 that if we log a lot of
data in Sidekiq workers, the number of open file descriptors
reaches over 1000. To avoid this, we can memoize the logger per
thread via RequestStore.

Closes gitlab-org/gitlab-ee#3664
2017-10-24 14:06:23 +03:00
Robert Speicher
4598e0c392 Fix a potential timeout in Gitlab::Logger.read_latest
If this method was called for a file that didn't exist, we attempted to
first `build` it. But if the file wasn't writeable, such as a symlink
pointing to an unmounted filesystem, the method would just hang and
eventually timeout.

Further, this was entirely pointless since we were creating a file and
then shelling out to `tail`, eventually returning an empty Array. Now we
just skip building it and return the empty Array straight away.
2017-08-22 17:09:45 -04:00
Ciro Santilli
9bebacd692 Dry admin logs. 2014-10-06 00:14:46 +02:00
Ciro Santilli
2e9f5de868 Add parenthesis to function def with arguments. 2014-10-03 09:18:46 +02:00
Jacob Vosmaer
2b816075dc Replace backticks with Gitlab::Popen 2014-03-03 08:40:29 +01:00
Dmitriy Zaporozhets
4b02f4a22d show production.log, show only active milestone for issue filter 2012-12-19 07:14:05 +03:00
Dmitriy Zaporozhets
ff9a2e2a93 Improve admin logs 2012-11-29 07:49:11 +03:00
Robert Speicher
afc4a75499 Use Rails.root.join where appropriate 2012-09-26 16:32:26 -04:00
randx
0523b4265b Application logger 2012-09-11 23:24:53 +03:00
Pat Thoyts
6035ad7e1f Create the githost.log file if necessary.
This resolves issue #1121.

Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
2012-07-21 15:32:04 +01:00
Dmitriy Zaporozhets
8803350023 CHANGELOG updated. Fixed MR bug. Logger improved 2012-07-17 08:23:16 +03:00
Dmitriy Zaporozhets
2a705c4f40 Admin logs improved. Commits list box styled 2012-07-16 08:03:10 +03:00
Dmitriy Zaporozhets
d40b9ce26d Admin gitolite logs. Refactored project creation. Few style fixes. 2012-07-05 21:59:37 +03:00
randx
3272620f72 lib/ refactoring. Module Gitlabhq renamed to Gitlab 2012-05-26 13:37:49 +03:00
Renamed from lib/gitlabhq/logger.rb (Browse further)