throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " less than activeMark: " + Long.toHexString(activeMark) throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " greater than currentKey: " + Long.toHexString(currentKey)
/** * Replays log from the active mark forward to the current position. * * @param listener an object that implements ReplayListener interface. * @throws LogConfigurationException * most likely because the configured LogBuffer class cannot be found. * @see #replay(ReplayListener, long) */ public void replay(ReplayListener listener) throws LogConfigurationException { try { bmgr.replay(listener, lfmgr.activeMark, false); } catch (InvalidLogKeyException e) { // should not happen -- use assert to catch during development assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
/** * @see org.apache.activeio.journal.Journal#read(org.codehaus.activemq.journal.RecordLocation) */ public Packet read(RecordLocation location) throws InvalidRecordLocationException, IOException { try { LogRecord record = logger.get(null, toLong(location)); return new ByteArrayPacket(record.data); } catch (InvalidLogKeyException e) { throw new InvalidRecordLocationException(e.getMessage(), e); } catch (Exception e) { throw (IOException) new IOException("Journal write failed: " + e) .initCause(e); } }
/** * Replays log from the active mark forward to the current position. * * @param listener an object that implements ReplayListener interface. * @throws LogConfigurationException * most likely because the configured LogBuffer class cannot be found. * @see #replay(ReplayListener, long) */ public void replay(ReplayListener listener) throws LogConfigurationException { try { bmgr.replay(listener, lfmgr.activeMark, false); } catch (InvalidLogKeyException e) { // should not happen -- use assert to catch during development assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " less than activeMark: " + Long.toHexString(activeMark) throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " greater than currentKey: " + Long.toHexString(currentKey)
/** * @see org.apache.activeio.journal.Journal#setMark(org.codehaus.activemq.journal.RecordLocation, boolean) */ public void setMark(RecordLocation recordLocator, boolean force) throws InvalidRecordLocationException, IOException { try { long location = toLong(recordLocator); logger.mark(location, force); lastMark = recordLocator; } catch (InterruptedException e) { throw (InterruptedIOException) new InterruptedIOException() .initCause(e); } catch (IOException e) { throw e; } catch (InvalidLogKeyException e) { throw new InvalidRecordLocationException(e.getMessage(), e); } catch (Exception e) { throw (IOException) new IOException("Journal write failed: " + e) .initCause(e); } }
/** * Replays log from the active mark forward to the current position. * * @param listener an object that implements ReplayListener interface. * @throws LogConfigurationException * most likely because the configured LogBuffer class cannot be found. * @see #replay(ReplayListener, long) */ public void replay(ReplayListener listener) throws LogConfigurationException { try { bmgr.replay(listener, lfmgr.activeMark, false); } catch (InvalidLogKeyException e) { // should not happen -- use assert to catch during development assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " less than activeMark: " + Long.toHexString(activeMark) throw new InvalidLogKeyException( " key: " + Long.toHexString(key) + " greater than currentKey: " + Long.toHexString(currentKey)
/** * Replays log from the active mark forward to the current position. * * @param listener an object that implements ReplayListener interface. * @throws LogConfigurationException * most likely because the configured LogBuffer class cannot be found. * @see #replay(ReplayListener, long) */ public void replay(ReplayListener listener) throws LogConfigurationException { try { bmgr.replay(listener, lfmgr.activeMark, false); } catch (InvalidLogKeyException e) { // should not happen -- use assert to catch during development assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException(Long.toHexString(mark)); "] was not found in the log."; throw new InvalidLogKeyException(msg);
/** * Wrapp Logger#replay(ReplayListener) so we can * intercept onRecord() notifications to process * XACOMMIT and XACOMMITMOVED records. */ public void replay(ReplayListener listener) throws LogConfigurationException { try { this.replay(listener, getActiveMark()); } catch (InvalidLogKeyException e) { // should not happen assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException(Long.toHexString(mark)); "] was not found in the log."; throw new InvalidLogKeyException(msg);
/** * Wrapp Logger#replay(ReplayListener) so we can * intercept onRecord() notifications to process * XACOMMIT and XACOMMITMOVED records. */ public void replay(ReplayListener listener) throws LogConfigurationException { try { this.replay(listener, getActiveMark()); } catch (InvalidLogKeyException e) { // should not happen assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException(Long.toHexString(mark)); "] was not found in the log."; throw new InvalidLogKeyException(msg);
/** * Wrapp Logger#replay(ReplayListener) so we can * intercept onRecord() notifications to process * XACOMMIT and XACOMMITMOVED records. */ public void replay(ReplayListener listener) throws LogConfigurationException { try { this.replay(listener, getActiveMark()); } catch (InvalidLogKeyException e) { // should not happen assert false : "Unhandled InvalidLogKeyException" + e.toString(); } }
throw new InvalidLogKeyException(Long.toHexString(mark)); "] was not found in the log."; throw new InvalidLogKeyException(msg);
mark(newMark, true); // force = true } catch (InvalidLogKeyException e) { // should never happen System.err.println(e.toString()); Thread.yield(); } catch (LogClosedException e) { // should never happen
throw new InvalidLogKeyException(Long.toHexString(mark)); "activeMark is [" + Long.toHexString(lfm.activeMark) + "]"; throw new InvalidLogKeyException(msg); "] requested for replay was not found in the log."; throw new InvalidLogKeyException(msg);
mark(newMark, true); // force = true } catch (InvalidLogKeyException e) { // should never happen System.err.println(e.toString()); Thread.yield(); } catch (LogClosedException e) { // should never happen
throw new InvalidLogKeyException(Long.toHexString(mark)); "activeMark is [" + Long.toHexString(lfm.activeMark) + "]"; throw new InvalidLogKeyException(msg); "] requested for replay was not found in the log."; throw new InvalidLogKeyException(msg);