Skip to content

Resources for threaded comms #1217

Description

@shuds13

When threading is used for running workers (or if used just for generator), a modification is necessary for resources to work.

The resources object is held as a class attribute in Resources, which has a copy on each worker. This object contains the attribute self.worker_resources which contains the resource sets assigned to the current worker at a any point in time and is updated during the run. Currently, when using threads, this will be a single object and updated each time any worker updates it's resource sets.

One solution could be that when using threads, an array is used for self.worker_resources, and each worker points to it's own part of the array. If just running a generator on a thread, then there may be a self.gen_resources used.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions