Package com.linkedin.databus.client

Examples of com.linkedin.databus.client.DbusPartitionInfoImpl


  @Override
  public synchronized void onGainedPartitionOwnership(int partition)
  {
    _log.info("Partition (" + partition + ") getting added !!");

    DbusPartitionInfo partitionInfo = new DbusPartitionInfoImpl(partition);
    try {
      addPartition(partitionInfo);
    } catch (DatabusClientException e) {
      _log.error("Unable to add partition. Shutting down the cluster !!", e);
      deregister();
View Full Code Here


  @Override
  public synchronized void onLostPartitionOwnership(int partition)
  {
    _log.info("Partition (" + partition + ") getting removed !!");

    DbusPartitionInfo partitionInfo = new DbusPartitionInfoImpl(partition);
    try {
      dropOnePartition(partitionInfo);
    } catch (DatabusException e) {
      _log.error("Unable to drop partition. Shutting down the cluster !!", e);
      deregister();
View Full Code Here

        Map<PhysicalPartition, DatabusV3Registration> childRegs =
            ((DatabusV3MultiPartitionRegistration) r).getPartionRegs();
        childR = new HashMap<DbusPartitionInfo, RegInfo>();
        for (Entry<PhysicalPartition, DatabusV3Registration> e2 : childRegs.entrySet())
        {
          childR.put(new DbusPartitionInfoImpl(e2.getKey().getId()),
                     new RegInfo(e.getValue().getState().name(),
                                 e.getValue().getRegistrationId(),
                                 e.getValue().getStatus(),
                                 null,
                                 e.getValue().getSubscriptions()));
View Full Code Here

   *           When cluster or partition is not hosted in this instance.
   */
  private RegInfo getV2PartitionRegistration(String cluster, long partition) throws RequestProcessingException
  {
    DatabusV2ClusterRegistrationImpl reg = getV2ClusterRegistration(cluster);
    DbusPartitionInfo p = new DbusPartitionInfoImpl(partition);
    DatabusRegistration r = reg.getPartitionRegs().get(p);

    if (null == r)
      throw new RequestProcessingException("Partition(" + partition + ") for cluster ("
          + cluster + ") not found !!");
View Full Code Here

TOP

Related Classes of com.linkedin.databus.client.DbusPartitionInfoImpl

Copyright © 2018 www.massapicom. 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.