Tabnine Logo
WireCommands$TableKeyDoesNotExist
Code IndexAdd Tabnine to your IDE (free)

How to use
WireCommands$TableKeyDoesNotExist
in
io.pravega.shared.protocol.netty

Best Java code snippets using io.pravega.shared.protocol.netty.WireCommands$TableKeyDoesNotExist (Showing top 7 results out of 315)

origin: pravega/pravega

order.verify(connection).send(new WireCommands.TableKeyDoesNotExist(3, streamSegmentName, "" ));
origin: pravega/pravega

} else if (u instanceof KeyNotExistsException) {
  log.warn(requestId, "Conditional update on Table segment '{}' failed as the key does not exist.", segment);
  invokeSafely(connection::send, new WireCommands.TableKeyDoesNotExist(requestId, segment, clientReplyStackTrace), failureHandler);
} else if (u instanceof BadKeyVersionException) {
  log.warn(requestId, "Conditional update on Table segment '{}' failed due to bad key version.", segment);
origin: pravega/pravega

factory.rp.tableKeyDoesNotExist(new WireCommands.TableKeyDoesNotExist(0, getQualifiedStreamSegmentName("", "", 0L), ""));
AssertExtensions.assertThrows("", result::join,
               ex -> ex instanceof WireCommandFailedException &&
origin: pravega/pravega

factory.rp.tableKeyDoesNotExist(new WireCommands.TableKeyDoesNotExist(0, getQualifiedStreamSegmentName("", "", 0L), ""));
AssertExtensions.assertThrows("", result::join,
               ex -> ex instanceof WireCommandFailedException &&
origin: pravega/pravega

@Test
public void testRemoveTableKeys() {
  MockConnectionFactory factory = new MockConnectionFactory();
  List<TableKey<byte[]>> keys = Arrays.asList(new TableKeyImpl<>("k".getBytes(), KeyVersion.NOT_EXISTS),
                        new TableKeyImpl<>("k1".getBytes(), KeyVersion.NOT_EXISTS));
  // On receiving TableKeysRemoved.
  CompletableFuture<Void> result = helper.removeTableKeys("", "", keys, new MockHostControllerStore(), factory, "",
                                    System.nanoTime());
  factory.rp.tableKeysRemoved(new WireCommands.TableKeysRemoved(0, getQualifiedStreamSegmentName("", "", 0L) ));
  assertTrue(Futures.await(result));
  // On receiving TableKeyDoesNotExist.
  result = helper.removeTableKeys("", "", keys, new MockHostControllerStore(), factory, "", System.nanoTime());
  factory.rp.tableKeyDoesNotExist(new WireCommands.TableKeyDoesNotExist(0, getQualifiedStreamSegmentName("", "", 0L), ""));
  assertTrue(Futures.await(result));
  // On receiving TableKeyBadVersion.
  result = helper.removeTableKeys("", "", keys, new MockHostControllerStore(), factory, "", System.nanoTime());
  factory.rp.tableKeyBadVersion(new WireCommands.TableKeyBadVersion(0, getQualifiedStreamSegmentName("", "", 0L), ""));
  AssertExtensions.assertThrows("", result::join,
                 ex -> ex instanceof WireCommandFailedException &&
                     (((WireCommandFailedException) ex).getReason() == WireCommandFailedException.Reason.TableKeyBadVersion));
  Supplier<CompletableFuture<?>> futureSupplier = () -> helper.removeTableKeys("", "", keys, new MockHostControllerStore(),
                                          factory, "", System.nanoTime());
  validateAuthTokenCheckFailed(factory, futureSupplier);
  validateWrongHost(factory, futureSupplier);
  validateConnectionDropped(factory, futureSupplier);
  validateProcessingFailure(factory, futureSupplier);
  validateNoSuchSegment(factory, futureSupplier);
}
origin: pravega/pravega

@Test
public void testKeyDoesNotExist() throws IOException {
  WireCommands.TableKeyDoesNotExist cmd = new WireCommands.TableKeyDoesNotExist(l, testString1, "");
  testCommand(cmd);
  assertTrue(cmd.isFailure());
}
origin: pravega/pravega

public static WireCommand readFrom(ByteBufInputStream in, int length) throws IOException {
  long requestId = in.readLong();
  String segment = in.readUTF();
  String serverStackTrace = in.readUTF();
  return new TableKeyDoesNotExist(requestId, segment, serverStackTrace);
}
io.pravega.shared.protocol.nettyWireCommands$TableKeyDoesNotExist

Most used methods

  • <init>
  • isFailure

Popular in Java

  • Making http requests using okhttp
  • compareTo (BigDecimal)
  • getSharedPreferences (Context)
  • getResourceAsStream (ClassLoader)
  • Kernel (java.awt.image)
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • BigDecimal (java.math)
    An immutable arbitrary-precision signed decimal.A value is represented by an arbitrary-precision "un
  • Map (java.util)
    A Map is a data structure consisting of a set of keys and values in which each key is mapped to a si
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now