Commit 7dd654cd authored by Daniel Seybold's avatar Daniel Seybold

added all common params for query execution

parent ccb47ff5
Pipeline #81090 passed with stage
in 28 minutes and 5 seconds
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* DBEndpoint
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class DBEndpoint {
@JsonProperty("ipAddress")
private String ipAddress = null;
......
......@@ -22,7 +22,7 @@ import javax.validation.constraints.*;
* a list of the database endpoints to issue the workload
*/
@ApiModel(description = "a list of the database endpoints to issue the workload")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class DBEndpoints extends java.util.ArrayList<DBEndpoint> {
@Override
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
/**
* DatabaseConfig
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class DatabaseConfig {
/**
* Gets or Sets databaseBinding
......
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* DatabaseConfigProperty
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class DatabaseConfigProperty {
@JsonProperty("name")
private String name = null;
......
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* Error
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class Error {
@JsonProperty("code")
private Integer code = null;
......
......@@ -24,7 +24,7 @@ import javax.validation.constraints.*;
/**
* MeasurementConfig
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class MeasurementConfig {
@JsonProperty("interval")
private Integer interval = null;
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
/**
* TPCCWorkload
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TPCCWorkload {
@JsonProperty("dbEndpoints")
private DBEndpoints dbEndpoints = null;
......
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* TPCCWorkloadConfig
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TPCCWorkloadConfig {
@JsonProperty("activeWarehouses")
private Integer activeWarehouses = null;
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
* parameters for the data generation phase
*/
@ApiModel(description = "parameters for the data generation phase")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSBSDataGeneration {
@JsonProperty("usecase")
private String usecase = null;
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
/**
* TSBSLoadExecution
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSBSLoadExecution {
@JsonProperty("workers")
private BigDecimal workers = null;
......
......@@ -25,11 +25,23 @@ import javax.validation.constraints.*;
/**
* TSBSQueryExecution
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSBSQueryExecution {
@JsonProperty("workers")
private BigDecimal workers = null;
@JsonProperty("burn-in")
private BigDecimal burnIn = null;
@JsonProperty("debug")
private Boolean debug = null;
@JsonProperty("print-interval")
private BigDecimal printInterval = null;
@JsonProperty("print-responses")
private Boolean printResponses = null;
@JsonProperty("dbmsPorperties")
private java.util.List<TSDBMSDBMSProperties> dbmsPorperties = null;
......@@ -52,6 +64,82 @@ public class TSBSQueryExecution {
this.workers = workers;
}
public TSBSQueryExecution burnIn(BigDecimal burnIn) {
this.burnIn = burnIn;
return this;
}
/**
* number of queries to ignore before collecting statistics
* @return burnIn
**/
@JsonProperty("burn-in")
@ApiModelProperty(example = "0.0", value = "number of queries to ignore before collecting statistics")
public BigDecimal getBurnIn() {
return burnIn;
}
public void setBurnIn(BigDecimal burnIn) {
this.burnIn = burnIn;
}
public TSBSQueryExecution debug(Boolean debug) {
this.debug = debug;
return this;
}
/**
* print debug messages
* @return debug
**/
@JsonProperty("debug")
@ApiModelProperty(example = "false", value = "print debug messages")
public Boolean isDebug() {
return debug;
}
public void setDebug(Boolean debug) {
this.debug = debug;
}
public TSBSQueryExecution printInterval(BigDecimal printInterval) {
this.printInterval = printInterval;
return this;
}
/**
* print timing stats to stderr after this many queries (0 to disable) (default 100)
* @return printInterval
**/
@JsonProperty("print-interval")
@ApiModelProperty(example = "100.0", value = "print timing stats to stderr after this many queries (0 to disable) (default 100)")
public BigDecimal getPrintInterval() {
return printInterval;
}
public void setPrintInterval(BigDecimal printInterval) {
this.printInterval = printInterval;
}
public TSBSQueryExecution printResponses(Boolean printResponses) {
this.printResponses = printResponses;
return this;
}
/**
* pretty print response bodies for correctness checking (default false)
* @return printResponses
**/
@JsonProperty("print-responses")
@ApiModelProperty(example = "false", value = "pretty print response bodies for correctness checking (default false)")
public Boolean isPrintResponses() {
return printResponses;
}
public void setPrintResponses(Boolean printResponses) {
this.printResponses = printResponses;
}
public TSBSQueryExecution dbmsPorperties(java.util.List<TSDBMSDBMSProperties> dbmsPorperties) {
this.dbmsPorperties = dbmsPorperties;
return this;
......@@ -90,12 +178,16 @@ public class TSBSQueryExecution {
}
TSBSQueryExecution tsBSQueryExecution = (TSBSQueryExecution) o;
return Objects.equals(this.workers, tsBSQueryExecution.workers) &&
Objects.equals(this.burnIn, tsBSQueryExecution.burnIn) &&
Objects.equals(this.debug, tsBSQueryExecution.debug) &&
Objects.equals(this.printInterval, tsBSQueryExecution.printInterval) &&
Objects.equals(this.printResponses, tsBSQueryExecution.printResponses) &&
Objects.equals(this.dbmsPorperties, tsBSQueryExecution.dbmsPorperties);
}
@Override
public int hashCode() {
return Objects.hash(workers, dbmsPorperties);
return Objects.hash(workers, burnIn, debug, printInterval, printResponses, dbmsPorperties);
}
......@@ -105,6 +197,10 @@ public class TSBSQueryExecution {
sb.append("class TSBSQueryExecution {\n");
sb.append(" workers: ").append(toIndentedString(workers)).append("\n");
sb.append(" burnIn: ").append(toIndentedString(burnIn)).append("\n");
sb.append(" debug: ").append(toIndentedString(debug)).append("\n");
sb.append(" printInterval: ").append(toIndentedString(printInterval)).append("\n");
sb.append(" printResponses: ").append(toIndentedString(printResponses)).append("\n");
sb.append(" dbmsPorperties: ").append(toIndentedString(dbmsPorperties)).append("\n");
sb.append("}");
return sb.toString();
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
* parameters for the query generation phase
*/
@ApiModel(description = "parameters for the query generation phase")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSBSQueryGeneration {
@JsonProperty("usecase")
private String usecase = null;
......
......@@ -29,7 +29,7 @@ import javax.validation.constraints.*;
/**
* TSBSWorkload
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSBSWorkload {
@JsonProperty("dbEndpoints")
private DBEndpoints dbEndpoints = null;
......
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* TSDBMSDBMSProperties
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class TSDBMSDBMSProperties {
@JsonProperty("name")
private String name = null;
......
......@@ -24,7 +24,7 @@ import javax.validation.constraints.*;
/**
* WorkloadConfig
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class WorkloadConfig {
/**
* Gets or Sets workloadType
......
......@@ -25,7 +25,7 @@ import javax.validation.constraints.*;
/**
* WorkloadProcessInstance
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class WorkloadProcessInstance {
@JsonProperty("processId")
private String processId = null;
......
......@@ -23,7 +23,7 @@ import javax.validation.constraints.*;
/**
* WorkloadProcessSubmissionError
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class WorkloadProcessSubmissionError {
@JsonProperty("message")
private String message = null;
......
......@@ -27,7 +27,7 @@ import javax.validation.constraints.*;
/**
* YCSBWorkload
*/
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class YCSBWorkload {
@JsonProperty("dbEndpoints")
private DBEndpoints dbEndpoints = null;
......
package de.uulm.omi.dbms.workload.api;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class ApiException extends Exception{
private int code;
public ApiException (int code, String msg) {
......
......@@ -5,7 +5,7 @@ import java.io.IOException;
import javax.servlet.*;
import javax.servlet.http.HttpServletResponse;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class ApiOriginFilter implements javax.servlet.Filter {
public void doFilter(ServletRequest request, ServletResponse response,
FilterChain chain) throws IOException, ServletException {
......
......@@ -3,7 +3,7 @@ package de.uulm.omi.dbms.workload.api;
import javax.xml.bind.annotation.XmlTransient;
@javax.xml.bind.annotation.XmlRootElement
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class ApiResponseMessage {
public static final int ERROR = 1;
public static final int WARNING = 2;
......
package de.uulm.omi.dbms.workload.api;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class NotFoundException extends ApiException {
private int code;
public NotFoundException (int code, String msg) {
......
package de.uulm.omi.dbms.workload.api;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class StringUtil {
/**
* Check if the given array contains the given value (with case-insensitive comparison).
......
......@@ -35,7 +35,7 @@ import javax.validation.constraints.*;
@Produces({ "application/json" })
@io.swagger.annotations.Api(description = "the workload API")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class WorkloadApi {
private final WorkloadApiService delegate;
......
......@@ -21,7 +21,7 @@ import java.io.InputStream;
import javax.ws.rs.core.Response;
import javax.ws.rs.core.SecurityContext;
import javax.validation.constraints.*;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public abstract class WorkloadApiService {
public abstract Response workloadResultGet( @NotNull String taskId, @NotNull String workloadType,SecurityContext securityContext) throws NotFoundException;
public abstract Response workloadStatusGet( String applicationInstanceId,SecurityContext securityContext) throws NotFoundException;
......
......@@ -3,7 +3,7 @@ package de.uulm.omi.dbms.workload.api.factories;
import de.uulm.omi.dbms.workload.api.WorkloadApiService;
import de.uulm.omi.dbms.workload.api.impl.WorkloadApiServiceImpl;
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-08T15:27:14.409+02:00")
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaJerseyServerCodegen", date = "2020-05-14T10:01:48.492+02:00")
public class WorkloadApiServiceFactory {
private final static WorkloadApiService service = new WorkloadApiServiceImpl();
......
......@@ -186,11 +186,30 @@ public class TSBSCommandBuilder {
String queriesCommand = "cat " + queryFolder + dbms.toString().toLowerCase() + "-queries.gz " + " | gunzip | " + binaryPath + "tsbs_run_queries_" + dbms.toString().toLowerCase() + " ";
//common parameters
if (tsbsQueryExecution.getWorkers() != null){
queriesCommand += "--workers=\"" + tsbsQueryExecution.getWorkers()+ "\" ";
if (tsbsQueryExecution.getWorkers() != null && tsbsQueryExecution.getWorkers().intValue() > 0){
queriesCommand += "--workers " + tsbsQueryExecution.getWorkers()+ " ";
}
else throw new IllegalArgumentException("Missing or incorrect --workers parameter!");
if (tsbsQueryExecution.getBurnIn() != null){
queriesCommand += "--burn-in " + tsbsQueryExecution.getBurnIn()+ " ";
}
else throw new IllegalArgumentException("Missing or incorrect --burn-in parameter!");
if (tsbsQueryExecution.getPrintInterval() != null){
queriesCommand += "--print-interval " + tsbsQueryExecution.getPrintInterval()+ " ";
}
else throw new IllegalArgumentException("Missing or incorrect --print-interval parameter!");
if (tsbsQueryExecution.isDebug()){
queriesCommand += "--debug 1 ";
}
if (tsbsQueryExecution.isPrintResponses()){
queriesCommand += "--print-responses ";
}
//DBMS specific parameters
return getDBMSConnection(dbms, dbEndpoints, queriesCommand,
......
......@@ -625,6 +625,24 @@ definitions:
format: int32
description: 'number of worker to execute the workload'
example: 4
burn-in:
type: number
format: int32
description: 'number of queries to ignore before collecting statistics'
example: 0
debug:
type: boolean
description: 'print debug messages'
example: false
print-interval:
type: number
format: int32
description: 'print timing stats to stderr after this many queries (0 to disable) (default 100)'
example: 100
print-responses:
type: boolean
description: 'pretty print response bodies for correctness checking (default false)'
example: false
dbmsPorperties:
type: array
items:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment