Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/bookkeeping.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Use Node.js 12.18.0
- name: Use Node.js 16.9.1
uses: actions/setup-node@v1
with:
node-version: '12.18.0'
node-version: '16.9.1'
- name: Installing dependencies
run: npm ci
- name: Running linter
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/openapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Use Node.js 12.18.0
- name: Use Node.js 16.9.1
uses: actions/setup-node@v1
with:
node-version: '12.18.0'
node-version: '16.9.1'
- name: Running validator
run: |
npm ci
Expand All @@ -28,10 +28,10 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Use Node.js 12.18.0
- name: Use Node.js 16.9.1
uses: actions/setup-node@v1
with:
node-version: '12.18.0'
node-version: '16.9.1'
- name: Running validator
run: |
npx @openapitools/openapi-generator-cli validate -i spec/openapi.yaml
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: '14.x'
node-version: '16.9.1'
registry-url: 'https://registry.npmjs.org'
- name: Install production deps
run: npm install --only=production
Expand Down
6 changes: 3 additions & 3 deletions cpp-api-client/openapi-source.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1435,8 +1435,8 @@ components:
description: Describes an intervention or an event that happened.
type: object
properties:
activityId:
$ref: '#/components/schemas/RunActivityId'
environmentId:
$ref: '#/components/schemas/RunEnvironmentId'
bytesReadOut:
$ref: '#/components/schemas/RunBytesReadOut'
createdAt:
Expand Down Expand Up @@ -1480,7 +1480,7 @@ components:
format: int64
example: 853113599
additionalProperties: false
RunActivityId:
RunEnvironmentId:
description: The unique identifier of this entity.
type: string
RunBytesReadOut:
Expand Down
4 changes: 2 additions & 2 deletions cpp-api-client/src/BookkeepingApi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ BookkeepingApi::BookkeepingApi(std::string url, std::string token)


void BookkeepingApi::runStart(int64_t runNumber, std::time_t o2Start,
std::time_t triggerStart, utility::string_t activityId,
std::time_t triggerStart, utility::string_t environmentId,
RunType runType, int64_t nDetectors, int64_t nFlps, int64_t nEpns,
bool dd_flp, bool dcs, bool epn)
{
Expand All @@ -135,7 +135,7 @@ void BookkeepingApi::runStart(int64_t runNumber, std::time_t o2Start,
run->setTimeO2Start(getUnixTimeStamp(&o2Start));
run->setTimeTrgStart(getUnixTimeStamp(&triggerStart));
run->setRunType(runTypeToActualRunType(runType));
run->setActivityId(activityId);
run->setEnvironmentId(environmentId);
run->setNDetectors(nDetectors);
run->setNFlps(nFlps);
run->setNEpns(nEpns);
Expand Down
2 changes: 1 addition & 1 deletion cpp-api-client/src/BookkeepingApi.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class BookkeepingApi : public virtual BookkeepingInterface
public:
BookkeepingApi(std::string url, std::string token);
virtual void runStart(int64_t runNumber, std::time_t o2Start,
std::time_t triggerStart, utility::string_t activityId,
std::time_t triggerStart, utility::string_t environmentId,
RunType runType, int64_t nDetectors, int64_t nFlps, int64_t nEpns,
bool dd_flp, bool dcs, bool epn) override;
virtual void runEnd(int64_t runNumber, std::time_t o2End, std::time_t triggerEnd,
Expand Down
4 changes: 2 additions & 2 deletions cpp-api-client/src/BookkeepingInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ namespace bookkeeping
* @param runNumber Integer ID of a specific data taking session
* @param o2Start Time (UTC) when command to start a new Run was given
* @param triggerStart Time (UTC) when Trigger subsystem was started
* @param activityId Control ID string. Can be a long hash, 32 or 64 character long
* @param environmentId Control ID string. Can be a long hash, 32 or 64 character long
* @param runType Type of run. Might be replaced by tags
* @param nDetectors Number of detectors in the Run
* @param nFlps Number of FLP nodes in the Run
Expand All @@ -43,7 +43,7 @@ namespace bookkeeping
* @throws org::openapitools::client::api::ApiException
*/
virtual void runStart(int64_t runNumber, std::time_t o2Start, std::time_t triggerStart,
utility::string_t activityId, RunType runType, int64_t nDetectors, int64_t nFlps, int64_t nEpns,
utility::string_t environmentId, RunType runType, int64_t nDetectors, int64_t nFlps, int64_t nEpns,
bool dd_flp, bool dcs, bool epn) = 0;

/**
Expand Down
2 changes: 1 addition & 1 deletion cpp-api-client/src/CreateRunParameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ struct CreateRunParameters
boost::posix_time::ptime timeTrgEnd;
std::string runType;
std::string runQuality;
std::string activityId;
std::string environmentId;
int64_t nDetectors;
int64_t nFlps;
int64_t nEpns;
Expand Down
2 changes: 1 addition & 1 deletion cpp-api-client/src/GetRunsParameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ struct GetRunsParameters
boost::optional<boost::posix_time::ptime> endTimeTrgEnd;
boost::optional<boost::posix_time::ptime> startTimeO2End;
boost::optional<boost::posix_time::ptime> endTimeO2End;
boost::optional<std::string> activityId;
boost::optional<std::string> environmentId;
boost::optional<RunType> runType;
boost::optional<RunQuality> runQuality;
};
Expand Down
2 changes: 1 addition & 1 deletion cpp-api-client/src/Run.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ struct Run
boost::posix_time::ptime timeTrgEnd;
std::string runType;
std::string runQuality;
std::string activityId;
std::string environmentId;
int64_t nDetectors;
int64_t nFlps;
int64_t nEpns;
Expand Down
48 changes: 24 additions & 24 deletions cpp-api-client/src/cpprest-client/model/Run.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ namespace model {

Run::Run()
{
m_ActivityId = utility::conversions::to_string_t("");
m_ActivityIdIsSet = false;
m_EnvironmentId = utility::conversions::to_string_t("");
m_EnvironmentIdIsSet = false;
m_BytesReadOut = 0L;
m_BytesReadOutIsSet = false;
m_CreatedAt = 0L;
Expand Down Expand Up @@ -75,9 +75,9 @@ web::json::value Run::toJson() const

web::json::value val = web::json::value::object();

if(m_ActivityIdIsSet)
if(m_EnvironmentIdIsSet)
{
val[utility::conversions::to_string_t("activityId")] = ModelBase::toJson(m_ActivityId);
val[utility::conversions::to_string_t("environmentId")] = ModelBase::toJson(m_EnvironmentId);
}
if(m_BytesReadOutIsSet)
{
Expand Down Expand Up @@ -159,14 +159,14 @@ bool Run::fromJson(const web::json::value& val)
{
bool ok = true;

if(val.has_field(utility::conversions::to_string_t("activityId")))
if(val.has_field(utility::conversions::to_string_t("environmentId")))
{
const web::json::value& fieldValue = val.at(utility::conversions::to_string_t("activityId"));
const web::json::value& fieldValue = val.at(utility::conversions::to_string_t("environmentId"));
if(!fieldValue.is_null())
{
utility::string_t refVal_activityId;
ok &= ModelBase::fromJson(fieldValue, refVal_activityId);
setActivityId(refVal_activityId);
utility::string_t refVal_environmentId;
ok &= ModelBase::fromJson(fieldValue, refVal_environmentId);
setEnvironmentId(refVal_environmentId);
}
}
if(val.has_field(utility::conversions::to_string_t("bytesReadOut")))
Expand Down Expand Up @@ -359,9 +359,9 @@ void Run::toMultipart(std::shared_ptr<MultipartFormData> multipart, const utilit
{
namePrefix += utility::conversions::to_string_t(".");
}
if(m_ActivityIdIsSet)
if(m_EnvironmentIdIsSet)
{
multipart->add(ModelBase::toHttpContent(namePrefix + utility::conversions::to_string_t("activityId"), m_ActivityId));
multipart->add(ModelBase::toHttpContent(namePrefix + utility::conversions::to_string_t("environmentId"), m_EnvironmentId));
}
if(m_BytesReadOutIsSet)
{
Expand Down Expand Up @@ -446,11 +446,11 @@ bool Run::fromMultiPart(std::shared_ptr<MultipartFormData> multipart, const util
namePrefix += utility::conversions::to_string_t(".");
}

if(multipart->hasContent(utility::conversions::to_string_t("activityId")))
if(multipart->hasContent(utility::conversions::to_string_t("environmentId")))
{
utility::string_t refVal_activityId;
ok &= ModelBase::fromHttpContent(multipart->getContent(utility::conversions::to_string_t("activityId")), refVal_activityId );
setActivityId(refVal_activityId);
utility::string_t refVal_environmentId;
ok &= ModelBase::fromHttpContent(multipart->getContent(utility::conversions::to_string_t("environmentId")), refVal_environmentId );
setEnvironmentId(refVal_environmentId);
}
if(multipart->hasContent(utility::conversions::to_string_t("bytesReadOut")))
{
Expand Down Expand Up @@ -563,25 +563,25 @@ bool Run::fromMultiPart(std::shared_ptr<MultipartFormData> multipart, const util
return ok;
}

utility::string_t Run::getActivityId() const
utility::string_t Run::getEnvironmentId() const
{
return m_ActivityId;
return m_EnvironmentId;
}

void Run::setActivityId(const utility::string_t& value)
void Run::setEnvironmentId(const utility::string_t& value)
{
m_ActivityId = value;
m_ActivityIdIsSet = true;
m_EnvironmentId = value;
m_EnvironmentIdIsSet = true;
}

bool Run::activityIdIsSet() const
bool Run::environmentIdIsSet() const
{
return m_ActivityIdIsSet;
return m_EnvironmentIdIsSet;
}

void Run::unsetActivityId()
void Run::unsetEnvironmentId()
{
m_ActivityIdIsSet = false;
m_EnvironmentIdIsSet = false;
}
int64_t Run::getBytesReadOut() const
{
Expand Down
12 changes: 6 additions & 6 deletions cpp-api-client/src/cpprest-client/model/Run.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ class Run
/// <summary>
/// The unique identifier of this entity.
/// </summary>
utility::string_t getActivityId() const;
bool activityIdIsSet() const;
void unsetActivityId();
utility::string_t getEnvironmentId() const;
bool environmentIdIsSet() const;
void unsetEnvironmentId();

void setActivityId(const utility::string_t& value);
void setEnvironmentId(const utility::string_t& value);

/// <summary>
/// Total data volume read out from the detectors by the O2 system in bytes.
Expand Down Expand Up @@ -228,8 +228,8 @@ class Run


protected:
utility::string_t m_ActivityId;
bool m_ActivityIdIsSet;
utility::string_t m_EnvironmentId;
bool m_EnvironmentIdIsSet;
int64_t m_BytesReadOut;
bool m_BytesReadOutIsSet;
int64_t m_CreatedAt;
Expand Down
6 changes: 3 additions & 3 deletions go-api-client/openapi-source.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1435,8 +1435,8 @@ components:
description: Describes an intervention or an event that happened.
type: object
properties:
activityId:
$ref: '#/components/schemas/RunActivityId'
environmentId:
$ref: '#/components/schemas/RunEnvironmentId'
bytesReadOut:
$ref: '#/components/schemas/RunBytesReadOut'
createdAt:
Expand Down Expand Up @@ -1480,7 +1480,7 @@ components:
format: int32
example: 853113599
additionalProperties: false
RunActivityId:
RunEnvironmentId:
description: The unique identifier of this entity.
type: string
RunBytesReadOut:
Expand Down
4 changes: 2 additions & 2 deletions go-api-client/src/BookkeepingApi.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ func InitializeApi(baseUrl string, apiKey string) {
* @param o2Start Time (UTC) when command to start a new Run was given
* @param triggerStart Time (UTC) when Trigger subsystem was started
*/
func CreateRun(activityId string, nDetectors int32, nEpns int32, nFlps int32, runNumber int32, runType sw.RunType, timeO2Start time.Time, timeTrgStart time.Time, dd_flp bool, dcs bool, epn bool) {
func CreateRun(environmentId string, nDetectors int32, nEpns int32, nFlps int32, runNumber int32, runType sw.RunType, timeO2Start time.Time, timeTrgStart time.Time, dd_flp bool, dcs bool, epn bool) {
var runtype sw.RunType = runType

obj := sw.Run{
ActivityId: activityId,
EnvironmentId: environmentId,
NDetectors: nDetectors,
NEpns: nEpns,
NFlps: nFlps,
Expand Down
14 changes: 7 additions & 7 deletions go-api-client/src/go-client-generated/api/swagger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1274,11 +1274,11 @@ components:
runType: physics
bytesReadOut: 0
nSubtimeframes: 2
activityId: activityId
createdAt: 853113599
nEpns: 5
runQuality: good
timeO2Start: 2000-01-23T04:56:07.000+00:00
environmentId: environmentId
dcs: false
nDetectors: 1
nFlps: 5
Expand All @@ -1293,11 +1293,11 @@ components:
runType: physics
bytesReadOut: 0
nSubtimeframes: 2
activityId: activityId
createdAt: 853113599
nEpns: 5
runQuality: good
timeO2Start: 2000-01-23T04:56:07.000+00:00
environmentId: environmentId
dcs: false
nDetectors: 1
nFlps: 5
Expand Down Expand Up @@ -2239,8 +2239,8 @@ components:
Run:
type: object
properties:
activityId:
$ref: '#/components/schemas/RunActivityId'
environmentId:
$ref: '#/components/schemas/RunEnvironmentId'
bytesReadOut:
$ref: '#/components/schemas/RunBytesReadOut'
createdAt:
Expand Down Expand Up @@ -2293,19 +2293,19 @@ components:
runType: physics
bytesReadOut: 0
nSubtimeframes: 2
activityId: activityId
createdAt: 853113599
nEpns: 5
runQuality: good
timeO2Start: 2000-01-23T04:56:07.000+00:00
environmentId: environmentId
dcs: false
nDetectors: 1
nFlps: 5
dd_flp: false
runNumber: 7
id: 1
updatedAt: 853113599
RunActivityId:
RunEnvironmentId:
type: string
description: The unique identifier of this entity.
RunBytesReadOut:
Expand Down Expand Up @@ -2367,11 +2367,11 @@ components:
runType: physics
bytesReadOut: 0
nSubtimeframes: 2
activityId: activityId
createdAt: 853113599
nEpns: 5
runQuality: good
timeO2Start: 2000-01-23T04:56:07.000+00:00
environmentId: environmentId
dcs: false
nDetectors: 1
nFlps: 5
Expand Down
2 changes: 1 addition & 1 deletion go-api-client/src/go-client-generated/docs/Run.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**ActivityId** | **string** | | [optional] [default to null]
**EnvironmentId** | **string** | | [optional] [default to null]
**BytesReadOut** | **int32** | | [optional] [default to null]
**CreatedAt** | **int32** | Unix timestamp when this entity was created. | [optional] [default to null]
**Id** | **int32** | | [optional] [default to null]
Expand Down
2 changes: 1 addition & 1 deletion go-api-client/src/go-client-generated/model_run.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (

// Describes an intervention or an event that happened.
type Run struct {
ActivityId string `json:"activityId,omitempty"`
EnvironmentId string `json:"environmentId,omitempty"`
BytesReadOut int32 `json:"bytesReadOut,omitempty"`
// Unix timestamp when this entity was created.
CreatedAt int32 `json:"createdAt,omitempty"`
Expand Down
Loading