james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From btell...@apache.org
Subject [4/9] james-project git commit: JAMES-1617 CassandraSieveRepository should be a singleton
Date Thu, 07 Apr 2016 03:10:14 GMT
JAMES-1617 CassandraSieveRepository should be a singleton


Project: http://git-wip-us.apache.org/repos/asf/james-project/repo
Commit: http://git-wip-us.apache.org/repos/asf/james-project/commit/49b31808
Tree: http://git-wip-us.apache.org/repos/asf/james-project/tree/49b31808
Diff: http://git-wip-us.apache.org/repos/asf/james-project/diff/49b31808

Branch: refs/heads/master
Commit: 49b318080201a9e4a1a99851133fed88e5ad8df3
Parents: f054e2c
Author: Benoit Tellier <btellier@linagora.com>
Authored: Tue Mar 15 11:40:59 2016 +0700
Committer: Benoit Tellier <btellier@linagora.com>
Committed: Thu Apr 7 09:13:35 2016 +0700

----------------------------------------------------------------------
 .../apache/james/modules/data/CassandraSieveRepositoryModule.java  | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/james-project/blob/49b31808/server/container/cassandra-guice/src/main/java/org/apache/james/modules/data/CassandraSieveRepositoryModule.java
----------------------------------------------------------------------
diff --git a/server/container/cassandra-guice/src/main/java/org/apache/james/modules/data/CassandraSieveRepositoryModule.java
b/server/container/cassandra-guice/src/main/java/org/apache/james/modules/data/CassandraSieveRepositoryModule.java
index ffce858..4ea5aa7 100644
--- a/server/container/cassandra-guice/src/main/java/org/apache/james/modules/data/CassandraSieveRepositoryModule.java
+++ b/server/container/cassandra-guice/src/main/java/org/apache/james/modules/data/CassandraSieveRepositoryModule.java
@@ -19,6 +19,7 @@
 package org.apache.james.modules.data;
 
 import com.google.inject.AbstractModule;
+import com.google.inject.Scopes;
 import com.google.inject.multibindings.Multibinder;
 import org.apache.james.backends.cassandra.components.CassandraModule;
 import org.apache.james.sieve.cassandra.CassandraSieveRepository;
@@ -28,6 +29,7 @@ public class CassandraSieveRepositoryModule extends AbstractModule {
     
     @Override
     public void configure() {
+        bind(CassandraSieveRepository.class).in(Scopes.SINGLETON);
         bind(SieveRepository.class).to(CassandraSieveRepository.class);
         Multibinder<CassandraModule> cassandraDataDefinitions = Multibinder.newSetBinder(binder(),
CassandraModule.class);
         cassandraDataDefinitions.addBinding().to(org.apache.james.sieve.cassandra.CassandraSieveRepositoryModule.class);


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message