问题
In my Java EE application I have a @Singleton
with several @Schedule
d methods. When I deploy the app on Wildfly, the Timer service starts executing these methods, which is correct.
Since during development I test my app on a secondary server, I'd like to disable the Timer service on that instance of Wildfly, to prevent the execution of those methods.
Problem is… I can't find any setting to do this.
How can I disable the Timer service in Wildfly 10?
回答1:
Try to remove block timer-service
in standalone.xml.
<subsystem xmlns="urn:jboss:domain:ejb3:3.0">
...
<timer-service thread-pool-name="default" default-data-store="default-file-store">
<data-stores>
<file-data-store name="default-file-store" path="timer-service-data" relative-to="jboss.server.data.dir"/>
</data-stores>
</timer-service>
It works for wildfly 9.
来源:https://stackoverflow.com/questions/37027870/how-to-disable-timer-service-in-wildfly-10