diff --git a/org.springframework.context/src/main/java/org/springframework/context/event/SimpleApplicationEventMulticaster.java b/org.springframework.context/src/main/java/org/springframework/context/event/SimpleApplicationEventMulticaster.java index 1ca1235db1c..d84d0d17b06 100644 --- a/org.springframework.context/src/main/java/org/springframework/context/event/SimpleApplicationEventMulticaster.java +++ b/org.springframework.context/src/main/java/org/springframework/context/event/SimpleApplicationEventMulticaster.java @@ -68,7 +68,6 @@ public class SimpleApplicationEventMulticaster extends AbstractApplicationEventM * transaction association) unless the TaskExecutor explicitly supports this. * @see org.springframework.core.task.SyncTaskExecutor * @see org.springframework.core.task.SimpleAsyncTaskExecutor - * @see org.springframework.scheduling.timer.TimerTaskExecutor */ public void setTaskExecutor(Executor taskExecutor) { this.taskExecutor = taskExecutor; diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorFactoryBean.java b/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorFactoryBean.java index 8b152235f88..61915d2c76f 100644 --- a/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorFactoryBean.java +++ b/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorFactoryBean.java @@ -52,10 +52,6 @@ import org.springframework.util.ObjectUtils; * {@link #setContinueScheduledExecutionAfterException "continueScheduledExecutionAfterException"} * property to "true". * - *
This class is analogous to the - * {@link org.springframework.scheduling.timer.TimerFactoryBean} - * class for the JDK 1.3 {@link java.util.Timer} facility. - * * @author Juergen Hoeller * @since 2.0 * @see #setPoolSize diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorTask.java b/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorTask.java index 756019ede69..a0a658a05d4 100644 --- a/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorTask.java +++ b/org.springframework.context/src/main/java/org/springframework/scheduling/concurrent/ScheduledExecutorTask.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2007 the original author or authors. + * Copyright 2002-2009 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -31,14 +31,10 @@ import java.util.concurrent.TimeUnit; * uses a {@link Runnable} instance that is shared between repeated executions, * in contrast to Quartz which creates a new Job instance for each execution. * - *
This class is analogous to the {@link org.springframework.scheduling.timer.ScheduledTimerTask} - * class for the JDK 1.3 {@link java.util.Timer} facility. - * * @author Juergen Hoeller * @since 2.0 * @see java.util.concurrent.ScheduledExecutorService#scheduleWithFixedDelay(java.lang.Runnable, long, long, java.util.concurrent.TimeUnit) * @see java.util.concurrent.ScheduledExecutorService#scheduleAtFixedRate(java.lang.Runnable, long, long, java.util.concurrent.TimeUnit) - * @see org.springframework.scheduling.timer.ScheduledTimerTask */ public class ScheduledExecutorTask { diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/support/MethodInvokingRunnable.java b/org.springframework.context/src/main/java/org/springframework/scheduling/support/MethodInvokingRunnable.java index 18f77798b94..142b832e3ce 100644 --- a/org.springframework.context/src/main/java/org/springframework/scheduling/support/MethodInvokingRunnable.java +++ b/org.springframework.context/src/main/java/org/springframework/scheduling/support/MethodInvokingRunnable.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2008 the original author or authors. + * Copyright 2002-2009 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -33,18 +33,6 @@ import org.springframework.util.ClassUtils; *
Inherits common configuration properties from * {@link org.springframework.util.MethodInvoker}. * - *
Useful to generically encapsulate a method invocation as timer task
- * for java.util.Timer, in combination with a
- * {@link org.springframework.scheduling.timer.DelegatingTimerTask} adapter.
- * Can also be used with JDK 1.5's java.util.concurrent.Executor
- * abstraction, which works with plain Runnables.
- *
- *
Extended by Spring's
- * {@link org.springframework.scheduling.timer.MethodInvokingTimerTaskFactoryBean}
- * adapter for Supports limiting concurrent threads through the "concurrencyLimit"
@@ -41,7 +41,6 @@ import org.springframework.util.CustomizableThreadCreator;
* @since 2.0
* @see #setConcurrencyLimit
* @see SyncTaskExecutor
- * @see org.springframework.scheduling.timer.TimerTaskExecutor
* @see org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor
* @see org.springframework.scheduling.commonj.WorkManagerTaskExecutor
*/
diff --git a/org.springframework.core/src/main/java/org/springframework/core/task/SyncTaskExecutor.java b/org.springframework.core/src/main/java/org/springframework/core/task/SyncTaskExecutor.java
index 857edf1f449..4830730c754 100644
--- a/org.springframework.core/src/main/java/org/springframework/core/task/SyncTaskExecutor.java
+++ b/org.springframework.core/src/main/java/org/springframework/core/task/SyncTaskExecutor.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2006 the original author or authors.
+ * Copyright 2002-2009 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,16 +16,16 @@
package org.springframework.core.task;
-import org.springframework.util.Assert;
-
import java.io.Serializable;
+import org.springframework.util.Assert;
+
/**
- * Mainly intended for testing scenarios.
- *
+ *
* Execution in the calling thread does have the advantage of participating
* in it's thread context, for example the thread context class loader or the
* thread's current transaction association. That said, in many cases,
@@ -33,9 +33,8 @@ import java.io.Serializable;
* java.util.TimerTask. Note that you can populate a
- * ScheduledTimerTask object with a plain MethodInvokingRunnable instance
- * as well, which will automatically get wrapped with a DelegatingTimerTask.
- *
* @author Juergen Hoeller
* @since 1.2.4
* @see org.springframework.scheduling.timer.ScheduledTimerTask#setRunnable(Runnable)
diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/DelegatingTimerTask.java b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/DelegatingTimerTask.java
index ba8d365d1d0..68880c17961 100644
--- a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/DelegatingTimerTask.java
+++ b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/DelegatingTimerTask.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2008 the original author or authors.
+ * Copyright 2002-2009 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -32,7 +32,10 @@ import org.springframework.util.Assert;
*
* @author Juergen Hoeller
* @since 1.2.4
+ * @deprecated as of Spring 3.0, in favor of the scheduling.concurrent
+ * package which is based on Java 5's java.util.concurrent.ExecutorService
*/
+@Deprecated
public class DelegatingTimerTask extends TimerTask {
private static final Log logger = LogFactory.getLog(DelegatingTimerTask.class);
diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/MethodInvokingTimerTaskFactoryBean.java b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/MethodInvokingTimerTaskFactoryBean.java
index 98513a281ea..f387a0e7044 100644
--- a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/MethodInvokingTimerTaskFactoryBean.java
+++ b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/MethodInvokingTimerTaskFactoryBean.java
@@ -37,7 +37,10 @@ import org.springframework.scheduling.support.MethodInvokingRunnable;
* @see ScheduledTimerTask#setRunnable
* @see org.springframework.scheduling.support.MethodInvokingRunnable
* @see org.springframework.beans.factory.config.MethodInvokingFactoryBean
+ * @deprecated as of Spring 3.0, in favor of the scheduling.concurrent
+ * package which is based on Java 5's java.util.concurrent.ExecutorService
*/
+@Deprecated
public class MethodInvokingTimerTaskFactoryBean extends MethodInvokingRunnable implements FactoryBeanscheduling.concurrent
+ * package which is based on Java 5's java.util.concurrent.ExecutorService
*/
+@Deprecated
public class ScheduledTimerTask {
private TimerTask timerTask;
diff --git a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/TimerFactoryBean.java b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/TimerFactoryBean.java
index 6fed79af6bf..38c4f8c23a0 100644
--- a/org.springframework.context/src/main/java/org/springframework/scheduling/timer/TimerFactoryBean.java
+++ b/org.springframework.context/src/main/java/org/springframework/scheduling/timer/TimerFactoryBean.java
@@ -46,7 +46,10 @@ import org.springframework.util.StringUtils;
* @see ScheduledTimerTask
* @see java.util.Timer
* @see java.util.TimerTask
+ * @deprecated as of Spring 3.0, in favor of the scheduling.concurrent
+ * package which is based on Java 5's java.util.concurrent.ExecutorService
*/
+@Deprecated
public class TimerFactoryBean implements FactoryBeanscheduling.concurrent
+ * package which is based on Java 5's java.util.concurrent.ExecutorService
*/
+@Deprecated
public class TimerTaskExecutor implements SchedulingTaskExecutor, BeanNameAware, InitializingBean, DisposableBean {
protected final Log logger = LogFactory.getLog(getClass());
diff --git a/org.springframework.core/src/main/java/org/springframework/core/task/SimpleAsyncTaskExecutor.java b/org.springframework.core/src/main/java/org/springframework/core/task/SimpleAsyncTaskExecutor.java
index 56ded1323d6..e92efb8ca34 100644
--- a/org.springframework.core/src/main/java/org/springframework/core/task/SimpleAsyncTaskExecutor.java
+++ b/org.springframework.core/src/main/java/org/springframework/core/task/SimpleAsyncTaskExecutor.java
@@ -27,7 +27,7 @@ import org.springframework.util.ConcurrencyThrottleSupport;
import org.springframework.util.CustomizableThreadCreator;
/**
- * TaskExecutor implementation that fires up a new Thread for each task,
+ * {@link TaskExecutor} implementation that fires up a new Thread for each task,
* executing it asynchronously.
*
* TaskExecutor implementation that executes each task
- * synchronously in the calling thread.
- *
+ * {@link TaskExecutor} implementation that executes each task synchronously
+ * in the calling thread.
+ *
* TaskExecutor instead for such scenarios.
*
* @author Juergen Hoeller
- * @see SimpleAsyncTaskExecutor
- * @see org.springframework.scheduling.timer.TimerTaskExecutor
* @since 2.0
+ * @see SimpleAsyncTaskExecutor
*/
public class SyncTaskExecutor implements TaskExecutor, Serializable {