def load(self, *args, **kwargs):
try:<EOL><INDENT>self.acquire_lock()<EOL>return self._storage_service.load(*args, **kwargs)<EOL><DEDENT>finally:<EOL><INDENT>if self.lock is not None:<EOL><INDENT>try:<EOL><INDENT>self.release_lock()<EOL><DEDENT>except RuntimeError:<EOL><INDENT>self._logger.error('<STR_LIT>' % str(self.lock))<EOL><DEDENT><DEDENT><DEDENT>
Acquires a lock before loading and releases it afterwards.