ValueLengthRule

com.netflix.atlas.core.validation.ValueLengthRule
See theValueLengthRule companion object
case class ValueLengthRule(minLength: Int, maxLength: Int) extends TagRule

Verifies that the values are within the specified length bounds. Sample config:

min-length = 2
max-length = 60

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait TagRule
trait Rule
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def validate(k: String, v: String): String

Check the key/value pair and return null if it is valid or a reason string if there is a validation failure. The null type for success is used to avoid allocations or other overhead since the validation checks tend to be a hot path.

Check the key/value pair and return null if it is valid or a reason string if there is a validation failure. The null type for success is used to avoid allocations or other overhead since the validation checks tend to be a hot path.

Attributes

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product
override def validate(id: Id): ValidationResult

Validates that the id matches the rule.

Validates that the id matches the rule.

Attributes

Definition Classes
Inherited from:
TagRule
override def validate(tags: SortedTagMap): ValidationResult

Validates that the tag map matches the rule.

Validates that the tag map matches the rule.

Attributes

Definition Classes
Inherited from:
TagRule
override def validate(tags: SmallHashMap[String, String]): ValidationResult

Validates that the tag map matches the rule.

Validates that the tag map matches the rule.

Attributes

Definition Classes
Inherited from:
TagRule
def validate(tags: Map[String, String]): ValidationResult

Validates that the tag map matches the rule.

Validates that the tag map matches the rule.

Attributes

Inherited from:
Rule