This is an automatically generated e-mail. To reply, visit: http://reviewboard-openlmi.rhcloud.com/r/187/

src/python/openlmi/common/JobManager.py (Diff revision 1)
def execute(self):
380
                    % str(error))
Try to avoid using % to format string for log messages. It enforces formatting before the log function is called and thus slows down the execution, when logging is suppressed.

src/python/openlmi/common/JobManager.py (Diff revision 1)
def get_post_call(self):
514
                    keybindings={},
I would avoid this assignment. The default for path.keybindings is pywbem.NocaseDict, which does lowercase key comparisons. With this plain dictionary the whole path behaves differently and you have to bare it in mind, when using it afterwards.

src/python/openlmi/common/JobManager.py (Diff revision 1)
def send_modify_indications(self, prev_instance, current_instance,
776
        cmpi_logging.logger.debug("Removing job %s: '%s'"
807
        # We cannot log here, this method is executed in job's Timer thread,
Maybe it's better to prevent logging by using different logger like:
  logging.getLogger('openlmi.separate_thread')

which could have logging suppressed (runtime) or redirected to file (when debugging).

- Michal


On April 12th, 2013, 2:13 p.m. UTC, Jan Safranek wrote:

Review request for OpenLMI Developers.
By Jan Safranek.

Updated April 12, 2013, 2:13 p.m.

Repository: openlmi-providers

Description

Synchronize JobManager with storage.

JobManager here is older version of the one in openlmi-storage.
Let's sync it with the storage so I can use it from there.

The patch includes:

Fixed job expiration under SFCB.
Added LMI_StorageJob.JobInParameters and .JobOutParameters properties.
Allow python to exit the provider even if there are threads running.
Fixed job returning an error
Added possibility to set AffectedElements when a job finishes.
Added workaround for rhbz#920763

Diffs

  • src/python/openlmi/common/JobManager.py (a923f296d3eba40f1997a267b68525a44f50ffc7)

View Diff