From cc97ba2e17d48cc5fa02f8d9c32b2e0ffacab1a6 Mon Sep 17 00:00:00 2001
From: Mehdi Abaakouk <sileht@redhat.com>
Date: Tue, 1 Dec 2015 15:50:50 +0100
Subject: [PATCH] doc: explain rpc call/cast expection

This change adds some doc about remote method execution expectation
when rpc call/cast is used.

Change-Id: Idb26413fc9a6747ebcd6fd32b82f63ea97bfae16
---
 oslo_messaging/rpc/client.py | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/oslo_messaging/rpc/client.py b/oslo_messaging/rpc/client.py
index f67f673dd..7beea841e 100644
--- a/oslo_messaging/rpc/client.py
+++ b/oslo_messaging/rpc/client.py
@@ -356,6 +356,10 @@ class RPCClient(object):
         Similarly, the request context must be a dict unless the client's
         serializer supports serializing another type.
 
+        Note: cast doesn't ensure the remote method to be been executed
+        on each destination. But ensures that it will be not executed twice
+        on a destination.
+
         :param ctxt: a request context dict
         :type ctxt: dict
         :param method: the method name
@@ -392,6 +396,12 @@ class RPCClient(object):
         allowed_remote_exmods list, then a messaging.RemoteError exception is
         raised with all details of the remote exception.
 
+        Note: call is done 'at-most-once'. In case of we can't known
+        if the call have been done correctly, because we didn't get the
+        response on time, MessagingTimeout exception is raised.
+        The real reason can vary, transport failure, worker
+        doesn't answer in time or crash, ...
+
         :param ctxt: a request context dict
         :type ctxt: dict
         :param method: the method name