[ome-users] BlitzGateway: keep connection alive to write large ROIs
Paul Korir
pkorir at ebi.ac.uk
Mon Apr 24 09:44:16 BST 2017
Dear OMERO Users/Developers,
I'm writing a client application which connects to an OMERO server
through a BlitzGateway object but I get a lost-connection exception.
Could someone please advise me on how to keep a connection open? The
snippet of code is roughly the following:
conn = omero.gateway.BlitzGateway(...)
roi = <some large ROI object>
conn.getUpdateService().saveObject(roi)
Please see the traceback below:
Traceback (most recent call last):
File
"/Users/pkorir/omero/OMERO.server/lib/python/omero/gateway/__init__.py",
line 4212, in __call__
return self.f(*args, **kwargs)
File
"/Users/pkorir/omero/OMERO.server/lib/python/omero_api_IUpdate_ice.py",
line 131, in saveAndReturnObject
return _M_omero.api.IUpdate._op_saveAndReturnObject.invoke(self,
((obj, ), _ctx))
ConnectionLostException: Ice.ConnectionLostException:
Broken pipe
Fri Apr 21 17:02:55 2017 Closing the connection...
Fri Apr 21 17:02:55 2017 Deleting ROIHandler instance... OK
WARNING:omero.client:Cannot get session service for killSession. Using
closeSession
Fri Apr 21 17:02:55 2017 Connection closed.
Traceback (most recent call last):
File "/Users/pkorir/VirtualEnvs/sfftk/bin/sffp", line 11, in <module>
load_entry_point('sfftk-plus', 'console_scripts', 'sffp')()
File
"/Users/pkorir/Documents/workspace/bioimaging-scripts/trunk/sfftk-plus/sfftkplus/sffplus.py",
line 460, in main
return handle_attachroi(args)
File
"/Users/pkorir/Documents/workspace/bioimaging-scripts/trunk/sfftk-plus/sfftkplus/sffplus.py",
line 381, in handle_attachroi
omero_connection.saveRoi(roi)
File
"/Users/pkorir/Documents/workspace/bioimaging-scripts/trunk/sfftk-plus/sfftkplus/omero/handlers.py",
line 149, in saveRoi
self.conn.getUpdateService().saveAndReturnObject(roi)
File
"/Users/pkorir/omero/OMERO.server/lib/python/omero/gateway/__init__.py",
line 4215, in __call__
return self.handle_exception(e, *args, **kwargs)
File
"/Users/pkorir/omero/OMERO.server/lib/python/omero/gateway/__init__.py",
line 4212, in __call__
return self.f(*args, **kwargs)
File
"/Users/pkorir/omero/OMERO.server/lib/python/omero_api_IUpdate_ice.py",
line 131, in saveAndReturnObject
return _M_omero.api.IUpdate._op_saveAndReturnObject.invoke(self,
((obj, ), _ctx))
Ice.ConnectionLostException: Ice.ConnectionLostException:
Broken pipe
--
Paul K. Korir, PhD
Scientific Programmer
EMBL-EBI
01223494422
More information about the ome-users
mailing list