Class SimpleResourceUnit
java.lang.Object
org.apache.pulsar.broker.loadbalance.impl.SimpleResourceUnit
- All Implemented Interfaces:
Comparable<ResourceUnit>,ResourceUnit
-
Field Summary
Fields inherited from interface org.apache.pulsar.broker.loadbalance.ResourceUnit
PROPERTY_KEY_BROKER_ZNODE_NAME -
Constructor Summary
ConstructorsConstructorDescriptionSimpleResourceUnit(String resourceId, ResourceDescription resourceDescription) SimpleResourceUnit(String resourceId, ResourceDescription resourceDescription, Map<String, Object> properties) -
Method Summary
Modifier and TypeMethodDescriptionbooleancanFit(ResourceDescription resourceDescription) intbooleangetProperty(String key) inthashCode()toString()
-
Constructor Details
-
SimpleResourceUnit
-
SimpleResourceUnit
public SimpleResourceUnit(String resourceId, ResourceDescription resourceDescription, Map<String, Object> properties)
-
-
Method Details
-
getResourceId
- Specified by:
getResourceIdin interfaceResourceUnit
-
getAvailableResource
- Specified by:
getAvailableResourcein interfaceResourceUnit
-
canFit
- Specified by:
canFitin interfaceResourceUnit
-
getProperty
- Specified by:
getPropertyin interfaceResourceUnit
-
compareTo
- Specified by:
compareToin interfaceComparable<ResourceUnit>
-
equals
-
hashCode
public int hashCode() -
toString
-