Record Class DatabaseActivity.Work
java.lang.Object
java.lang.Record
com.vaadin.observability.micrometer.DatabaseActivity.Work
- Record Components:
queries- queries executed,-1when not measuredrows- rows read from their result sets,-1when not measured
- Enclosing class:
DatabaseActivity
The JDBC work counted in one window: how many queries ran and how many
result-set rows they read.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final DatabaseActivity.WorkNo measurement: no instrumentation, or none on this thread. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanisKnown()longqueries()Returns the value of thequeriesrecord component.longrows()Returns the value of therowsrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
UNKNOWN
No measurement: no instrumentation, or none on this thread.
-
-
Constructor Details
-
Method Details
-
isKnown
public boolean isKnown()- Returns:
- whether this carries an actual measurement
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
queries
public long queries()Returns the value of thequeriesrecord component.- Returns:
- the value of the
queriesrecord component
-
rows
public long rows()Returns the value of therowsrecord component.- Returns:
- the value of the
rowsrecord component
-