Package dev.dokimos.server.dto.v1
Record Class RegressionAlertPayload
java.lang.Object
java.lang.Record
dev.dokimos.server.dto.v1.RegressionAlertPayload
- Record Components:
projectName- the project the run belongs toexperimentId- the experiment the run belongs toexperimentName- the experiment namerunId- the candidate run that regressedbaselineRunId- the baseline run it was compared againstbaselinePassRate- the baseline run's pass ratecandidatePassRate- the candidate run's pass ratepassRateDelta- candidate minus baseline pass rate (negative on a regression)regressedCaseCount- the number of items that regressed
public record RegressionAlertPayload(String projectName, UUID experimentId, String experimentName, UUID runId, UUID baselineRunId, double baselinePassRate, double candidatePassRate, double passRateDelta, int regressedCaseCount)
extends Record
JSON body POSTed to a project's alert webhooks when a completed run regresses against its baseline.
Carries enough context to identify the regression without a follow-up API call.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of thebaselinePassRaterecord component.Returns the value of thebaselineRunIdrecord component.doubleReturns the value of thecandidatePassRaterecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theexperimentIdrecord component.Returns the value of theexperimentNamerecord component.final inthashCode()Returns a hash code value for this object.doubleReturns the value of thepassRateDeltarecord component.Returns the value of theprojectNamerecord component.intReturns the value of theregressedCaseCountrecord component.runId()Returns the value of therunIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RegressionAlertPayload
public RegressionAlertPayload(String projectName, UUID experimentId, String experimentName, UUID runId, UUID baselineRunId, double baselinePassRate, double candidatePassRate, double passRateDelta, int regressedCaseCount) Creates an instance of aRegressionAlertPayloadrecord class.- Parameters:
projectName- the value for theprojectNamerecord componentexperimentId- the value for theexperimentIdrecord componentexperimentName- the value for theexperimentNamerecord componentrunId- the value for therunIdrecord componentbaselineRunId- the value for thebaselineRunIdrecord componentbaselinePassRate- the value for thebaselinePassRaterecord componentcandidatePassRate- the value for thecandidatePassRaterecord componentpassRateDelta- the value for thepassRateDeltarecord componentregressedCaseCount- the value for theregressedCaseCountrecord component
-
-
Method Details
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
projectName
Returns the value of theprojectNamerecord component.- Returns:
- the value of the
projectNamerecord component
-
experimentId
Returns the value of theexperimentIdrecord component.- Returns:
- the value of the
experimentIdrecord component
-
experimentName
Returns the value of theexperimentNamerecord component.- Returns:
- the value of the
experimentNamerecord component
-
runId
Returns the value of therunIdrecord component.- Returns:
- the value of the
runIdrecord component
-
baselineRunId
Returns the value of thebaselineRunIdrecord component.- Returns:
- the value of the
baselineRunIdrecord component
-
baselinePassRate
public double baselinePassRate()Returns the value of thebaselinePassRaterecord component.- Returns:
- the value of the
baselinePassRaterecord component
-
candidatePassRate
public double candidatePassRate()Returns the value of thecandidatePassRaterecord component.- Returns:
- the value of the
candidatePassRaterecord component
-
passRateDelta
public double passRateDelta()Returns the value of thepassRateDeltarecord component.- Returns:
- the value of the
passRateDeltarecord component
-
regressedCaseCount
public int regressedCaseCount()Returns the value of theregressedCaseCountrecord component.- Returns:
- the value of the
regressedCaseCountrecord component
-