Browse Source

removed logfile

pull/123/head
notgiven688 3 years ago
parent
commit
79e3a481d7
1 changed files with 0 additions and 22 deletions
  1. +0
    -22
      server/Server/Program.cs

+ 0
- 22
server/Server/Program.cs View File

@ -19,8 +19,6 @@
// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#define WRITELOG
using System;
using System.Collections.Generic;
using System.IO;
@ -115,12 +113,6 @@ namespace Server {
private static Dictionary<string, PoolInfo> PoolPool = new Dictionary<string, PoolInfo> ();
#if(WRITELOG)
public const string LogFile = "out.log"; // rotate the out.log -> old_out.log
private const int RotateLogEveryXHeartbeats = 2160; // every 6h
#endif
private const int GraceConnectionTime = 16; // time to connect to a pool in seconds
private const int HeartbeatRate = 10; // server logic every x seconds
private const int TimeDevJobsAreOld = 600; // after that job-age we do not forward dev jobs
@ -502,10 +494,6 @@ namespace Server {
public static void Main (string[] args) {
#if(WRITELOG)
CConsole.DirectToFile(LogFile);
#endif
CConsole.ColorInfo (() => {
#if (DEBUG)
@ -1002,16 +990,6 @@ namespace Server {
Firewall.Heartbeat (Heartbeats);
#if(WRITELOG)
if(Heartbeats % RotateLogEveryXHeartbeats == 0)
{
CConsole.ColorWarning(() => Console.WriteLine("Rotating logfile: LogFile -> old_LogFile"));
CConsole.CloseFile();
File.Copy(LogFile, "old_" + LogFile,true);
CConsole.DirectToFile(LogFile);
}
#endif
try {
if (Heartbeats % SaveStatisticsEveryXHeartbeat == 0) {
CConsole.ColorInfo (() => Console.WriteLine ("Saving statistics."));

Loading…
Cancel
Save