<div class="gmail_quote"> <br>
<div>Hi all,</div>
<div> </div>
<div>First let me explain my program and later will tell about the issue i am facing with dbus.</div>
<div>******This is the function on the client side which is being called from process A for 10000 times from 10 different threads ***********</div>
<div>static void TestfunctA(ELAPSED_TIME_STATS *et)<br>{</div>
<div> </div>
<div>   int                        i;<br>   printf(&quot;\n\nstarting %s.\n&quot;, __FUNCTION__);</div>
<div>   InitElapsedTimeSet(&quot;VZPAL_GetVideoInputStatusInfo&quot;, et); //initializing the time_spec struct<br>   for (i=1; i&lt;=LoopCount; i++)<br>   {<br>      StartElapsedTimeMeasurement(et);// making note of the start time <br>
      Result = function1(10, &amp;variable);<br>      StopElapsedTimeMeasurement(et);//making note of the end time</div>
<div>   }<br>   DumpLatencyTimeSet(et);<br>   DumpElapsedTimeSet(et);<br>}</div>
<div> </div>
<div>************ client glue file which actally calls the original fucntion on the process B which is the server *****************</div>
<div>eVZPAL_ReturnCode function1 (</div>
<div>                           int   n,<br>                           int array[512])                 // input array,  will have to be passed as Glib variant<br>{<br> <br>   GError            *error = NULL;<br>   GVariant          *gvarray;<br>
   gconstpointer     structFromGV;<br>   gsize             dataSize;</div>
<div>   // call the sync version of the method,<br>   com_our_api_call_function1_sync (proxy,<br>                                      n, &amp;gvarray, (gint*)&amp;nResult,<br>                                      NULL, &amp;error);<br>
   if (error != NULL)<br>   {<br>      g_print(&quot;Error in %s, msg=\&quot;%s\&quot;.\n&quot;, __FUNCTION__, error-&gt;message);<br>      g_object_unref(error);<br>   }</div>
<div>   structFromGV = g_variant_get_fixed_array(gvarray, &amp;dataSize, sizeof (guchar));<br>   memcpy(array, structFromGV, sizeof(array));</div>
<div>   g_variant_unref(gvarray);<br>    return nResult;<br>}</div>
<div> </div>
<div> </div>
<div>***********************This is the code for the Server side glue code which runs on the process B***********************</div>
<div>in bus acquired function i registered the function1 with the respective signal handler..</div>
<div>g_signal_connect(interface, &quot;handle-get-function1&quot;, G_CALLBACK(Do_function1),  NULL);<br></div>
<div> </div>
<div>static gboolean Do_function1(<br>   ComlOurApi        *interface,<br>   GDBusMethodInvocation      *invocation,<br>   guint16                    n,<br>   int                           *InputStatus,<br>   gpointer                   user_data)<br>
{<br>   GVariant                   *gvarray;<br>    int                         array[512];    // input struct, will have to be passed as Glib variant</div>
<div>   // get the data from VZPALe.<br>   nResult = function1(n, &amp;array);</div>
<div>   gv = g_variant_new_from_data(((const GVariantType *) &quot;ay&quot;),  &amp;array,<br>                                           sizeof(array),<br>                                           TRUE, NULL, NULL);</div>

<div>   // send the results back to the client process<br>   coml_our_api_complete_function1 (interface, invocation,<br>                                            gvarray, (guint16) nResult);</div>
<div>   // a little test to see if main loop calls these functions<br>   //volatile pid_t callbackPid = getpid();<br>   //g_print(&quot;\n mainloop pid is %x, callback pid is %x.\n&quot;, mainLoopPid, callbackPid);</div>

<div>   g_variant_unref(gvarray);<br>   (void) user_data;    //  </div>
<div>   return TRUE;         // to indicate that we handled</div>
<div>}<br></div>
<div>This inturn calls a original function....</div>
<div> </div>
<div>My issue is this program works perfectly fine... no errors but when i run this client for 10000 run in 10 different  threads ( i am calling the same API) </div>
<div>I am getting the error </div>
<div> </div>
<div> </div>
<div><strong>Error in VZPAL_TuneToChannel, msg=&quot;GDBus.Error:org.freedesktop.DBus.Error.NoReply: Message did not receive a reply (timeout by message bus)&quot;.</strong></div>
<div><strong></strong> </div>
<div>and automatically my server loses its message bus which was acquired. </div>
<div> </div>
<div>I would like to know is there a work around for the same.. because my system in real time scenario need to handle some 10000 calls from  more than 50 threads, but where </div>
<div>as the dbus is failing when there is more than 6 threads are called for the function which gives array or structure as out parameters during its call back.</div>
<div> </div>
<div>I observe this with functions having structure or array as out parameters, which needs to be sent back to the client process. </div>
<div> </div>
<div>and also the dbus thread timing and standard deviation of the dbus call across the process in my system is 4.3 msec , 
<div>which is three time slower than normal linux os. </div>
<div> </div>
<div>standard deviation of the threads increases as the number of threads <a href="http://increases.it">increases.it</a> varies from 3.5msec to 18 mesc which is not accpetable.</div>
<div> </div>
<div>I have also tired to increase the reply time out in the configuration files (system.conf and sessiont.conf ) but even that didnt help</div>
<div> </div></div>
<div>Is there a solution for my problem..? I badly need to increase the dbus performance.. </div>
<div> </div>
<div>kindly help me friends .Thanks in advance.</div>
<div> </div>
<div>Regards</div>
<div>vinoth</div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div><br><br> </div>
<div>  </div></div><br>