From 8ee3fc879e8e20f668fc29d3c5a95947d6bcbe75 Mon Sep 17 00:00:00 2001 From: Sylvain Renault Date: Thu, 30 May 2024 13:38:03 +0200 Subject: [PATCH 1/2] Fixed issue missing some modules by using new generator version (7.6.0) in the file openapitools.json --- openapi | 2 +- openapitools.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/openapi b/openapi index 61f9f88..073fd72 160000 --- a/openapi +++ b/openapi @@ -1 +1 @@ -Subproject commit 61f9f881fd6e4df80767f35107ae36750b307395 +Subproject commit 073fd7213fd9e6ebc2f8a47d628a650de30c8bc4 diff --git a/openapitools.json b/openapitools.json index 05dd985..d77a729 100644 --- a/openapitools.json +++ b/openapitools.json @@ -2,7 +2,7 @@ "$schema": "node_modules/@openapitools/openapi-generator-cli/config.schema.json", "spaces": 2, "generator-cli": { - "version": "5.3.0", + "version": "7.6.0", "generators":{ "v1.1": { "generatorName": "aspnetcore", -- GitLab From ca42e4d9c63bcac53b3b96cd5649b7ed96057df7 Mon Sep 17 00:00:00 2001 From: Sylvain Renault Date: Thu, 5 Sep 2024 12:08:35 +0200 Subject: [PATCH 2/2] Current version for HHI server. --- .../ETSI-ARF/ControllersImpl/DefaultImpl.cs | 10 +++--- .../ControllersImpl/TrackablesImpl.cs | 4 +-- .../ControllersImpl/WorldAnchorsImpl.cs | 2 +- .../ControllersImpl/WorldLinksImpl.cs | 4 +-- .../ETSI-ARF/ModelsExt/TrackableExt.cs | 6 ++++ .../ETSI-ARF/ModelsExt/WorldLinksExt.cs | 3 ++ .../ETSI-ARF/Services/BaseService.cs | 2 +- .../ETSI.ARF.OpenAPI.WorldStorage/Startup.cs | 31 ++++++++++++++++--- .../appsettings.json | 8 ++--- 9 files changed, 51 insertions(+), 19 deletions(-) diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/DefaultImpl.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/DefaultImpl.cs index ea5c39b..af22e02 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/DefaultImpl.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/DefaultImpl.cs @@ -1,9 +1,9 @@ /* - * SmartSite Core System API + * ETSI ARF Core System API * - * API ensuring interoperability between the various services, tools and apps in SmartSite + * API ensuring interoperability between the various services, tools and apps in ARF * - * The version of the OpenAPI document: 1.0.2 + * The version of the OpenAPI document: 2.0.1 * * Generated by: https://openapi-generator.tech */ @@ -39,13 +39,13 @@ namespace ETSI.ARF.OpenAPI.WorldStorage.Controllers public override IActionResult GetAdmin() { - string answer = "ETSI ARF Server Running."; + string answer = "ETSI ARF World Storage Server is running."; return new ObjectResult(answer); } public override IActionResult GetVersion() { - string answer = "ETSI ARF RESTful API 1.1.0"; + string answer = "ETSI ARF RESTful API v" + Startup.apiVersion;//"2.0.1"; return new ObjectResult(answer); } diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/TrackablesImpl.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/TrackablesImpl.cs index 5845b10..f6c4bdc 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/TrackablesImpl.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/TrackablesImpl.cs @@ -1,7 +1,7 @@ // // ARF - Augmented Reality Framework (ETSI ISG ARF) // -// Copyright 2022 ETSI +// Copyright 2024 ETSI // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -15,7 +15,7 @@ // See the License for the specific language governing permissions and // limitations under the License. // -// Last change: June 2022 +// Last change: June 2024 // /* diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldAnchorsImpl.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldAnchorsImpl.cs index 8d5e48b..0d66633 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldAnchorsImpl.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldAnchorsImpl.cs @@ -15,7 +15,7 @@ // See the License for the specific language governing permissions and // limitations under the License. // -// Last change: June 2022 +// Last change: June 2024 // /* diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldLinksImpl.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldLinksImpl.cs index cd5da8a..27ce36e 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldLinksImpl.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ControllersImpl/WorldLinksImpl.cs @@ -1,7 +1,7 @@ // // ARF - Augmented Reality Framework (ETSI ISG ARF) // -// Copyright 2022 ETSI +// Copyright 2024 ETSI // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -15,7 +15,7 @@ // See the License for the specific language governing permissions and // limitations under the License. // -// Last change: June 2022 +// Last change: June 2024 // /* diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/TrackableExt.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/TrackableExt.cs index db4d674..059404b 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/TrackableExt.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/TrackableExt.cs @@ -40,6 +40,9 @@ namespace ETSI.ARF.OpenAPI.WorldStorage.Models //[BsonIgnore] - don't ignore, so mongo replace can use it! public ObjectId _mongoID { get => _id; set => _id = value; } + /// + /// Check for capabilities + /// public bool Match(List capabilities) { if (capabilities.Count == 0) @@ -60,6 +63,9 @@ namespace ETSI.ARF.OpenAPI.WorldStorage.Models return false; } + /// + /// Give the matrix from the array of the object + /// public Matrix4x4 Matrix() { return new Matrix4x4( diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/WorldLinksExt.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/WorldLinksExt.cs index 3191d4a..f7d1ce7 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/WorldLinksExt.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/ModelsExt/WorldLinksExt.cs @@ -46,6 +46,9 @@ namespace ETSI.ARF.OpenAPI.WorldStorage.Models //[BsonIgnore] - don't ignore, so mongo replace can use it! public ObjectId _mongoID { get => _id; set => _id = value; } + /// + /// Give the matrix from the array of the object + /// public Matrix4x4 Matrix() { return new Matrix4x4( diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/Services/BaseService.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/Services/BaseService.cs index 90e909e..6b499f1 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/Services/BaseService.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/ETSI-ARF/Services/BaseService.cs @@ -36,7 +36,7 @@ namespace ETSI.ARF.OpenAPI.WorldStorage.Services { string msg = "World Storage API: Service for '" + settings.CollectionNameTrackables + "' can only be instantiated one time!"; Console.WriteLine(msg); - return; + //return; //throw new Exception(msg); } else _singleton = this; diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/Startup.cs b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/Startup.cs index 701c684..b2d59f7 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/Startup.cs +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/Startup.cs @@ -1,9 +1,29 @@ +// +// ARF - Augmented Reality Framework (ETSI ISG ARF) +// +// Copyright 2024 ETSI +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Last change: June 2024 +// + /* - * World Storage API +*World Storage API * * API ensuring interoperability between an authoring tool and a World Storage service * - * The version of the OpenAPI document: 1.0.0 + * The version of the OpenAPI document: 2.0.1 * * Generated by: https://openapi-generator.tech */ @@ -17,9 +37,12 @@ using Microsoft.AspNetCore.Hosting; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Hosting; +using Microsoft.Extensions.Options; using Microsoft.OpenApi.Models; + using Newtonsoft.Json.Converters; using Newtonsoft.Json.Serialization; + using ETSI.ARF.OpenAPI.WorldStorage.Authentication; using ETSI.ARF.OpenAPI.WorldStorage.Filters; using ETSI.ARF.OpenAPI.WorldStorage.OpenApi; @@ -27,10 +50,10 @@ using ETSI.ARF.OpenAPI.WorldStorage.Formatters; using ETSI.ARF.OpenAPI.WorldStorage.Services; using ETSI.ARF.OpenAPI.WorldStorage.Models; using ETSI.ARF.OpenAPI.WorldStorage.Binders; + using MongoDB.Bson.Serialization.Serializers; using MongoDB.Bson.Serialization; using MongoDB.Bson; -using Microsoft.Extensions.Options; namespace ETSI.ARF.OpenAPI.WorldStorage { @@ -45,7 +68,7 @@ namespace ETSI.ARF.OpenAPI.WorldStorage /// /// The API version. (how to read it from the yaml?) /// - static public string apiVersion = "1.1.0"; + static public string apiVersion = "2.0.1"; /// /// Demo access key diff --git a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/appsettings.json b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/appsettings.json index f740468..f2c1c69 100644 --- a/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/appsettings.json +++ b/server/worldstorage/src/ETSI.ARF.OpenAPI.WorldStorage/appsettings.json @@ -1,13 +1,13 @@ { "DatabaseSettings": { - "Description" : "Version for Visual Studio", + "Description": "Version for Visual Studio", "LocalDataPath": ".\\wwwroot\\dataspace\\data", "MongoSrv": "192-168-020-029.fe.hhi.de", "MongoPort": "27037", "DatabaseName": "WorldStorageAPI", - "CollectionNameWorldLinks": "WorldLinks", - "CollectionNameTrackables": "Trackables", - "CollectionNameWorldAnchors": "WorldAnchors" + "CollectionNameWorldLinks": "WorldLinks-DEV", + "CollectionNameTrackables": "Trackables-DEV", + "CollectionNameWorldAnchors": "WorldAnchors-DEV" }, "Logging": { "LogLevel": { -- GitLab