Best way to start background processes

Hello,

I’ve got a bunch of long operations which I want to start in the background to avoid blocking the UI, but I’m a little confused about the appropriate way to achieve this. I first tried with the headless client; unfortunately, I need to switch the database to a DEMO one in some cases, but the opened solution would not call the onOpen method: am I doing something wrong?
As a second try I moved to the scheduler plugin. However I’m starting to think it just does not start any real new thread in the end, since without a little delay in the start date for the job the UI still freezes. Is it correct or again that’s entirely my fault?

What would be the “right” way of doing what I need? This kind of simple things made kind of hard really annoy me, if I must be sincere…

As a side note, at the risk of appearing rude, I think you guys should really improve the documentation (I know it’s boring, but that’s what we’re looking at before coming here bothering you, so it’s a win-win ;))

studiomiazzo:
I first tried with the headless client; unfortunately, I need to switch the database to a DEMO one in some cases, but the opened solution would not call the onOpen method: am I doing something wrong?

I’ve used this successful in various situations using the headless client plugin.
The plugin even has a parameter reserved to pass arguments to the solution…

Can you explain how you tested the headless client?
If you did this from the developer, this would directly be the explanation why the onOpenSolution method isn’t triggered…

mboegem:

studiomiazzo:
I first tried with the headless client; unfortunately, I need to switch the database to a DEMO one in some cases, but the opened solution would not call the onOpen method: am I doing something wrong?

I’ve used this successful in various situations using the headless client plugin.
The plugin even has a parameter reserved to pass arguments to the solution…

Can you explain how you tested the headless client?
If you did this from the developer, this would directly be the explanation why the onOpenSolution method isn’t triggered…

Mmm…iirc the same was happening even when publishing the solution (I can tell it since the DEMO data are extremely different and recognizeable). But I’m not 100% sure. I’ll try that first, thanks.

Btw, starting the app server in the installation directory in a development machine should run exactly the same as a production one, right? Modulo the configuration, of course, but I’m interested in behaviour wrt headless client and such.