-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use a global DRMAA session #97
Conversation
per process) so multiple runner plugins can be active in the same runner (they all have to target the same DRMAA library, however). Also add locking to calls that modify the number of active jobs, as per the Python-drmaa documentation.
@jmchilton if the |
log.debug("Initializing DRMAA session from thread %s", threading.current_thread().name) | ||
DrmaaSession.session = session_constructor() | ||
DrmaaSession.session.initialize() | ||
DrmaaSession.session_count += 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to move up one level right? Otherwise it will only ever be 1.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes 😦
d815cc8
to
76080da
Compare
Only one active DRMAA session is possible per process. This allows multiple Galaxy runner plugins to be active in the same handler if Pulsar is being used as an embedded runner (they all have to target the same DRMAA library, however). Also add locking to calls that modify the number of active jobs, as per the Python-drmaa documentation.
See also galaxyproject/galaxy#2102