This article is a mirror article of machine translation, please click here to jump to the original article.

View: 35326|Reply: 0

[Solved] Close Quartz . .Net

[Copy link]
Posted on 5/19/2021 10:14:22 AM | | |
Use Quartz.NET to schedule some custom tasks in our app.Everything works fine, but Quartz. .Net will automatically record debug logs. andParallel to my business log (log4net used)!

Q:How do I turn off these logging?
A: Set LogProvider.IsDisabled = true before starting the scheduler; (using Quartz.Logging;That's it


Here's itQuartz.NET self-logged debug logs (parallel to my business logs)

[Log Time]: 2021-05-17 16:52:05,552 [Thread ID]: QuartzScheduler_CPICEScheduler-NON_CLUSTERED_MisfireHandler (0)
Log level: DEBUG
[Log content]: Scanning for misfires...

[Log Time]: 2021-05-17 16:52:05,559 [Thread ID]: 5
Log level: DEBUG
Log contents: :P repared SQL: SELECT
                t.TRIGGER_NAME, t.TRIGGER_GROUP, jd. JOB_CLASS_NAME
              FROM
                qrtz_TRIGGERS t
              JOIN
                qrtz_JOB_DETAILS jd ON (jd. SCHED_NAME = t.SCHED_NAME AND  jd. JOB_GROUP = t.JOB_GROUP AND jd. JOB_NAME = t.JOB_NAME)
              WHERE
                t.SCHED_NAME = @schedulerName AND TRIGGER_STATE = @state AND NEXT_FIRE_TIME <= @noLaterThan AND (MISFIRE_INSTR = -1 OR (MISFIRE_INSTR <> -1 AND NEXT_FIRE_TIME >= @noEarlierThan))
              ORDER BY
                NEXT_FIRE_TIME ASC, PRIORITY DESC LIMIT 1

[Log time]: 2021-05-17 16:52:05,561 [Thread ID]: 5
Log level: DEBUG
Log content: Batch acquisition of 0 triggers

[Log Time]: 2021-05-17 16:52:05,568 [Thread ID]: QuartzScheduler_CPICEScheduler-NON_CLUSTERED_MisfireHandler (0)
Log level: DEBUG
Log contents: :P repared SQL: SELECT COUNT(TRIGGER_NAME) FROM qrtz_TRIGGERS WHERE SCHED_NAME = @schedulerName AND MISFIRE_INSTR <> -1 AND NEXT_FIRE_TIME < @nextFireTime AND TRIGGER_STATE = @state1

[Log Time]: 2021-05-17 16:52:05,569 [Thread ID]: QuartzScheduler_CPICEScheduler-NON_CLUSTERED_MisfireHandler (0)
Log level: DEBUG
[Log Content]:Found 0 triggers that missed their scheduled fire-time.
————————————————————————————————————————————————————————————————————————————————
[Log time]: 2021-05-17 16:28:26,191 [Thread ID]: 5
Log level: INFO  
[Log content]: Scheduler CPICEScheduler_$_NON_CLUSTERED Shutdown complete.
[Log time]: 2021-05-17 16:28:26,205 [Thread ID]: 1
Log level: INFO  
[Log Content]: [Mission Closed]
[Log time]: 2021-05-17 16:30:26,549 [Thread ID]: 1
Log level: INFO  
[Log content]: [Service started]
[Log time]: 2021-05-17 16:30:26,676 [Thread ID]: 4
Log level: INFO  
[Log Content]: [Mission Start]
[Log time]: 2021-05-17 16:30:26,818 [Thread ID]: 4
Log level: INFO  
[Log content]: Registering datasource 'itsvse' with db provider: 'Quartz.Impl.AdoJobStore.Common.DbProvider'
[Log time]:2021-05-17 16:30:26,824 [Thread ID]:4
Log level: INFO  
[Log content]: Using object serializer: Quartz.Simpl.JsonObjectSerializer, Quartz.Serialization.Json





Previous:X-Forwarded-For multiple IP addresses in the HTTP request header
Next:Nuget packages multiple libraries into a package
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com