{"action":"created","issue":{"url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/992","repository_url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk","labels_url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/992/labels{/name}","comments_url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/992/comments","events_url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/992/events","html_url":"https://github.com/azerothcore/azerothcore-wotlk/pull/992","id":345717963,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA0NzczODk0","number":992,"title":"Core/Logging: Fix out of file descriptors","user":{"login":"Winfidonarleyan","id":18329778,"node_id":"MDQ6VXNlcjE4MzI5Nzc4","avatar_url":"https://avatars3.githubusercontent.com/u/18329778?v=4","gravatar_id":"","url":"https://api.github.com/users/Winfidonarleyan","html_url":"https://github.com/Winfidonarleyan","followers_url":"https://api.github.com/users/Winfidonarleyan/followers","following_url":"https://api.github.com/users/Winfidonarleyan/following{/other_user}","gists_url":"https://api.github.com/users/Winfidonarleyan/gists{/gist_id}","starred_url":"https://api.github.com/users/Winfidonarleyan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Winfidonarleyan/subscriptions","organizations_url":"https://api.github.com/users/Winfidonarleyan/orgs","repos_url":"https://api.github.com/users/Winfidonarleyan/repos","events_url":"https://api.github.com/users/Winfidonarleyan/events{/privacy}","received_events_url":"https://api.github.com/users/Winfidonarleyan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-07-30T11:27:25Z","updated_at":"2018-07-30T13:38:55Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/pulls/992","html_url":"https://github.com/azerothcore/azerothcore-wotlk/pull/992","diff_url":"https://github.com/azerothcore/azerothcore-wotlk/pull/992.diff","patch_url":"https://github.com/azerothcore/azerothcore-wotlk/pull/992.patch"},"body":"##### CHANGES PROPOSED:\r\n-  Add check before opening a file\r\n\r\n##### ISSUES ADDRESSED:\r\nCloses https://github.com/azerothcore/azerothcore-wotlk/issues/991\r\n\r\n\r\n##### TESTS PERFORMED:\r\nNeed test...\r\n\r\n##### HOW TO TEST THE CHANGES:\r\n- Before apply test commit\r\n```\r\nFind the process ID of your worldserver :\r\npgrep worldserver\r\n\r\nList the file descriptors (replace XXXXX with the number above) :\r\nls -al /proc/XXXXX/fd\r\n\r\nCount the number of file descriptors :\r\nls -al /proc/XXXXX/fd | wc -l\r\n```\r\n- Apply test commit\r\n- Repeat step 1\r\n\r\n\r\n##### KNOWN ISSUES AND TODO LIST:\r\n<!-- This is a TODO list with checkboxes to tick -->\r\n\r\n- [ ] Need test Unix OS\r\n- [ ] Need test Windows OS\r\n- [ ] Need test in Build\r\n- [ ] Need test in Game\r\n\r\n##### Target branch(es): Master"},"comment":{"url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/comments/408866280","html_url":"https://github.com/azerothcore/azerothcore-wotlk/pull/992#issuecomment-408866280","issue_url":"https://api.github.com/repos/azerothcore/azerothcore-wotlk/issues/992","id":408866280,"node_id":"MDEyOklzc3VlQ29tbWVudDQwODg2NjI4MA==","user":{"login":"BarbzYHOOL","id":29780637,"node_id":"MDQ6VXNlcjI5NzgwNjM3","avatar_url":"https://avatars3.githubusercontent.com/u/29780637?v=4","gravatar_id":"","url":"https://api.github.com/users/BarbzYHOOL","html_url":"https://github.com/BarbzYHOOL","followers_url":"https://api.github.com/users/BarbzYHOOL/followers","following_url":"https://api.github.com/users/BarbzYHOOL/following{/other_user}","gists_url":"https://api.github.com/users/BarbzYHOOL/gists{/gist_id}","starred_url":"https://api.github.com/users/BarbzYHOOL/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BarbzYHOOL/subscriptions","organizations_url":"https://api.github.com/users/BarbzYHOOL/orgs","repos_url":"https://api.github.com/users/BarbzYHOOL/repos","events_url":"https://api.github.com/users/BarbzYHOOL/events{/privacy}","received_events_url":"https://api.github.com/users/BarbzYHOOL/received_events","type":"User","site_admin":false},"created_at":"2018-07-30T13:38:55Z","updated_at":"2018-07-30T13:38:55Z","author_association":"MEMBER","body":"Discussed with @Stoabrogga (since we found the issue yesterday)\r\n\r\nAnd here is a transcript:\r\n\r\n- so it means the logs wont work with this pr?\r\n- I think so, e.g. in function \"openLogFile\" NULL will be returned if the file is already open. So e.g. in function \"outErrorDb\", which calls \"openLogFile\", it will write nothing because NULL is returned.\r\nBy the way, in the original code all log files were initialized within the \"Initialize\" function, don't know why this has been changed. There the log files were initialized when the Log object is created and closed when the Log object is destroyed. I think this was a better way how to handle the log files.\r\n\r\n\r\nNow I tested the PR and I can confirm this, there is no more hundred of logs opened, there is literally 0 while it should have 1 log of each opened (verified on an older worldserver)"}}
{"actor":{"display_login":"BarbzYHOOL"}}