[Vala] DBus Server and Thread



Hi all,

I'm writing a dbus server and a client in Vala and I'm facing some trouble.

Because I have a function which can takes a long time to run, I created a method in the server which launches a thread and returns without waiting for the thread to finish.

This long running function sends progress signals and all works well, the client can call the method and connect to signals.

The problem is when the client try to call another method when the long running thread hasn't finished. The client hangs up because the server doesn't send a response. I always have the no response timeout error.

I expected that launching my long running function in a thread would make the dbus server responsive but it's not the case.

Can someone tell me what is the problem and how to solve it?

Regards,

Guillaume.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]