Package org.apache.jackrabbit.oak.plugins.segment

Examples of org.apache.jackrabbit.oak.plugins.segment.Segment.writeTo()


            response.sendError(HttpServletResponse.SC_NOT_FOUND);
            return;
        }

        response.setContentType("application/octet-stream");
        segment.writeTo(response.getOutputStream());
    }

    private void doPutSegment(
            String info,
            HttpServletRequest request, HttpServletResponse response)
View Full Code Here


            response.sendError(HttpServletResponse.SC_NOT_FOUND);
            return;
        }

        response.setContentType("application/octet-stream");
        segment.writeTo(response.getOutputStream());
    }

    private void doPutSegment(
            String info,
            HttpServletRequest request, HttpServletResponse response)
View Full Code Here

                    }

                    log.debug("did reread locally corrupt segment " + id + " with size " + s.size());
                    ByteArrayOutputStream bout = new ByteArrayOutputStream(s.size());
                    try {
                        s.writeTo(bout);
                    }
                    catch (IOException f) {
                        log.error("can't wrap segment to output stream", f);
                        throw e;
                    }
View Full Code Here

                            s.size());
                    if (id.isDataSegmentId()) {
                        ids.addAll(s.getReferencedIds());
                    }
                    try {
                        s.writeTo(bout);
                        writeSegment(id, bout.toByteArray(), 0, s.size());
                    } catch (IOException e) {
                        throw new IllegalStateException(
                                "Unable to write remote segment " + id, e);
                    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.