Skip to content

Commit

Permalink
WELD-2079 Do not register ScheduledExecutorServiceFactory by default
Browse files Browse the repository at this point in the history
  • Loading branch information
mkouba committed Jan 14, 2016
1 parent 8725dbc commit 413dace
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
4 changes: 3 additions & 1 deletion docs/reference/src/main/asciidoc/ri-spi.asciidoc
Expand Up @@ -960,4 +960,6 @@ Instead, this dependency needs to be deployed separately to the OSGi container.

* Java 6 support was dropped. Java 7 or newer is now required for both compile time and runtime.

* An observer for `@Initialized(ConversationScoped.class)` or `@Destroyed(ConversationScoped.class)` event no longer forces eager conversation context initialization. See also <<_lazy_and_eager_conversation_context_initialization>>.
* An observer for `@Initialized(ConversationScoped.class)` or `@Destroyed(ConversationScoped.class)` event no longer forces eager conversation context initialization. See also <<_lazy_and_eager_conversation_context_initialization>>.

* `ScheduledExecutorServiceFactory` is deprecated and no default implementation is provided by default. This service has not been used by Weld internals at least since version 1.1.0.Final.
5 changes: 0 additions & 5 deletions impl/src/main/java/org/jboss/weld/bootstrap/WeldStartup.java
Expand Up @@ -120,11 +120,9 @@
import org.jboss.weld.resources.ReflectionCache;
import org.jboss.weld.resources.ReflectionCacheFactory;
import org.jboss.weld.resources.SharedObjectCache;
import org.jboss.weld.resources.SingleThreadScheduledExecutorServiceFactory;
import org.jboss.weld.resources.WeldClassLoaderResourceLoader;
import org.jboss.weld.resources.spi.ClassFileServices;
import org.jboss.weld.resources.spi.ResourceLoader;
import org.jboss.weld.resources.spi.ScheduledExecutorServiceFactory;
import org.jboss.weld.serialization.BeanIdentifierIndex;
import org.jboss.weld.serialization.ContextualStoreImpl;
import org.jboss.weld.serialization.spi.ContextualStore;
Expand Down Expand Up @@ -200,9 +198,6 @@ public WeldRuntime startContainer(String contextId, Environment environment, Dep
WeldConfiguration configuration = new WeldConfiguration(registry, deployment);
registry.add(WeldConfiguration.class, configuration);

if (!registry.contains(ScheduledExecutorServiceFactory.class)) {
registry.add(ScheduledExecutorServiceFactory.class, new SingleThreadScheduledExecutorServiceFactory());
}
if (!registry.contains(ProxyServices.class)) {
registry.add(ProxyServices.class, new SimpleProxyServices());
}
Expand Down
Expand Up @@ -16,11 +16,16 @@
*/
package org.jboss.weld.resources;

import org.jboss.weld.resources.spi.ScheduledExecutorServiceFactory;

import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;

import org.jboss.weld.resources.spi.ScheduledExecutorServiceFactory;

/**
*
* @see WELD-2079
*/
@Deprecated
public class SingleThreadScheduledExecutorServiceFactory implements ScheduledExecutorServiceFactory {

private final ScheduledExecutorService executorService;
Expand Down

0 comments on commit 413dace

Please sign in to comment.