diff options
Diffstat (limited to 'plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java')
-rw-r--r-- | plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java index 807529e5db..d8ac8927cc 100644 --- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java +++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/DelegatingSessionProtocol.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010-2016, 2019-2021 Eike Stepper (Loehne, Germany) and others. + * Copyright (c) 2010-2016, 2019-2022 Eike Stepper (Loehne, Germany) and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -39,6 +39,7 @@ import org.eclipse.emf.cdo.session.CDOSession; import org.eclipse.emf.cdo.session.CDOSession.ExceptionHandler; import org.eclipse.emf.cdo.session.remote.CDORemoteSession; import org.eclipse.emf.cdo.session.remote.CDORemoteSessionMessage; +import org.eclipse.emf.cdo.session.remote.CDORemoteTopic; import org.eclipse.emf.cdo.spi.common.CDORawReplicationContext; import org.eclipse.emf.cdo.spi.common.CDOReplicationContext; import org.eclipse.emf.cdo.spi.common.commit.CDORevisionAvailabilityInfo; @@ -966,14 +967,21 @@ public class DelegatingSessionProtocol extends Lifecycle implements CDOSessionPr } @Override + @Deprecated public Set<Integer> sendRemoteMessage(CDORemoteSessionMessage message, List<CDORemoteSession> recipients) { + return sendRemoteMessage(message, null, recipients); + } + + @Override + public Set<Integer> sendRemoteMessage(CDORemoteSessionMessage message, CDORemoteTopic topic, List<CDORemoteSession> recipients) + { int attempt = 0; for (;;) { try { - return delegate.sendRemoteMessage(message, recipients); + return delegate.sendRemoteMessage(message, topic, recipients); } catch (Exception ex) { @@ -1000,6 +1008,23 @@ public class DelegatingSessionProtocol extends Lifecycle implements CDOSessionPr } @Override + public Set<Integer> subscribeRemoteTopic(String id, boolean on) + { + int attempt = 0; + for (;;) + { + try + { + return delegate.subscribeRemoteTopic(id, on); + } + catch (Exception ex) + { + handleException(++attempt, ex); + } + } + } + + @Override public void replicateRepository(CDOReplicationContext context, OMMonitor monitor) { int attempt = 0; |