diff Platforms/Generic/WebServiceCommandBase.h @ 309:14ef1227120f am-callable-and-promise

web services: better handling of failures
author am@osimis.io
date Fri, 28 Sep 2018 15:02:43 +0200
parents 547e1cf7aa7b
children c34784e5f299
line wrap: on
line diff
--- a/Platforms/Generic/WebServiceCommandBase.h	Tue Sep 25 15:14:53 2018 +0200
+++ b/Platforms/Generic/WebServiceCommandBase.h	Fri Sep 28 15:02:43 2018 +0200
@@ -46,6 +46,7 @@
     bool                                    success_;
     std::string                             answer_;
     NativeStoneApplicationContext&          context_;
+    unsigned int                            timeoutInSeconds_;
 
   public:
     WebServiceCommandBase(MessageBroker& broker,
@@ -54,8 +55,10 @@
                           const Orthanc::WebServiceParameters& parameters,
                           const std::string& uri,
                           const std::map<std::string, std::string>& headers,
+                          unsigned int timeoutInSeconds,
                           Orthanc::IDynamicObject* payload /* takes ownership */,
-                          NativeStoneApplicationContext& context);
+                          NativeStoneApplicationContext& context
+                          );
 
     virtual void Execute() = 0;