-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.0.27
-
Component/s: None
-
Labels:
-
Empty show more show less
Should we call GridStore.open() before using GridStore.stream() ?
Currently the code has inconsistent behavior:
- stream.pipe() calls gs.open() itself (even if already open, is it an issue? at least no visible issue, maybe just useless server queries)
- stream.write() calls gs.open() if not already open (checks gs.isOpen)
- stream._read() never calls gs.open(): if we don't call it manually, and don't use stream.pipe() it will break (see attached files)
Since we probably don't want to break anything, I think it would be best to add open if not yet open on all methods of GridStoreStream, for consistency; or document the fact that it's required to open the file, and remove useless open() (at least in pipe()).