Examples of ping()


Examples of org.teiid.client.security.ILogon.ping()

      }, "foo"); //$NON-NLS-1$
    csr.registerClientService(FakeService.class, new FakeServiceImpl(), "foo"); //$NON-NLS-1$
    final FakeClientServerInstance serverInstance = new FakeClientServerInstance(csr);
    SocketServerConnection connection = createFakeConnection(serverInstance);
    ILogon logon = connection.getService(ILogon.class);
    Future<?> result = logon.ping();
    assertNull(result.get(0, TimeUnit.MILLISECONDS));
    result = logon.logoff();
    try {
      result.get(0, TimeUnit.MICROSECONDS);
      fail("exception expected"); //$NON-NLS-1$
View Full Code Here

Examples of org.tempuri.IPingServiceContract.ping()

                            portPrefix
                        ),
                        IPingServiceContract.class
                    );
              
                final String output = port.ping(INPUT);
                if (!INPUT.equals(output)) {
                    System.err.println(
                        "Expected " + INPUT + " but got " + output
                    );
                    results.add("Unexpected output " + output);
View Full Code Here

Examples of org.xmlBlaster.client.I_XmlBlasterAccess.ping()

         xb = getXmlBlasterAccess();
      } catch (XmlBlasterException e) {
         e.printStackTrace();
      }
      if (xb != null)
         xb.ping();
   }

   /**
    * On first invocation we connect to the other xmlBlaster cluster node.
    * <p />
View Full Code Here

Examples of org.xmlBlaster.protocol.corba.clientIdl.BlasterCallback.ping()

   {
      if (log.isLoggable(Level.FINER)) log.finer("ping client");
      try {
         BlasterCallback bcb = this.cb; // can be null during startup from persistence
         if (bcb != null)
            return bcb.ping(qos);
         else
            throw new XmlBlasterException(glob, ErrorCode.COMMUNICATION_NOCONNECTION, ME,
                  "CORBA callback ping failed, no callback handle is available");
      } catch (Throwable e) {
         throw new XmlBlasterException(glob, ErrorCode.COMMUNICATION_NOCONNECTION, ME,
View Full Code Here

Examples of org.xmlBlaster.util.protocol.socket.SocketExecutor.ping()

      SocketExecutor se = this.handler;
      if (se == null)
         throw new XmlBlasterException(glob, ErrorCode.COMMUNICATION_NOCONNECTION, ME,
                  "SOCKET callback ping failed, handler is null");
      try {
         return se.ping(qos);
      } catch (Throwable e) {
         throw new XmlBlasterException(glob, ErrorCode.COMMUNICATION_NOCONNECTION, ME,
                     "CallbackSocketDriver " + getType() + " callback ping failed", e);
      }
   }
View Full Code Here

Examples of redis.clients.jedis.BinaryJedis.ping()

  @Override
  public boolean validateObject(PooledObject<Jedis> pooledJedis) {
    final BinaryJedis jedis = pooledJedis.getObject();
    try {
      return jedis.isConnected() && jedis.ping().equals("PONG");
    } catch (final Exception e) {
      return false;
    }
  }
}
View Full Code Here

Examples of redis.clients.jedis.Jedis.ping()

  assertEquals("PONG", beforeFailoverJedis.ping());

  waitForFailover(pool, oldMaster);

  Jedis afterFailoverJedis = pool.getResource();
  assertEquals("PONG", afterFailoverJedis.ping());
  assertEquals("foobared", afterFailoverJedis.configGet("requirepass")
    .get(1));
  assertEquals(2, afterFailoverJedis.getDB().intValue());

  // returning both connections to the pool should not throw
View Full Code Here

Examples of redis.clients.jedis.Jedis.ping()

  Jedis j = new Jedis("localhost", 6380);
  j.auth("foobared");
  j.select(2);
  j.set("foo", "bar");
  Jedis jedis = new Jedis("redis://:foobared@localhost:6380/2");
  assertEquals("PONG", jedis.ping());
  assertEquals("bar", jedis.get("foo"));
    }

    @Test
    public void startWithUrl() throws URISyntaxException {
View Full Code Here

Examples of redis.clients.jedis.Jedis.ping()

  Jedis j = new Jedis("localhost", 6380);
  j.auth("foobared");
  j.select(2);
  j.set("foo", "bar");
  Jedis jedis = new Jedis(new URI("redis://:foobared@localhost:6380/2"));
  assertEquals("PONG", jedis.ping());
  assertEquals("bar", jedis.get("foo"));
    }

    @Test
    public void allowUrlWithNoDBAndNoPassword() {
View Full Code Here

Examples of redis.clients.jedis.JedisCluster.ping()

    @Test(expected = JedisClusterException.class)
    public void testThrowExceptionWithoutKey() {
  Set<HostAndPort> jedisClusterNode = new HashSet<HostAndPort>();
  jedisClusterNode.add(new HostAndPort("127.0.0.1", 7379));
  JedisCluster jc = new JedisCluster(jedisClusterNode);
  jc.ping();
    }

    @Test(expected = JedisClusterMaxRedirectionsException.class)
    public void testRedisClusterMaxRedirections() {
  Set<HostAndPort> jedisClusterNode = new HashSet<HostAndPort>();
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.