Skip to content

Support async jobs #91

@swarmshine

Description

@swarmshine
interface DistributedJob{
   void run(context: Context)
}

currently supports sync launching and execution.
Actually there are many cases when jon maintain it's own thread pool and execute work items in async way

void run(context: Context){
    context.workShare.map{ processAsync(it) }.forEach{ it.join()}
}

This leads to wasting resources for extra Threads.
Solution is to support async job invocation

interface DistributedAsyncJob{
   CompletableFuture<Void> run(context: Context)
}
`` 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions