labs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ber...@apache.org
Subject svn commit: r658568 - /labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java
Date Wed, 21 May 2008 06:56:06 GMT
Author: berndf
Date: Tue May 20 23:56:06 2008
New Revision: 658568

URL: http://svn.apache.org/viewvc?rev=658568&view=rev
Log:
[vysper] prepare use of failure strategy in delivery

Modified:
    labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java

Modified: labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java
URL: http://svn.apache.org/viewvc/labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java?rev=658568&r1=658567&r2=658568&view=diff
==============================================================================
--- labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java (original)
+++ labs/vysper/src/main/java/org/apache/vysper/xmpp/delivery/DeliveringStanzaRelay.java Tue
May 20 23:56:06 2008
@@ -47,7 +47,7 @@
     }
     
     public void relay(Entity receiver, Stanza stanza, DeliveryFailureStrategy deliveryFailureStrategy)
throws DeliveryException {
-        Future<RelayResult> resultFuture = executor.submit(new Relay(receiver, stanza));
+        Future<RelayResult> resultFuture = executor.submit(new Relay(receiver, stanza,
deliveryFailureStrategy));
     }
 
     public boolean receiverIsOnline(Entity receiver) {
@@ -57,10 +57,12 @@
     private class Relay implements Callable<RelayResult> {
         private Entity receiver;
         private Stanza stanza;
+        private DeliveryFailureStrategy deliveryFailureStrategy;
 
-        Relay(Entity receiver, Stanza stanza) {
+        Relay(Entity receiver, Stanza stanza, DeliveryFailureStrategy deliveryFailureStrategy)
{
             this.receiver = receiver;
             this.stanza = stanza;
+            this.deliveryFailureStrategy = deliveryFailureStrategy;
         }
 
         public Entity getReceiver() {
@@ -71,6 +73,10 @@
             return stanza;
         }
 
+        public DeliveryFailureStrategy getDeliveryFailureStrategy() {
+            return deliveryFailureStrategy;
+        }
+
         public RelayResult call() {
             try {
                 List<SessionContext> receivingSessions = resourceRegistry.getSessions(receiver);



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org


Mime
View raw message