if(!node.getSession().isLive()) {
log.warn("Session closed, unable to flush stream");
} else {
// Create node that will store the stream
final String streamNodePath = node.getPath() + "/" + streamPath.getNodePath();
final Node streamNode = new DeepNodeCreator().deepCreateNode(streamNodePath,
node.getSession(), STREAM_NODE_TYPE);
streamNode.setProperty(NodeStreamPath.PROPERTY_NAME,
new ByteArrayInputStream(buffer.toByteArray()));
log.debug("Saved {} bytes to Property {}", buffer.size(),