annotations - excludeFilters for SchedulingConfiguration is not working in spring 4.1.6 -
i'm trying exclude schedulingconfiguration while component scan seems not excluding,i can see still scheduler trigered. please me resolve issue..
main class:
public class storagedatareconcilebatchrunner { public static void main(string[] args) { new annotationconfigapplicationcontext(configclass.class).start(); } }
configuration class
@configuration @enableaspectjautoproxy(proxytargetclass = true) @componentscan(excludefilters = { @componentscan.filter(type = filtertype.assignable_type, value = reconcilebatchschedulerunconfig.class)}, basepackages = {"com.a.b.c.api"}) @enabletransactionmanagement public class configclass { }
scheduler
@component public class reconcilebatchschedulerunconfig { @resource private datareconcilebatch datareconcilebatch; @scheduled(fixeddelay = 10000) private void scheduledreconciliation() { datareconcilebatch.startdatareconciliation(); } }
Comments
Post a Comment