Brooklyn

brooklyn.entity.nosql.cassandra
[Java] Class CassandraNodeImpl

java.lang.Object
  brooklyn.entity.basic.AbstractEntity
      brooklyn.entity.basic.SoftwareProcessImpl
          brooklyn.entity.nosql.cassandra.CassandraNodeImpl
All Implemented Interfaces:
CassandraNode

public class CassandraNodeImpl
extends SoftwareProcessImpl

Implementation of CassandraNode.


Field Summary
 
Fields inherited from class SoftwareProcessImpl
connectedSensors
 
Fields inherited from class AbstractEntity
EFFECTOR_ADDED, EFFECTOR_CHANGED, EFFECTOR_REMOVED, LOG, POLICY_ADDED, POLICY_REMOVED, SENSOR_ADDED, SENSOR_REMOVED, _subscriptionTracker, managementSupport, tempWorkings
 
Constructor Summary
CassandraNodeImpl()

 
Method Summary
protected void connectEnrichers()

protected void connectEnrichers(Duration windowPeriod)

protected void connectSensors()

void disconnectSensors()

java.lang.String getBroadcastAddress()

java.lang.String getClusterName()

java.lang.String getDatacenterName()

CassandraNodeDriver getDriver()

java.lang.Class getDriverInterface()

java.lang.Integer getGossipPort()

java.lang.String getListenAddress()

java.lang.String getPrivateIp()

java.lang.String getPublicIp()

java.lang.String getRackName()

java.lang.String getSeeds()

java.lang.Integer getSslGossipPort()

java.lang.Integer getThriftPort()

java.lang.Long getToken()

void init()

protected boolean requiresAlwaysPublicIp()

Some clouds (e.g.

void setToken(java.lang.String token)

 
Methods inherited from class SoftwareProcessImpl
callRebindHooks, callStartHooks, checkModifiable, connectSensors, connectServiceUpIsRunning, disconnectSensors, disconnectServiceUpIsRunning, doInitDriver, doRestart, doStart, doStop, getDriver, getLocalHostname, getMachineOrNull, getProvisioningFlags, getProvisioningLocation, getRequiredOpenPorts, newDriver, obtainProvisioningFlags, onManagementStarted, onManagementStarting, postDriverStart, postRebind, postStart, preStart, preStop, rebind, restart, setProvisioningLocation, start, startInLocation, startInLocation, startInLocation, startInLocation, stop, waitForEntityStart, waitForServiceUp, waitForServiceUp, waitForServiceUp, waitForServiceUp
 
Methods inherited from class AbstractEntity
addChild, addChild, addEnricher, addGroup, addLocations, addPolicy, clearLocations, clearParent, configure, configure, configure, configure, configure, configure, destroy, emit, emitInternal, equals, finalize, firstLocation, getAllAttributes, getAllConfig, getApplication, getApplicationId, getAttribute, getAttributeByNameParts, getChildren, getConfig, getConfig, getConfig, getConfig, getConfigMap, getCreationTime, getDisplayName, getEffector, getEnrichers, getEntityManager, getEntityType, getEntityTypeName, getExecutionContext, getGroups, getIconUrl, getId, getLocations, getManagementContext, getManagementSupport, getMutableEntityType, getParent, getPolicies, getProxy, getProxyIfAvailable, getRebindSupport, getSubscriptionContext, getSubscriptionTracker, hashCode, init, invalidateReferences, invoke, invoke, invoke, isLegacyConstruction, onManagementBecomingMaster, onManagementNoLongerMaster, onManagementStarted, onManagementStarting, onManagementStopped, refreshInheritedConfig, removeAllEnrichers, removeAllPolicies, removeAttribute, removeChild, removeEnricher, removeLocations, removePolicy, setApplication, setAttribute, setAttribute, setAttributeWithoutPublishing, setConfig, setConfig, setConfig, setConfig, setConfig, setConfig, setConfigEvenIfOwned, setConfigEvenIfOwned, setConfigIfValNonNull, setConfigIfValNonNull, setDisplayName, setManagementContext, setParent, setProxy, subscribe, subscribeToChildren, subscribeToMembers, toMetadataRecord, toString, toStringHelper, unsubscribe, unsubscribe
 

Constructor Detail

CassandraNodeImpl

public CassandraNodeImpl()


 
Method Detail

connectEnrichers

protected void connectEnrichers()


connectEnrichers

protected void connectEnrichers(Duration windowPeriod)


connectSensors

.entity(this)
.period(3000, TimeUnit.MILLISECONDS)
protected void connectSensors()


disconnectSensors

public void setToken(String token) {
public void disconnectSensors()


getBroadcastAddress

@Override
public java.lang.String getBroadcastAddress()


getClusterName

@Override
public java.lang.String getClusterName()


getDatacenterName

public java.lang.String getDatacenterName()


getDriver

public CassandraNodeDriver getDriver()


getDriverInterface

}
public java.lang.Class getDriverInterface()


getGossipPort

@Override
public java.lang.Integer getGossipPort()


getListenAddress

@Override
public java.lang.String getListenAddress()


getPrivateIp

public java.lang.String getPrivateIp()


getPublicIp

public java.lang.String getPublicIp()


getRackName

public java.lang.String getRackName()


getSeeds

lo
public java.lang.String getSeeds()


getSslGossipPort

@Override
public java.lang.Integer getSslGossipPort()


getThriftPort

@Override
public java.lang.Integer getThriftPort()


getToken

@Override
public java.lang.Long getToken()


init

private JmxHelper jmxHelper;
public void init()


requiresAlwaysPublicIp

protected boolean requiresAlwaysPublicIp()
Some clouds (e.g. Rackspace) give us VMs that have two nics: one for private and one for public. If the private IP is used then it doesn't work, even for a cluster purely internal to Rackspace! TODO Need to investigate that further, e.g.: - is `openIptables` opening it up for both interfaces? - for aws->rackspace comms between nodes (thus using the public IP), will it be listening on an accessible port? FIXME Really ugly code; surely can do better?!
Returns:


setToken

}
public void setToken(java.lang.String token)


 

Brooklyn Multi-Cloud Application Management Platform
brooklyncentral.github.com. Apache License. © 2012.