Package: celerabit-pipeline-integration
CELERABIT PIPELINE INTEGRATION TOOLSThis package helps to integrate CI/CD processes withcelerabit platformREQUIEREMENTSNone.USAGEpython -m celerabitpipelineintegration <operation> [ags] [<flags>]OperationauthenticateGenerates anauthentication token.  This token will be input for secure operations.ExamplesGenerate authentication tokenpython-mcelerabitpipelineintegrationauthenticatelogin"myemail@mydomain.com"password"secretpassword"You must replacemyemail@mydomain.comandsecretpasswordfor your valid credentials in celerabit platform.
The Output of this operation is an alphanumeric token like this:eyJhbGciOiJIUzI1NiIsInR5cCI6Ikicm9sZXMiOm51bGx9LCJpYXQiOjE2NzIyNTQyMDAsImV4cCI6MTY3MjI2MTQwMH0cWBm8Iua2sUFkHbr89epcfN9EtwBDKtqoLMUtdXJSkOperationrunThis operation runs a performance testing scenario and waitwait for it to finish.ExamplesRuns a scenario and waits for the execution to finish. If the scenario has not finished in 120 seconds (2 minutes), it will throw an exception.python-mcelerabitpipelineintegrationruntoken"nR5cCI6Ikicm9sZXMiOm51bGYXQiOjE2NzIyNDAsImV4cCI6MTY3MjI2MTQwMH0"client"My client Name"application"My application Name"scenario"My scenario code"timeout120You must replacenR5cCI6Ikicm9sZXMiOm51bGx9LCJpYXQiOjE2NzIyNTQyMDAsImV4cCI6MTY3MjI2MTQwMH0for a valid authentication token,My client Namefor your client name in celerabit platform,My application Namefor the name of the application in celerabit platform aich the scneario belongs to, andMy scenario codefor the code of the existing scenario that you want to run.Ifsilent modeis needed to avoid verbose info messages, you can add the flag-qat the end of the execution command line.Note that previous command specifies atimeoutthis means: if scenario execution takes more than 120 seconds (timeout 120), commnadpython -m celerabitpipelineintegration runwill fail.The output of the command is a json object that specifies the new job id:{
    "jobId": 1158298, 
    "status": "SUCCESS", 
    "dateCreated": "2023-01-01T17:01:01.851Z", 
    "duration": 178.913196, 
    "kpiLatency": 3000, 
    "kpiErrors": 5, 
    "kpiThroughput": 100, 
    "kpiDeviation": 3000, 
    "metricLatency": 27.74, 
    "metricErrors": 0.35, 
    "metricThroughput": 1659057.06, 
    "metricDeviation": 52.36, 
    "complianceLatency": 199.08, 
    "complianceErrors": 192.94, 
    "complianceThroughput": 200, 
    "complianceDeviation": 198.25
}Ih this response:AttributeTypeDescriptionjobIdJob InfoId corresponding the new created job for this scenario run.statusJob InfoIndicates if the job finished inSUCCESSorERRORstatus.dateCreatedJob InfoDate and time the job starts its execution.durationJob InfoIndicates the seconds the job took to finalize.kpiLatencyKPIObjective value defined for the scenario average latency.kpiErrorsKPIObjective value defined for the scenario errors percentage.kpiThroughputKPIObjective value defined for the scenario capacity (requests attended per minute).kpiDeviationKPIObjective value defined for the standard deviation for scenario average latency.metricLatencyMetricMeasured value for the scenario average latency in this run (For thisjobId).metricErrorsMetricMeasured value for the scenario errors percentage in this run (For thisjobId).metricThroughputMetricMeasured value for the capacity (requests attended per minute) in this run (For thisjobId).metricDeviationMetricMeasured value for the standard deviation for scenario average latency in this run (For thisjobId).complianceLatencyComplianceLatency compliance (latency metric vs latency KPI).complianceErrorsComplianceErrors percentage compliance (Errors percentage metric vs Errors percentage KPI).complianceThroughputComplianceCapacity compliance (Capacity metric vs Capacity KPI).complianceDeviationComplianceDeviation compliance (Deviation metric vs Deviation KPI).Operationeval-job-resultsReceives the json structure resulting from executing a scenario and evaluates its compliance by giving a tolerance level.ExamplesReceive the json structure resulting of executing an scenario and evaluates its compliance giving a tolerance level.python-mcelerabitpipelineintegrationeval-job-resultsjob-result"$EXEC_RESULT"tolerance"latency=0.8,throughput=0.5,errors=0.95,deviation=0.2"The output of this command is an string with the compliance validation errors.  If there is not, the string will be empty.In this example, theEXEC_RESULTvariable contains thejsonstructure returned by using therunoperation.  The values sent in thetoleranceparameter specify the minimum percentage of compliance accepted for the executed scenario.  For the example:Performance dimensionTolerance (Minimun compliance)latency0.8(80%)throughput0.5(50%)errors0.95(95%)deviation0.2(20%)If no tolerance value is specified for a performance dimension (Latency, Throughput, errors, deviation), the default tolerance would be zero. It means that a minimum compliance of 100% will be evaluated.Operationlast-statusThis operation returns the details of the last job execution for a given scenario.Examplespython-mcelerabitpipelineintegrationlast-statustoken"nR5cCI6Ikicm9sZXMiOm51bGYXQiOjE2NzIyNDAsImV4cCI6MTY3MjI2MTQwMH0"client"My client Name"application"My application Name"scenario"My scenario code"You must replacenR5cCI6Ikicm9sZXMiOm51bGx9LCJpYXQiOjE2NzIyNTQyMDAsImV4cCI6MTY3MjI2MTQwMH0for a valid authentication token,My client Namefor your client name in celerabit platform,My application Namefor the name of the application in celerabit platform aich the scneario belongs to, andMy scenario codefor the code of the existing scenario that you want to run.The output of this operation is same asrunoperation.