From 5e10aa610cc353935395d39f846cf1cee1e16d0f Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Tue, 24 Jan 2023 17:36:42 +0100 Subject: [PATCH 1/8] Fixes #24476 --- .../clients/ProfiledConcessioniTest.java | 13 +- geoportal-service/CHANGELOG.md | 4 + geoportal-service/pom.xml | 2 +- .../cms/sdi/engine/SDIManagerWrapper.java | 2 +- .../cms/sdi/plugins/MaterializerTests.java | 13 +- .../sampleFiles/timpone.json | 466 ++++++++++++++++ test-data/profiledDocuments/timponeFull.json | 518 ++++++++++++++++++ .../application/cms/usecases/SingleTest.java | 39 ++ 8 files changed, 1047 insertions(+), 10 deletions(-) create mode 100644 test-data/profiledDocuments/sampleFiles/timpone.json create mode 100644 test-data/profiledDocuments/timponeFull.json create mode 100644 use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java diff --git a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java index 6ae0741..8abc07a 100644 --- a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java +++ b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java @@ -123,12 +123,19 @@ public class ProfiledConcessioniTest > e // Set pos - client.registerFileSet(project.getId(), FileSets. + RegisterFileSetRequest req = FileSets. prepareRequest(new StorageUtils(), "$.posizionamentoScavo","fileset", "$.posizionamentoScavo."+Field.CHILDREN+"[?(@.fileset)]", - new File(Tests.FOLDER_CONCESSIONI,"pos.shp"), - new File(Tests.FOLDER_CONCESSIONI,"pos.shx"))); + new File(Tests.FOLDER_CONCESSIONI,"pos.shx"), + new File(Tests.FOLDER_CONCESSIONI,"pos.shp")); + + String toTestStrangeName = "e. gna_topografia_timponedellamotta"; + //String toTestStrangeName = "1. my: Strange name *pos"; + + req.getStreams().forEach(t ->t.setFilename(t.getFilename().replace("pos",toTestStrangeName))); + + client.registerFileSet(project.getId(), req); // Add 2 imgs diff --git a/geoportal-service/CHANGELOG.md b/geoportal-service/CHANGELOG.md index 2be7162..8685004 100644 --- a/geoportal-service/CHANGELOG.md +++ b/geoportal-service/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog for org.gcube.application.geoportal-service + +## [v1.0.13-SNAPSHOT] - 2023-01-24 +- Fixes [#24476](https://support.d4science.org/issues/24476) + ## [v1.0.12] - 2023-01-10 - Refactored UserUtils into framework plugin diff --git a/geoportal-service/pom.xml b/geoportal-service/pom.xml index 82c7ac5..f5d562b 100644 --- a/geoportal-service/pom.xml +++ b/geoportal-service/pom.xml @@ -4,7 +4,7 @@ 4.0.0 org.gcube.application geoportal-service - 1.0.12 + 1.0.13-SNAPSHOT Geoportal Service war diff --git a/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java b/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java index 6d1f69f..d8460ec 100644 --- a/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java +++ b/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java @@ -94,7 +94,7 @@ public class SDIManagerWrapper extends SDIManager{ selectedFormat = format; // get basename for layer baseName = format.getToUseFileSet().get(0).getName(); - baseName= Files.fixFilename(baseName.substring(0,baseName.lastIndexOf('.'))); + baseName= Files.fixFilename(baseName).substring(0,baseName.lastIndexOf('.')); break; } } diff --git a/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java b/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java index 99c96cc..cef51f2 100644 --- a/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java +++ b/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java @@ -33,15 +33,18 @@ public class MaterializerTests extends BasicPluginTest { assumeTrue(GCubeTest.isTestInfrastructureEnabled()); Project doc= TestDocuments.documentMap.get("registeredGeoTif.json"); // doc.setProfileID("sdi-tests"); - - - - - materialize(doc); } + @Test + public void testFileNames() throws JsonProcessingException, PluginExecutionException { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); + Project doc= TestDocuments.documentMap.get("timponeFull.json"); + // doc.setProfileID("sdi-tests"); + materialize(doc); + } + @Test public void download() throws ConfigurationException, IOException, StorageException { assumeTrue(GCubeTest.isTestInfrastructureEnabled()); diff --git a/test-data/profiledDocuments/sampleFiles/timpone.json b/test-data/profiledDocuments/sampleFiles/timpone.json new file mode 100644 index 0000000..f2a5abe --- /dev/null +++ b/test-data/profiledDocuments/sampleFiles/timpone.json @@ -0,0 +1,466 @@ +{ + "nome": "Scavi nell'abitato del Timpone della Motta di Francavilla Marittima (CS)", + "introduzione": "Lo scavo del Dipartimento di Studi Umanistici dell'Università della Calabria ha come obiettivo la conoscenza della storia dell'insediamento dell'abitato del Timpone della Motta di Francavilla Marittima (CS). La quinta campagna di scavo si è svolta tra settembre e ottobre del 2022, per la durata di 45 giorni. Le indagini sono state focalizzate in alcune aree del pianoro II, con lo scopo di ultimare lo scavo delle evidenze messe in luce precedentemente, riferibili ad alcune capanne e case, databili tra l'età del ferro e l'età arcaica. La prosecuzione delle indagini sta permettendo di approfondire le conoscenze in merito all'organizzazione dell'abitato e lo sviluppo diacronico del sito.", + "authors": [ + "Paolo Brocato", + "Luciano Altomare" + ], + "contributore": "Paolo Brocato", + "titolari": "Paolo Brocato", + "responsabile": "Paolo Brocato", + "editore": "Paolo Brocato", + "fontiFinanziamento": "Dipartimento di Studi Umanistici, Università della Calabria", + "soggetto": "Research Excavation", + "risorseCorrelate": "", + "dataInizioProgetto": "2022-09-05 ", + "dataFineProgetto": "2022-10-15 ", + "licenzaID": "CC0-1.0", + "titolareLicenza": "Paolo Brocato", + "titolareCopyright": "Paolo Brocato", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "centroidLat": "", + "centroidLong": "", + "abstractRelazione": { + "abstractIta": "Dal 2017 il Dipartimento di Studi Umanistici dell'Università della Calabria ha avviato nuove indagini archeologiche nell'abitato del Timpone della Motta di Francavilla Marittima (CS). L'obiettivo delle ricerche è l'analisi dell'organizzazione dell'insediamento, delle dinamiche di interazione tra le popolazioni indigene e i colonizzatori greci, prima e dopo la fondazione della colonia achea di Sibari, delle tecniche costruttive, della cultura materiale, delle produzioni. \nLa ricerca archeologica ha previsto diverse fasi di indagine, dalle prospezioni geofisiche alle acquisizioni aero-fotogrammetriche da drone, ricognizioni di superficie e scavo stratigrafico.\nGli scavi hanno permesso di documentare la frequentazione del sito dall'età del bronzo all'età classica, con una maggiore attestazione dei rinvenimenti databili tra l'età del ferro e l'epoca arcaica. Le ricerche condotte nei mesi di settembre e ottobre del 2022 si sono focalizzate sull'estensione di alcune aree già indagate in precedenza: saggio 15 nell'area A, 7 nell'area C. Nel corso degli scavi sono state rinvenute numerose tracce pertinenti a strutture lignee e in muratura. Nel primo caso le evidenze sono costituite dal rinvenimento di buche e canali realizzati nel banco roccioso, mentre per le murature sono stati rinvenuti allineamenti di ciottoli, porzioni di conglomerato e frammenti di grandi contenitori in ceramica, misti a terra a matrice argillosa. Lo studio in laboratorio delle stratigrafie e dei materiali associati consentirà di precisare le planimetrie, le tecniche costruttive, le funzioni e le datazioni degli edifici.\n", + "abstractEng": "Since 2017, the Department of Humanities of the University of Calabria has launched new archaeological investigations in the settlement of Timpone della Motta in Francavilla Marittima (CS). The aim of the research is the analysis of the organization of the settlement, of the dynamics of interaction between the indigenous populations and the Greek colonizers, before and after the foundation of the Achaean colony of Sybaris, of the construction techniques, of the material culture, of the productions.\nThe archaeological research involved various phases of investigation, from geophysical prospecting to aero-photogrammetric acquisitions from drones, survey and stratigraphic excavation.\nThe excavations have made it possible to document the presence of the site from the Bronze Age to the Classical Age, with a greater attestation of the findings datable between the Iron Age and the Archaic period. The research conducted in September and October 2022 focused on the extension of some areas already investigated previously: trench 15 in area A, 7 in area C. During the excavations, numerous traces pertinent to structures were found wooden and masonry. In the first case, the evidence consists of the discovery of holes and ditch made in the rocky bank, while for the walls alignments of pebbles, portions of conglomerate and fragments of large ceramic containers, mixed with clayey matrix were found. The laboratory study of the stratigraphies and associated materials will make it possible to specify the plans and construction techniques, the functions and cronology of the buildings.\n", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta abstract relazione di scavo", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "filesetIta": { + "_uuid": "6c55d59e-85f3-4139-ab2c-79e0be40c486", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.862" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "27dcafde-a742-4269-87df-e4bb4c8fb830", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "1fb94aa4-9423-454e-b3c5-424d9e019a75", + "_link": "https://data.d4science.org/shub/E_MVJTVVB4bmlEYVRYd0lRc1gzVUhSNEk5ZXRmd3lDbitiM1JvM2ZoSlJmNUkxa0c3dnFUMmN2cTl2WGxsMkNPZg==", + "_name": "gna_abstract_timpone_della_motta.pdf" + } + ] + } + }, + "relazioneScavo": { + "responsabili": "Paolo Brocato", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta relazione di scavo", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "170ae0b3-5784-4a72-97f3-71df7bfbdd8a", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:29.032" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "51816bb7-0264-43a2-8733-6abe5494cb37", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "e1da7dc0-7b8f-4b26-bacb-c929388c75d5", + "_link": "https://data.d4science.org/shub/E_UGMxTisrV21uUTlFVktXVDFrNFpuQ0s5bGMvbDhRRWxkUDVlM2JPUVBjWjQxU3piOXVWcXBPdTl4SFFkSTJRbA==", + "_name": "gna_relazione_timpone_della_motta.pdf" + } + ] + } + }, + "immaginiRappresentative": [ + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7a", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "0753cd63-8ea4-47c8-9096-76ec87bf031c", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:31.822" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "1d5b1b80-15ce-4729-be63-5d07ef43c2e7", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "40145ec5-c13e-48f6-9cb8-7d93d62c9d92", + "_link": "https://data.d4science.org/shub/E_L0lLcnBQY3h6alpTR0FvdWM5OGNBR2R3bHhrMWd2UHN3QStzZjR0UUN5VXJGK2l2M2FpdHVMVjczdkZwbkZDaw==", + "_name": "gna_foto_timpone_della_motta_saggio_7a.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7b", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "cb008239-e0c1-4553-9c00-ab584a3ed5dd", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:35.781" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "d1d70cd8-fca2-49d2-8378-74d8ac34596c", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "5a79e153-8462-4060-bd19-c0f3978daebf", + "_link": "https://data.d4science.org/shub/E_YXRoVHd4VE9QVWdxOEoyaGlPaWFQeTFvV1RQRzB3M2dKd1NYcEc2OUVBUTZnQ1paUDNJZGg3VlJXQ1N4dVJVRg==", + "_name": "gna_foto_timpone_della_motta_saggio_7b.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 15", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "da98f3c7-9484-4c88-84b3-57318c2c7c95", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:39.439" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "e017e4e2-f894-4770-9f2b-4ea9d5b618e9", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "e9166bc3-5db8-462f-8d17-f344422c1d7a", + "_link": "https://data.d4science.org/shub/E_Qktobk9panlIVml2V2JKRUtLR1JoZHkvdlhLVEJLWjRFWjd1SThjNlM2TXNuN2pWaXczeFJGUjRLYTlEZFRONA==", + "_name": "gna_foto_timpone_della_motta_saggio_15.jpg" + } + ] + } + } + ], + "posizionamentoScavo": { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta posizionamento scavo", + "abstractSection": "Posizionamento topografico georeferenziato dell’area interessata dalle indagini", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "7078ebc4-05a7-45e4-ac58-dfb44dbb2994", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:40.864" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "a663c392-8fff-4e64-9d1b-5af8442c37c4", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "d60bb454-5282-4030-a07d-19d2e763f45c", + "_link": "https://data.d4science.org/shub/E_REUyajZPeFF0V2dMcmIxMllRRHBSdStvSHdLeGR4Z1kzNkhwM0RjQkl2a2c1b2R5VFBkRzdOakxaamN6Uzg0NQ==", + "_name": "d. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "1af704df-64a8-44bd-9292-1c23a16fec6b", + "_link": "https://data.d4science.org/shub/E_SlRzSDVsUzdvUFU0TjVUK05rTE1CSHJEZFRMSm1iOFo5MWZOMkdxOXRWckVoNEpnMU52UlltZ2VINTNWMEtYcw==", + "_name": "d. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "d904278a-e738-4c12-8cbd-ca9ac9f24da9", + "_link": "https://data.d4science.org/shub/E_SWR6Qjc4L2NXZmxKNEdmRU9QaGxYUjJMeVVRZnVmK000cUVXelJNbkd5aEJEMnY5WVVXaGl3Z1A1ZTNFMEpOcw==", + "_name": "d. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "93d7831b-dd16-402f-9bd5-c998f265bb72", + "_link": "https://data.d4science.org/shub/E_VVQrWXBqWFc3MVZWVGYxenNSRzhSL09wUkZKbVJNa0dQSmtQOG42OTdXUW9RSVFFcDh3YkNwaTZqL21lVURSVw==", + "_name": "d. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "5bdcd098-f41d-489b-b3be-4a2b4ecd8e93", + "_link": "https://data.d4science.org/shub/E_bnAwOTFWSFgzb2xDVlJiUVVCUEMxN0FFM1JhbjI4SmszckYwbzNqaER5Qmhia0J5V0NxcTFqcU45ZW1ETUVoMg==", + "_name": "d. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "73214f25-ca41-43c6-adbc-7687fcca9dbc", + "_link": "https://data.d4science.org/shub/E_NHBybmZGaHFHRjRVcWJTbmpxV3h6R1JwdHNSbnRYVkZQYUpMb3kxRG4wdS9TeTF3VUVtSU1CRFlDei9LTTVOWA==", + "_name": "d. gna_topografia_timponedellamotta.shx" + } + ] + } + }, + "pianteFineScavo": [ + { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta pianta fine scavo", + "abstractSection": "Planimetria georeferenziata dell'area indagata al termine delle attività", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "c267807b-0ea5-4f9b-bcee-a8d70d5248ee", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:45.573" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "2210df2c-aa3a-4f8d-947a-d258853e82f0", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "8181f176-7f6a-4cd4-886c-3126a90482bf", + "_link": "https://data.d4science.org/shub/E_RmxSbnExNzk5dXVIaEtGOWlDVGtIaEJON0hrZ25BSkcwNlZFeFgyU3lFaG1sZ0RzYThCWUI4NDhFejNHUnpCNA==", + "_name": "e. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "96b833a2-0ddd-4b45-8408-6b51b9d85eb0", + "_link": "https://data.d4science.org/shub/E_NS9BaHRVYm5zSDlqMkk1V1FkUWMrMG1IQlBCWVRtdW5DenZnUnNvVzByUzNDbzFwdk9KS1RmdDJZemRCNzBhZw==", + "_name": "e. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "8ab4665d-5c6f-4296-a73d-c93561fd6668", + "_link": "https://data.d4science.org/shub/E_WEV6cGhlOU5GOUJ0WXJJdmgzZXdkOVpncXQxa3dveTFSQUNTeno2MEw0TFdCWURqRlRsd1FmODZRdHhLN25EMQ==", + "_name": "e. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "fabf64ac-0d80-4c9e-8caa-22b5a67cf772", + "_link": "https://data.d4science.org/shub/E_Y0xNZlVGYitGbVZCY0NrTEFoNWpZSGdPVGo2UVNITWFyekpORkdzai9ySTQrbG5YcnZQRE0yRnlXYXM4VVYwRA==", + "_name": "e. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "15f9dfe3-38c2-480c-9606-9803eeeec4a1", + "_link": "https://data.d4science.org/shub/E_ODJWWCt3ZHliRC9USmhTRmkxUmxzV3FnTVc0MGpjandNTDlBcDJDSVJoTGdndEszbWRaRlVsSWRmR3c3N0xXNQ==", + "_name": "e. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "2d3b8e3c-32ec-4e44-805d-8aca61d412b1", + "_link": "https://data.d4science.org/shub/E_ZFVpZ05jRWhkcUJObnJSaUMxanVMMWxPWCs1dXlybFU1Q3cyeGliSXNkbVhhd1hhMXNGV1hIajM0M01MaWlDYw==", + "_name": "e. gna_topografia_timponedellamotta.shx" + } + ] + } + } + ], + "descrizioneContenuto": "Relazione di fine scavo e relativo abstract; selezione di immagini rappresentative; posizionamento topografico dell'area indagata, pianta di fine scavo." +} \ No newline at end of file diff --git a/test-data/profiledDocuments/timponeFull.json b/test-data/profiledDocuments/timponeFull.json new file mode 100644 index 0000000..5207ecc --- /dev/null +++ b/test-data/profiledDocuments/timponeFull.json @@ -0,0 +1,518 @@ +{ + "_id": "63beaa3ca1e60e66b7b586fe", + "_version": "1.0.12", + "_info": { + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_lastEditInfo": { + "_user": { + "_username": "francesco.mangiacrapa" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-19T16:01:43.197" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + } + }, + "_profileID": "profiledConcessioni", + "_profileVersion": "1.0.0", + "_lifecycleInformation": { + "_phase": "DRAFT", + "_lastInvokedStep": "SUBMIT-FOR-REVIEW", + "_lastOperationStatus": "ERROR", + "_errorMessages": [ + "Unexpected exception while trying to materialize File Set Invalid uri 'https://geona-proto.d4science.org/geoserver/rest/layers/profiledconcessioni_d4science_research_infrastructures_eu_d4os_gna_63beaa3ca1e60e66b7b586fe:e. gna_topografia_timponedellamotta.xml': escaped absolute path not valid" + ], + "_warningMessages": [], + "_triggeredEvents": [], + "_notes": null + }, + "_relationships": [ + { + "_relationshipName": "follows", + "_targetID": "6388c16ea1e60e66b7b5834a", + "_targetUCD": "profiledConcessioni" + } + ], + "_identificationReferences": null, + "_theDocument": { + "nome": "Scavi nell'abitato del Timpone della Motta di Francavilla Marittima (CS)", + "introduzione": "Lo scavo del Dipartimento di Studi Umanistici dell'Università della Calabria ha come obiettivo la conoscenza della storia dell'insediamento dell'abitato del Timpone della Motta di Francavilla Marittima (CS). La quinta campagna di scavo si è svolta tra settembre e ottobre del 2022, per la durata di 45 giorni. Le indagini sono state focalizzate in alcune aree del pianoro II, con lo scopo di ultimare lo scavo delle evidenze messe in luce precedentemente, riferibili ad alcune capanne e case, databili tra l'età del ferro e l'età arcaica. La prosecuzione delle indagini sta permettendo di approfondire le conoscenze in merito all'organizzazione dell'abitato e lo sviluppo diacronico del sito.", + "authors": [ + "Paolo Brocato", + "Luciano Altomare" + ], + "contributore": "Paolo Brocato", + "titolari": "Paolo Brocato", + "responsabile": "Paolo Brocato", + "editore": "Paolo Brocato", + "fontiFinanziamento": "Dipartimento di Studi Umanistici, Università della Calabria", + "soggetto": "Research Excavation", + "risorseCorrelate": "", + "dataInizioProgetto": "2022-09-05 ", + "dataFineProgetto": "2022-10-15 ", + "licenzaID": "CC0-1.0", + "titolareLicenza": "Paolo Brocato", + "titolareCopyright": "Paolo Brocato", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "centroidLat": "", + "centroidLong": "", + "abstractRelazione": { + "abstractIta": "Dal 2017 il Dipartimento di Studi Umanistici dell'Università della Calabria ha avviato nuove indagini archeologiche nell'abitato del Timpone della Motta di Francavilla Marittima (CS). L'obiettivo delle ricerche è l'analisi dell'organizzazione dell'insediamento, delle dinamiche di interazione tra le popolazioni indigene e i colonizzatori greci, prima e dopo la fondazione della colonia achea di Sibari, delle tecniche costruttive, della cultura materiale, delle produzioni. \nLa ricerca archeologica ha previsto diverse fasi di indagine, dalle prospezioni geofisiche alle acquisizioni aero-fotogrammetriche da drone, ricognizioni di superficie e scavo stratigrafico.\nGli scavi hanno permesso di documentare la frequentazione del sito dall'età del bronzo all'età classica, con una maggiore attestazione dei rinvenimenti databili tra l'età del ferro e l'epoca arcaica. Le ricerche condotte nei mesi di settembre e ottobre del 2022 si sono focalizzate sull'estensione di alcune aree già indagate in precedenza: saggio 15 nell'area A, 7 nell'area C. Nel corso degli scavi sono state rinvenute numerose tracce pertinenti a strutture lignee e in muratura. Nel primo caso le evidenze sono costituite dal rinvenimento di buche e canali realizzati nel banco roccioso, mentre per le murature sono stati rinvenuti allineamenti di ciottoli, porzioni di conglomerato e frammenti di grandi contenitori in ceramica, misti a terra a matrice argillosa. Lo studio in laboratorio delle stratigrafie e dei materiali associati consentirà di precisare le planimetrie, le tecniche costruttive, le funzioni e le datazioni degli edifici.\n", + "abstractEng": "Since 2017, the Department of Humanities of the University of Calabria has launched new archaeological investigations in the settlement of Timpone della Motta in Francavilla Marittima (CS). The aim of the research is the analysis of the organization of the settlement, of the dynamics of interaction between the indigenous populations and the Greek colonizers, before and after the foundation of the Achaean colony of Sybaris, of the construction techniques, of the material culture, of the productions.\nThe archaeological research involved various phases of investigation, from geophysical prospecting to aero-photogrammetric acquisitions from drones, survey and stratigraphic excavation.\nThe excavations have made it possible to document the presence of the site from the Bronze Age to the Classical Age, with a greater attestation of the findings datable between the Iron Age and the Archaic period. The research conducted in September and October 2022 focused on the extension of some areas already investigated previously: trench 15 in area A, 7 in area C. During the excavations, numerous traces pertinent to structures were found wooden and masonry. In the first case, the evidence consists of the discovery of holes and ditch made in the rocky bank, while for the walls alignments of pebbles, portions of conglomerate and fragments of large ceramic containers, mixed with clayey matrix were found. The laboratory study of the stratigraphies and associated materials will make it possible to specify the plans and construction techniques, the functions and cronology of the buildings.\n", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta abstract relazione di scavo", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "filesetIta": { + "_uuid": "6c55d59e-85f3-4139-ab2c-79e0be40c486", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.862" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "27dcafde-a742-4269-87df-e4bb4c8fb830", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "1fb94aa4-9423-454e-b3c5-424d9e019a75", + "_link": "https://data.d4science.org/shub/E_MVJTVVB4bmlEYVRYd0lRc1gzVUhSNEk5ZXRmd3lDbitiM1JvM2ZoSlJmNUkxa0c3dnFUMmN2cTl2WGxsMkNPZg==", + "_name": "gna_abstract_timpone_della_motta.pdf" + } + ] + } + }, + "relazioneScavo": { + "responsabili": "Paolo Brocato", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta relazione di scavo", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "170ae0b3-5784-4a72-97f3-71df7bfbdd8a", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:29.032" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "51816bb7-0264-43a2-8733-6abe5494cb37", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "e1da7dc0-7b8f-4b26-bacb-c929388c75d5", + "_link": "https://data.d4science.org/shub/E_UGMxTisrV21uUTlFVktXVDFrNFpuQ0s5bGMvbDhRRWxkUDVlM2JPUVBjWjQxU3piOXVWcXBPdTl4SFFkSTJRbA==", + "_name": "gna_relazione_timpone_della_motta.pdf" + } + ] + } + }, + "immaginiRappresentative": [ + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7a", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "0753cd63-8ea4-47c8-9096-76ec87bf031c", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:31.822" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "1d5b1b80-15ce-4729-be63-5d07ef43c2e7", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "40145ec5-c13e-48f6-9cb8-7d93d62c9d92", + "_link": "https://data.d4science.org/shub/E_L0lLcnBQY3h6alpTR0FvdWM5OGNBR2R3bHhrMWd2UHN3QStzZjR0UUN5VXJGK2l2M2FpdHVMVjczdkZwbkZDaw==", + "_name": "gna_foto_timpone_della_motta_saggio_7a.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7b", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "cb008239-e0c1-4553-9c00-ab584a3ed5dd", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:35.781" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "d1d70cd8-fca2-49d2-8378-74d8ac34596c", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "5a79e153-8462-4060-bd19-c0f3978daebf", + "_link": "https://data.d4science.org/shub/E_YXRoVHd4VE9QVWdxOEoyaGlPaWFQeTFvV1RQRzB3M2dKd1NYcEc2OUVBUTZnQ1paUDNJZGg3VlJXQ1N4dVJVRg==", + "_name": "gna_foto_timpone_della_motta_saggio_7b.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 15", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "da98f3c7-9484-4c88-84b3-57318c2c7c95", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:39.439" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "e017e4e2-f894-4770-9f2b-4ea9d5b618e9", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "e9166bc3-5db8-462f-8d17-f344422c1d7a", + "_link": "https://data.d4science.org/shub/E_Qktobk9panlIVml2V2JKRUtLR1JoZHkvdlhLVEJLWjRFWjd1SThjNlM2TXNuN2pWaXczeFJGUjRLYTlEZFRONA==", + "_name": "gna_foto_timpone_della_motta_saggio_15.jpg" + } + ] + } + } + ], + "posizionamentoScavo": { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta posizionamento scavo", + "abstractSection": "Posizionamento topografico georeferenziato dell’area interessata dalle indagini", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "7078ebc4-05a7-45e4-ac58-dfb44dbb2994", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:40.864" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "a663c392-8fff-4e64-9d1b-5af8442c37c4", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "d60bb454-5282-4030-a07d-19d2e763f45c", + "_link": "https://data.d4science.org/shub/E_REUyajZPeFF0V2dMcmIxMllRRHBSdStvSHdLeGR4Z1kzNkhwM0RjQkl2a2c1b2R5VFBkRzdOakxaamN6Uzg0NQ==", + "_name": "d. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "1af704df-64a8-44bd-9292-1c23a16fec6b", + "_link": "https://data.d4science.org/shub/E_SlRzSDVsUzdvUFU0TjVUK05rTE1CSHJEZFRMSm1iOFo5MWZOMkdxOXRWckVoNEpnMU52UlltZ2VINTNWMEtYcw==", + "_name": "d. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "d904278a-e738-4c12-8cbd-ca9ac9f24da9", + "_link": "https://data.d4science.org/shub/E_SWR6Qjc4L2NXZmxKNEdmRU9QaGxYUjJMeVVRZnVmK000cUVXelJNbkd5aEJEMnY5WVVXaGl3Z1A1ZTNFMEpOcw==", + "_name": "d. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "93d7831b-dd16-402f-9bd5-c998f265bb72", + "_link": "https://data.d4science.org/shub/E_VVQrWXBqWFc3MVZWVGYxenNSRzhSL09wUkZKbVJNa0dQSmtQOG42OTdXUW9RSVFFcDh3YkNwaTZqL21lVURSVw==", + "_name": "d. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "5bdcd098-f41d-489b-b3be-4a2b4ecd8e93", + "_link": "https://data.d4science.org/shub/E_bnAwOTFWSFgzb2xDVlJiUVVCUEMxN0FFM1JhbjI4SmszckYwbzNqaER5Qmhia0J5V0NxcTFqcU45ZW1ETUVoMg==", + "_name": "d. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "73214f25-ca41-43c6-adbc-7687fcca9dbc", + "_link": "https://data.d4science.org/shub/E_NHBybmZGaHFHRjRVcWJTbmpxV3h6R1JwdHNSbnRYVkZQYUpMb3kxRG4wdS9TeTF3VUVtSU1CRFlDei9LTTVOWA==", + "_name": "d. gna_topografia_timponedellamotta.shx" + } + ] + } + }, + "pianteFineScavo": [ + { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta pianta fine scavo", + "abstractSection": "Planimetria georeferenziata dell'area indagata al termine delle attività", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "c267807b-0ea5-4f9b-bcee-a8d70d5248ee", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:45.573" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "2210df2c-aa3a-4f8d-947a-d258853e82f0", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "8181f176-7f6a-4cd4-886c-3126a90482bf", + "_link": "https://data.d4science.org/shub/E_RmxSbnExNzk5dXVIaEtGOWlDVGtIaEJON0hrZ25BSkcwNlZFeFgyU3lFaG1sZ0RzYThCWUI4NDhFejNHUnpCNA==", + "_name": "e. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "96b833a2-0ddd-4b45-8408-6b51b9d85eb0", + "_link": "https://data.d4science.org/shub/E_NS9BaHRVYm5zSDlqMkk1V1FkUWMrMG1IQlBCWVRtdW5DenZnUnNvVzByUzNDbzFwdk9KS1RmdDJZemRCNzBhZw==", + "_name": "e. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "8ab4665d-5c6f-4296-a73d-c93561fd6668", + "_link": "https://data.d4science.org/shub/E_WEV6cGhlOU5GOUJ0WXJJdmgzZXdkOVpncXQxa3dveTFSQUNTeno2MEw0TFdCWURqRlRsd1FmODZRdHhLN25EMQ==", + "_name": "e. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "fabf64ac-0d80-4c9e-8caa-22b5a67cf772", + "_link": "https://data.d4science.org/shub/E_Y0xNZlVGYitGbVZCY0NrTEFoNWpZSGdPVGo2UVNITWFyekpORkdzai9ySTQrbG5YcnZQRE0yRnlXYXM4VVYwRA==", + "_name": "e. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "15f9dfe3-38c2-480c-9606-9803eeeec4a1", + "_link": "https://data.d4science.org/shub/E_ODJWWCt3ZHliRC9USmhTRmkxUmxzV3FnTVc0MGpjandNTDlBcDJDSVJoTGdndEszbWRaRlVsSWRmR3c3N0xXNQ==", + "_name": "e. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "2d3b8e3c-32ec-4e44-805d-8aca61d412b1", + "_link": "https://data.d4science.org/shub/E_ZFVpZ05jRWhkcUJObnJSaUMxanVMMWxPWCs1dXlybFU1Q3cyeGliSXNkbVhhd1hhMXNGV1hIajM0M01MaWlDYw==", + "_name": "e. gna_topografia_timponedellamotta.shx" + } + ] + } + } + ], + "descrizioneContenuto": "Relazione di fine scavo e relativo abstract; selezione di immagini rappresentative; posizionamento topografico dell'area indagata, pianta di fine scavo." + }, + "_lock": null +} \ No newline at end of file diff --git a/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java b/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java new file mode 100644 index 0000000..a0cd185 --- /dev/null +++ b/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java @@ -0,0 +1,39 @@ +package org.gcube.application.cms.usecases; + +import org.bson.Document; +import org.gcube.application.cms.tests.TestDocuments; +import org.gcube.application.cms.tests.TokenSetter; +import org.gcube.application.geoportal.client.utils.Serialization; +import org.gcube.application.geoportal.common.model.document.Project; +import org.gcube.application.geoportal.common.model.rest.StepExecutionRequest; +import org.gcube.application.geoportal.common.rest.Projects; +import org.gcube.application.geoportal.common.utils.Files; +import org.gcube.application.geoportal.common.utils.tests.GCubeTest; + +import java.io.File; +import java.io.IOException; +import java.nio.charset.Charset; + +import static org.gcube.application.geoportal.client.plugins.GeoportalAbstractPlugin.projects; + +public class SingleTest { + + public static void main(String[] args) throws IOException { + TokenSetter.set(GCubeTest.getContext()); + + Projects client=projects("profiledConcessioni").build(); + + String toTestDocument = "/Users/fabioisti/git/gcube-cms-suite/test-data/profiledDocuments/sampleFiles/timpone.json"; + + Project p =client.createNew(Document.parse(Files.readFileAsString( + toTestDocument, Charset.defaultCharset()))); + + final StepExecutionRequest step = new StepExecutionRequest(); + step.setStepID("SUBMIT-FOR-REVIEW"); + p = client.performStep(p.getId(),step); + + System.out.println(Serialization.write(p)); + System.out.println("DONE"); + } + +} From b4cf8ccd27cf8ed5f5e7e6e3983d65fd72bdb58a Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Tue, 24 Jan 2023 17:43:31 +0100 Subject: [PATCH 2/8] Advancing the right plugin component, since the service doesn't need upgrade. --- geoportal-service/CHANGELOG.md | 3 --- geoportal-service/pom.xml | 2 +- sdi-plugins/CHANGELOG.md | 3 +++ sdi-plugins/pom.xml | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/geoportal-service/CHANGELOG.md b/geoportal-service/CHANGELOG.md index 8685004..c10350d 100644 --- a/geoportal-service/CHANGELOG.md +++ b/geoportal-service/CHANGELOG.md @@ -1,9 +1,6 @@ # Changelog for org.gcube.application.geoportal-service -## [v1.0.13-SNAPSHOT] - 2023-01-24 -- Fixes [#24476](https://support.d4science.org/issues/24476) - ## [v1.0.12] - 2023-01-10 - Refactored UserUtils into framework plugin diff --git a/geoportal-service/pom.xml b/geoportal-service/pom.xml index f5d562b..82c7ac5 100644 --- a/geoportal-service/pom.xml +++ b/geoportal-service/pom.xml @@ -4,7 +4,7 @@ 4.0.0 org.gcube.application geoportal-service - 1.0.13-SNAPSHOT + 1.0.12 Geoportal Service war diff --git a/sdi-plugins/CHANGELOG.md b/sdi-plugins/CHANGELOG.md index a3c4abc..afbf212 100644 --- a/sdi-plugins/CHANGELOG.md +++ b/sdi-plugins/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog for org.gcube.application.cms.sdi-plugins +## [v1.0.3-SNAPSHOT] - 2023-01-24 +- Fixes [#24476](https://support.d4science.org/issues/24476) + ## [v1.0.2] - 2023-01-10 - Pom updates diff --git a/sdi-plugins/pom.xml b/sdi-plugins/pom.xml index e95a416..25f6de6 100644 --- a/sdi-plugins/pom.xml +++ b/sdi-plugins/pom.xml @@ -5,7 +5,7 @@ 4.0.0 sdi-plugins - 1.0.2 + 1.0.3-SNAPSHOT gCube CMS - SDI Plugins From 2d62160ce1ca5b8010fa78b0c577decdc7b161ec Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Mon, 30 Jan 2023 12:01:56 +0100 Subject: [PATCH 3/8] Tests --- .../geoportal/clients/UCDTests.java | 28 +++++++++++++++++++ .../useCaseDescriptor/UseCaseDescriptor.java | 2 ++ .../common/utils/tests/GCubeTest.java | 2 +- .../profiles/basicProfile.json | 16 +++++++---- .../usecases/ExportConcessioniAsProjects.java | 2 +- 5 files changed, 42 insertions(+), 8 deletions(-) diff --git a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java index 5e9d949..58b4c6f 100644 --- a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java +++ b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java @@ -2,15 +2,23 @@ package org.gcube.application.geoportal.clients; import org.bson.Document; import org.gcube.application.cms.tests.TokenSetter; +import org.gcube.application.geoportal.client.utils.Serialization; +import org.gcube.application.geoportal.common.model.document.accounting.User; import org.gcube.application.geoportal.common.model.rest.QueryRequest; +import org.gcube.application.geoportal.common.model.useCaseDescriptor.DataAccessPolicy; +import org.gcube.application.geoportal.common.model.useCaseDescriptor.UseCaseDescriptor; import org.gcube.application.geoportal.common.rest.UseCaseDescriptorsI; import org.gcube.application.geoportal.common.utils.tests.GCubeTest; import org.junit.Assert; import org.junit.Test; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashSet; import java.util.concurrent.atomic.AtomicLong; import static org.gcube.application.geoportal.client.plugins.GeoportalAbstractPlugin.useCaseDescriptors; +import static org.junit.Assert.assertEquals; import static org.junit.Assume.assumeTrue; public class UCDTests{ @@ -26,6 +34,7 @@ public class UCDTests{ @Test public void query() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); QueryRequest request = new QueryRequest(); // All @@ -40,6 +49,7 @@ public class UCDTests{ @Test public void getByIdAll() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); QueryRequest request = new QueryRequest(); @@ -57,8 +67,26 @@ public class UCDTests{ @Test public void getById() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); System.out.println(client.getById("profiledConcessioni")); } + + @Test + public void checkPolicies() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); + UseCaseDescriptorsI client =getClient(); + UseCaseDescriptor ucd = client.getById("profiledConcessioni"); + System.out.println(Serialization.write(ucd)); + User u = new User(); + u.setRoles(new HashSet<>()); + u.getRoles().addAll(Arrays.asList("Members","Data-Manager")); + + DataAccessPolicy p = ucd.getMatching(u); + System.out.println("Evaluated policy : "+Serialization.write(p)); + assertEquals(p.getPolicy().getRead(), DataAccessPolicy.Policy.Type.any); + assertEquals(p.getPolicy().getWrite(), DataAccessPolicy.Policy.Type.any); + + } } diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java index c8d0a9f..67c0142 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java @@ -121,6 +121,8 @@ public class UseCaseDescriptor implements Serializable { @JsonIgnore public DataAccessPolicy getMatching(User u){ + // TODO Evaluate higher permits + DataAccessPolicy defaultPolicy = null; if(dataAccessPolicies!=null) for (DataAccessPolicy dataAccessPolicy : dataAccessPolicies) { diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java index 72f0be0..b0f1a6c 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java @@ -17,7 +17,7 @@ public class GCubeTest { testContext = "/pred4s/preprod/preVRE"; // testContext = "/d4science.research-infrastructures.eu/D4OS/GNA"; - // testContext= "/gcube/devsec/devVRE"; + // testContext= "/gcube/devsec/devVRE"; System.out.println("TEST CONTEXT = "+testContext); return testContext; diff --git a/test-data/profiledDocuments/profiles/basicProfile.json b/test-data/profiledDocuments/profiles/basicProfile.json index 1a38d36..45784ec 100644 --- a/test-data/profiledDocuments/profiles/basicProfile.json +++ b/test-data/profiledDocuments/profiles/basicProfile.json @@ -18,12 +18,16 @@ ] } }, - "_dataAccessPolicies" : [ - {"_policy" : {"_read" : "own", "_write" : "own"}, "_roles":[]}, - {"_policy" : {"_read" : "any", "_write" : "none"}, "_roles":["Guest"], - "_enforcer": {"_filter" : "{\"_lifecycleInformation._phase\" : {\"$eq\" : \"PUBLISHED\"}}"}}, - {"_policy" : {"_read" : "any", "_write" : "none"}, "_roles":["Editor"]}, - {"_policy" : {"_read" : "any", "_write" : "any"}, "_roles":["Admin"]} + "_dataAccessPolicies": [ + {"_policy": {"_read": "any","_write": "any"}, + "_roles": ["Data-Manager"]}, + {"_policy": {"_read": "own","_write": "own"}, + "_roles": ["Data-Editor"]}, + {"_policy": {"_read": "any","_write": "none"}, + "_roles": ["Member"], + "_enforcer": {"_filter": "{\"_lifecycleInformation._phase\" : {\"$eq\" : \"Published\"}}"}}, + {"_policy": {"_read": "none","_write": "none"}, + "_roles": []} ], "_relationshipDefinitions" : [ diff --git a/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java b/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java index fbe41e5..72af194 100644 --- a/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java +++ b/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java @@ -53,7 +53,7 @@ public class ExportConcessioniAsProjects { File dir= new File("/Users/fabioisti/git/gcube-cms-suite/import1669889538860"); // select only cluster -// dir = new File(dir,"cluster_1"); + dir = new File(dir,"61d5ec7495184b186ad0c2e4"); From ae6c5c1ea7c53bb5c5f2016b96674dd0c76cfa6a Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Tue, 24 Jan 2023 17:36:42 +0100 Subject: [PATCH 4/8] Fixes #24476 --- .../clients/ProfiledConcessioniTest.java | 13 +- geoportal-service/CHANGELOG.md | 4 + geoportal-service/pom.xml | 2 +- .../cms/sdi/engine/SDIManagerWrapper.java | 2 +- .../cms/sdi/plugins/MaterializerTests.java | 13 +- .../sampleFiles/timpone.json | 466 ++++++++++++++++ test-data/profiledDocuments/timponeFull.json | 518 ++++++++++++++++++ .../application/cms/usecases/SingleTest.java | 39 ++ 8 files changed, 1047 insertions(+), 10 deletions(-) create mode 100644 test-data/profiledDocuments/sampleFiles/timpone.json create mode 100644 test-data/profiledDocuments/timponeFull.json create mode 100644 use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java diff --git a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java index 6ae0741..8abc07a 100644 --- a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java +++ b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/ProfiledConcessioniTest.java @@ -123,12 +123,19 @@ public class ProfiledConcessioniTest > e // Set pos - client.registerFileSet(project.getId(), FileSets. + RegisterFileSetRequest req = FileSets. prepareRequest(new StorageUtils(), "$.posizionamentoScavo","fileset", "$.posizionamentoScavo."+Field.CHILDREN+"[?(@.fileset)]", - new File(Tests.FOLDER_CONCESSIONI,"pos.shp"), - new File(Tests.FOLDER_CONCESSIONI,"pos.shx"))); + new File(Tests.FOLDER_CONCESSIONI,"pos.shx"), + new File(Tests.FOLDER_CONCESSIONI,"pos.shp")); + + String toTestStrangeName = "e. gna_topografia_timponedellamotta"; + //String toTestStrangeName = "1. my: Strange name *pos"; + + req.getStreams().forEach(t ->t.setFilename(t.getFilename().replace("pos",toTestStrangeName))); + + client.registerFileSet(project.getId(), req); // Add 2 imgs diff --git a/geoportal-service/CHANGELOG.md b/geoportal-service/CHANGELOG.md index 2be7162..8685004 100644 --- a/geoportal-service/CHANGELOG.md +++ b/geoportal-service/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog for org.gcube.application.geoportal-service + +## [v1.0.13-SNAPSHOT] - 2023-01-24 +- Fixes [#24476](https://support.d4science.org/issues/24476) + ## [v1.0.12] - 2023-01-10 - Refactored UserUtils into framework plugin diff --git a/geoportal-service/pom.xml b/geoportal-service/pom.xml index 82c7ac5..f5d562b 100644 --- a/geoportal-service/pom.xml +++ b/geoportal-service/pom.xml @@ -4,7 +4,7 @@ 4.0.0 org.gcube.application geoportal-service - 1.0.12 + 1.0.13-SNAPSHOT Geoportal Service war diff --git a/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java b/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java index 6d1f69f..d8460ec 100644 --- a/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java +++ b/sdi-plugins/src/main/java/org/gcube/application/cms/sdi/engine/SDIManagerWrapper.java @@ -94,7 +94,7 @@ public class SDIManagerWrapper extends SDIManager{ selectedFormat = format; // get basename for layer baseName = format.getToUseFileSet().get(0).getName(); - baseName= Files.fixFilename(baseName.substring(0,baseName.lastIndexOf('.'))); + baseName= Files.fixFilename(baseName).substring(0,baseName.lastIndexOf('.')); break; } } diff --git a/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java b/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java index 99c96cc..cef51f2 100644 --- a/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java +++ b/sdi-plugins/src/test/java/org/gcube/application/cms/sdi/plugins/MaterializerTests.java @@ -33,15 +33,18 @@ public class MaterializerTests extends BasicPluginTest { assumeTrue(GCubeTest.isTestInfrastructureEnabled()); Project doc= TestDocuments.documentMap.get("registeredGeoTif.json"); // doc.setProfileID("sdi-tests"); - - - - - materialize(doc); } + @Test + public void testFileNames() throws JsonProcessingException, PluginExecutionException { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); + Project doc= TestDocuments.documentMap.get("timponeFull.json"); + // doc.setProfileID("sdi-tests"); + materialize(doc); + } + @Test public void download() throws ConfigurationException, IOException, StorageException { assumeTrue(GCubeTest.isTestInfrastructureEnabled()); diff --git a/test-data/profiledDocuments/sampleFiles/timpone.json b/test-data/profiledDocuments/sampleFiles/timpone.json new file mode 100644 index 0000000..f2a5abe --- /dev/null +++ b/test-data/profiledDocuments/sampleFiles/timpone.json @@ -0,0 +1,466 @@ +{ + "nome": "Scavi nell'abitato del Timpone della Motta di Francavilla Marittima (CS)", + "introduzione": "Lo scavo del Dipartimento di Studi Umanistici dell'Università della Calabria ha come obiettivo la conoscenza della storia dell'insediamento dell'abitato del Timpone della Motta di Francavilla Marittima (CS). La quinta campagna di scavo si è svolta tra settembre e ottobre del 2022, per la durata di 45 giorni. Le indagini sono state focalizzate in alcune aree del pianoro II, con lo scopo di ultimare lo scavo delle evidenze messe in luce precedentemente, riferibili ad alcune capanne e case, databili tra l'età del ferro e l'età arcaica. La prosecuzione delle indagini sta permettendo di approfondire le conoscenze in merito all'organizzazione dell'abitato e lo sviluppo diacronico del sito.", + "authors": [ + "Paolo Brocato", + "Luciano Altomare" + ], + "contributore": "Paolo Brocato", + "titolari": "Paolo Brocato", + "responsabile": "Paolo Brocato", + "editore": "Paolo Brocato", + "fontiFinanziamento": "Dipartimento di Studi Umanistici, Università della Calabria", + "soggetto": "Research Excavation", + "risorseCorrelate": "", + "dataInizioProgetto": "2022-09-05 ", + "dataFineProgetto": "2022-10-15 ", + "licenzaID": "CC0-1.0", + "titolareLicenza": "Paolo Brocato", + "titolareCopyright": "Paolo Brocato", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "centroidLat": "", + "centroidLong": "", + "abstractRelazione": { + "abstractIta": "Dal 2017 il Dipartimento di Studi Umanistici dell'Università della Calabria ha avviato nuove indagini archeologiche nell'abitato del Timpone della Motta di Francavilla Marittima (CS). L'obiettivo delle ricerche è l'analisi dell'organizzazione dell'insediamento, delle dinamiche di interazione tra le popolazioni indigene e i colonizzatori greci, prima e dopo la fondazione della colonia achea di Sibari, delle tecniche costruttive, della cultura materiale, delle produzioni. \nLa ricerca archeologica ha previsto diverse fasi di indagine, dalle prospezioni geofisiche alle acquisizioni aero-fotogrammetriche da drone, ricognizioni di superficie e scavo stratigrafico.\nGli scavi hanno permesso di documentare la frequentazione del sito dall'età del bronzo all'età classica, con una maggiore attestazione dei rinvenimenti databili tra l'età del ferro e l'epoca arcaica. Le ricerche condotte nei mesi di settembre e ottobre del 2022 si sono focalizzate sull'estensione di alcune aree già indagate in precedenza: saggio 15 nell'area A, 7 nell'area C. Nel corso degli scavi sono state rinvenute numerose tracce pertinenti a strutture lignee e in muratura. Nel primo caso le evidenze sono costituite dal rinvenimento di buche e canali realizzati nel banco roccioso, mentre per le murature sono stati rinvenuti allineamenti di ciottoli, porzioni di conglomerato e frammenti di grandi contenitori in ceramica, misti a terra a matrice argillosa. Lo studio in laboratorio delle stratigrafie e dei materiali associati consentirà di precisare le planimetrie, le tecniche costruttive, le funzioni e le datazioni degli edifici.\n", + "abstractEng": "Since 2017, the Department of Humanities of the University of Calabria has launched new archaeological investigations in the settlement of Timpone della Motta in Francavilla Marittima (CS). The aim of the research is the analysis of the organization of the settlement, of the dynamics of interaction between the indigenous populations and the Greek colonizers, before and after the foundation of the Achaean colony of Sybaris, of the construction techniques, of the material culture, of the productions.\nThe archaeological research involved various phases of investigation, from geophysical prospecting to aero-photogrammetric acquisitions from drones, survey and stratigraphic excavation.\nThe excavations have made it possible to document the presence of the site from the Bronze Age to the Classical Age, with a greater attestation of the findings datable between the Iron Age and the Archaic period. The research conducted in September and October 2022 focused on the extension of some areas already investigated previously: trench 15 in area A, 7 in area C. During the excavations, numerous traces pertinent to structures were found wooden and masonry. In the first case, the evidence consists of the discovery of holes and ditch made in the rocky bank, while for the walls alignments of pebbles, portions of conglomerate and fragments of large ceramic containers, mixed with clayey matrix were found. The laboratory study of the stratigraphies and associated materials will make it possible to specify the plans and construction techniques, the functions and cronology of the buildings.\n", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta abstract relazione di scavo", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "filesetIta": { + "_uuid": "6c55d59e-85f3-4139-ab2c-79e0be40c486", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.862" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "27dcafde-a742-4269-87df-e4bb4c8fb830", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "1fb94aa4-9423-454e-b3c5-424d9e019a75", + "_link": "https://data.d4science.org/shub/E_MVJTVVB4bmlEYVRYd0lRc1gzVUhSNEk5ZXRmd3lDbitiM1JvM2ZoSlJmNUkxa0c3dnFUMmN2cTl2WGxsMkNPZg==", + "_name": "gna_abstract_timpone_della_motta.pdf" + } + ] + } + }, + "relazioneScavo": { + "responsabili": "Paolo Brocato", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta relazione di scavo", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "170ae0b3-5784-4a72-97f3-71df7bfbdd8a", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:29.032" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "51816bb7-0264-43a2-8733-6abe5494cb37", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "e1da7dc0-7b8f-4b26-bacb-c929388c75d5", + "_link": "https://data.d4science.org/shub/E_UGMxTisrV21uUTlFVktXVDFrNFpuQ0s5bGMvbDhRRWxkUDVlM2JPUVBjWjQxU3piOXVWcXBPdTl4SFFkSTJRbA==", + "_name": "gna_relazione_timpone_della_motta.pdf" + } + ] + } + }, + "immaginiRappresentative": [ + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7a", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "0753cd63-8ea4-47c8-9096-76ec87bf031c", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:31.822" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "1d5b1b80-15ce-4729-be63-5d07ef43c2e7", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "40145ec5-c13e-48f6-9cb8-7d93d62c9d92", + "_link": "https://data.d4science.org/shub/E_L0lLcnBQY3h6alpTR0FvdWM5OGNBR2R3bHhrMWd2UHN3QStzZjR0UUN5VXJGK2l2M2FpdHVMVjczdkZwbkZDaw==", + "_name": "gna_foto_timpone_della_motta_saggio_7a.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7b", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "cb008239-e0c1-4553-9c00-ab584a3ed5dd", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:35.781" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "d1d70cd8-fca2-49d2-8378-74d8ac34596c", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "5a79e153-8462-4060-bd19-c0f3978daebf", + "_link": "https://data.d4science.org/shub/E_YXRoVHd4VE9QVWdxOEoyaGlPaWFQeTFvV1RQRzB3M2dKd1NYcEc2OUVBUTZnQ1paUDNJZGg3VlJXQ1N4dVJVRg==", + "_name": "gna_foto_timpone_della_motta_saggio_7b.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 15", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "da98f3c7-9484-4c88-84b3-57318c2c7c95", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:39.439" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "e017e4e2-f894-4770-9f2b-4ea9d5b618e9", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "e9166bc3-5db8-462f-8d17-f344422c1d7a", + "_link": "https://data.d4science.org/shub/E_Qktobk9panlIVml2V2JKRUtLR1JoZHkvdlhLVEJLWjRFWjd1SThjNlM2TXNuN2pWaXczeFJGUjRLYTlEZFRONA==", + "_name": "gna_foto_timpone_della_motta_saggio_15.jpg" + } + ] + } + } + ], + "posizionamentoScavo": { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta posizionamento scavo", + "abstractSection": "Posizionamento topografico georeferenziato dell’area interessata dalle indagini", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "7078ebc4-05a7-45e4-ac58-dfb44dbb2994", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:40.864" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "a663c392-8fff-4e64-9d1b-5af8442c37c4", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "d60bb454-5282-4030-a07d-19d2e763f45c", + "_link": "https://data.d4science.org/shub/E_REUyajZPeFF0V2dMcmIxMllRRHBSdStvSHdLeGR4Z1kzNkhwM0RjQkl2a2c1b2R5VFBkRzdOakxaamN6Uzg0NQ==", + "_name": "d. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "1af704df-64a8-44bd-9292-1c23a16fec6b", + "_link": "https://data.d4science.org/shub/E_SlRzSDVsUzdvUFU0TjVUK05rTE1CSHJEZFRMSm1iOFo5MWZOMkdxOXRWckVoNEpnMU52UlltZ2VINTNWMEtYcw==", + "_name": "d. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "d904278a-e738-4c12-8cbd-ca9ac9f24da9", + "_link": "https://data.d4science.org/shub/E_SWR6Qjc4L2NXZmxKNEdmRU9QaGxYUjJMeVVRZnVmK000cUVXelJNbkd5aEJEMnY5WVVXaGl3Z1A1ZTNFMEpOcw==", + "_name": "d. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "93d7831b-dd16-402f-9bd5-c998f265bb72", + "_link": "https://data.d4science.org/shub/E_VVQrWXBqWFc3MVZWVGYxenNSRzhSL09wUkZKbVJNa0dQSmtQOG42OTdXUW9RSVFFcDh3YkNwaTZqL21lVURSVw==", + "_name": "d. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "5bdcd098-f41d-489b-b3be-4a2b4ecd8e93", + "_link": "https://data.d4science.org/shub/E_bnAwOTFWSFgzb2xDVlJiUVVCUEMxN0FFM1JhbjI4SmszckYwbzNqaER5Qmhia0J5V0NxcTFqcU45ZW1ETUVoMg==", + "_name": "d. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "73214f25-ca41-43c6-adbc-7687fcca9dbc", + "_link": "https://data.d4science.org/shub/E_NHBybmZGaHFHRjRVcWJTbmpxV3h6R1JwdHNSbnRYVkZQYUpMb3kxRG4wdS9TeTF3VUVtSU1CRFlDei9LTTVOWA==", + "_name": "d. gna_topografia_timponedellamotta.shx" + } + ] + } + }, + "pianteFineScavo": [ + { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta pianta fine scavo", + "abstractSection": "Planimetria georeferenziata dell'area indagata al termine delle attività", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "c267807b-0ea5-4f9b-bcee-a8d70d5248ee", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:45.573" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "2210df2c-aa3a-4f8d-947a-d258853e82f0", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "8181f176-7f6a-4cd4-886c-3126a90482bf", + "_link": "https://data.d4science.org/shub/E_RmxSbnExNzk5dXVIaEtGOWlDVGtIaEJON0hrZ25BSkcwNlZFeFgyU3lFaG1sZ0RzYThCWUI4NDhFejNHUnpCNA==", + "_name": "e. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "96b833a2-0ddd-4b45-8408-6b51b9d85eb0", + "_link": "https://data.d4science.org/shub/E_NS9BaHRVYm5zSDlqMkk1V1FkUWMrMG1IQlBCWVRtdW5DenZnUnNvVzByUzNDbzFwdk9KS1RmdDJZemRCNzBhZw==", + "_name": "e. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "8ab4665d-5c6f-4296-a73d-c93561fd6668", + "_link": "https://data.d4science.org/shub/E_WEV6cGhlOU5GOUJ0WXJJdmgzZXdkOVpncXQxa3dveTFSQUNTeno2MEw0TFdCWURqRlRsd1FmODZRdHhLN25EMQ==", + "_name": "e. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "fabf64ac-0d80-4c9e-8caa-22b5a67cf772", + "_link": "https://data.d4science.org/shub/E_Y0xNZlVGYitGbVZCY0NrTEFoNWpZSGdPVGo2UVNITWFyekpORkdzai9ySTQrbG5YcnZQRE0yRnlXYXM4VVYwRA==", + "_name": "e. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "15f9dfe3-38c2-480c-9606-9803eeeec4a1", + "_link": "https://data.d4science.org/shub/E_ODJWWCt3ZHliRC9USmhTRmkxUmxzV3FnTVc0MGpjandNTDlBcDJDSVJoTGdndEszbWRaRlVsSWRmR3c3N0xXNQ==", + "_name": "e. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "2d3b8e3c-32ec-4e44-805d-8aca61d412b1", + "_link": "https://data.d4science.org/shub/E_ZFVpZ05jRWhkcUJObnJSaUMxanVMMWxPWCs1dXlybFU1Q3cyeGliSXNkbVhhd1hhMXNGV1hIajM0M01MaWlDYw==", + "_name": "e. gna_topografia_timponedellamotta.shx" + } + ] + } + } + ], + "descrizioneContenuto": "Relazione di fine scavo e relativo abstract; selezione di immagini rappresentative; posizionamento topografico dell'area indagata, pianta di fine scavo." +} \ No newline at end of file diff --git a/test-data/profiledDocuments/timponeFull.json b/test-data/profiledDocuments/timponeFull.json new file mode 100644 index 0000000..5207ecc --- /dev/null +++ b/test-data/profiledDocuments/timponeFull.json @@ -0,0 +1,518 @@ +{ + "_id": "63beaa3ca1e60e66b7b586fe", + "_version": "1.0.12", + "_info": { + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_lastEditInfo": { + "_user": { + "_username": "francesco.mangiacrapa" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-19T16:01:43.197" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + } + }, + "_profileID": "profiledConcessioni", + "_profileVersion": "1.0.0", + "_lifecycleInformation": { + "_phase": "DRAFT", + "_lastInvokedStep": "SUBMIT-FOR-REVIEW", + "_lastOperationStatus": "ERROR", + "_errorMessages": [ + "Unexpected exception while trying to materialize File Set Invalid uri 'https://geona-proto.d4science.org/geoserver/rest/layers/profiledconcessioni_d4science_research_infrastructures_eu_d4os_gna_63beaa3ca1e60e66b7b586fe:e. gna_topografia_timponedellamotta.xml': escaped absolute path not valid" + ], + "_warningMessages": [], + "_triggeredEvents": [], + "_notes": null + }, + "_relationships": [ + { + "_relationshipName": "follows", + "_targetID": "6388c16ea1e60e66b7b5834a", + "_targetUCD": "profiledConcessioni" + } + ], + "_identificationReferences": null, + "_theDocument": { + "nome": "Scavi nell'abitato del Timpone della Motta di Francavilla Marittima (CS)", + "introduzione": "Lo scavo del Dipartimento di Studi Umanistici dell'Università della Calabria ha come obiettivo la conoscenza della storia dell'insediamento dell'abitato del Timpone della Motta di Francavilla Marittima (CS). La quinta campagna di scavo si è svolta tra settembre e ottobre del 2022, per la durata di 45 giorni. Le indagini sono state focalizzate in alcune aree del pianoro II, con lo scopo di ultimare lo scavo delle evidenze messe in luce precedentemente, riferibili ad alcune capanne e case, databili tra l'età del ferro e l'età arcaica. La prosecuzione delle indagini sta permettendo di approfondire le conoscenze in merito all'organizzazione dell'abitato e lo sviluppo diacronico del sito.", + "authors": [ + "Paolo Brocato", + "Luciano Altomare" + ], + "contributore": "Paolo Brocato", + "titolari": "Paolo Brocato", + "responsabile": "Paolo Brocato", + "editore": "Paolo Brocato", + "fontiFinanziamento": "Dipartimento di Studi Umanistici, Università della Calabria", + "soggetto": "Research Excavation", + "risorseCorrelate": "", + "dataInizioProgetto": "2022-09-05 ", + "dataFineProgetto": "2022-10-15 ", + "licenzaID": "CC0-1.0", + "titolareLicenza": "Paolo Brocato", + "titolareCopyright": "Paolo Brocato", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "centroidLat": "", + "centroidLong": "", + "abstractRelazione": { + "abstractIta": "Dal 2017 il Dipartimento di Studi Umanistici dell'Università della Calabria ha avviato nuove indagini archeologiche nell'abitato del Timpone della Motta di Francavilla Marittima (CS). L'obiettivo delle ricerche è l'analisi dell'organizzazione dell'insediamento, delle dinamiche di interazione tra le popolazioni indigene e i colonizzatori greci, prima e dopo la fondazione della colonia achea di Sibari, delle tecniche costruttive, della cultura materiale, delle produzioni. \nLa ricerca archeologica ha previsto diverse fasi di indagine, dalle prospezioni geofisiche alle acquisizioni aero-fotogrammetriche da drone, ricognizioni di superficie e scavo stratigrafico.\nGli scavi hanno permesso di documentare la frequentazione del sito dall'età del bronzo all'età classica, con una maggiore attestazione dei rinvenimenti databili tra l'età del ferro e l'epoca arcaica. Le ricerche condotte nei mesi di settembre e ottobre del 2022 si sono focalizzate sull'estensione di alcune aree già indagate in precedenza: saggio 15 nell'area A, 7 nell'area C. Nel corso degli scavi sono state rinvenute numerose tracce pertinenti a strutture lignee e in muratura. Nel primo caso le evidenze sono costituite dal rinvenimento di buche e canali realizzati nel banco roccioso, mentre per le murature sono stati rinvenuti allineamenti di ciottoli, porzioni di conglomerato e frammenti di grandi contenitori in ceramica, misti a terra a matrice argillosa. Lo studio in laboratorio delle stratigrafie e dei materiali associati consentirà di precisare le planimetrie, le tecniche costruttive, le funzioni e le datazioni degli edifici.\n", + "abstractEng": "Since 2017, the Department of Humanities of the University of Calabria has launched new archaeological investigations in the settlement of Timpone della Motta in Francavilla Marittima (CS). The aim of the research is the analysis of the organization of the settlement, of the dynamics of interaction between the indigenous populations and the Greek colonizers, before and after the foundation of the Achaean colony of Sybaris, of the construction techniques, of the material culture, of the productions.\nThe archaeological research involved various phases of investigation, from geophysical prospecting to aero-photogrammetric acquisitions from drones, survey and stratigraphic excavation.\nThe excavations have made it possible to document the presence of the site from the Bronze Age to the Classical Age, with a greater attestation of the findings datable between the Iron Age and the Archaic period. The research conducted in September and October 2022 focused on the extension of some areas already investigated previously: trench 15 in area A, 7 in area C. During the excavations, numerous traces pertinent to structures were found wooden and masonry. In the first case, the evidence consists of the discovery of holes and ditch made in the rocky bank, while for the walls alignments of pebbles, portions of conglomerate and fragments of large ceramic containers, mixed with clayey matrix were found. The laboratory study of the stratigraphies and associated materials will make it possible to specify the plans and construction techniques, the functions and cronology of the buildings.\n", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta abstract relazione di scavo", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "filesetIta": { + "_uuid": "6c55d59e-85f3-4139-ab2c-79e0be40c486", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.862" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "27dcafde-a742-4269-87df-e4bb4c8fb830", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "1fb94aa4-9423-454e-b3c5-424d9e019a75", + "_link": "https://data.d4science.org/shub/E_MVJTVVB4bmlEYVRYd0lRc1gzVUhSNEk5ZXRmd3lDbitiM1JvM2ZoSlJmNUkxa0c3dnFUMmN2cTl2WGxsMkNPZg==", + "_name": "gna_abstract_timpone_della_motta.pdf" + } + ] + } + }, + "relazioneScavo": { + "responsabili": "Paolo Brocato", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta relazione di scavo", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "170ae0b3-5784-4a72-97f3-71df7bfbdd8a", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:29.032" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "51816bb7-0264-43a2-8733-6abe5494cb37", + "_payloads": [ + { + "_mimetype": "application/pdf", + "_storageID": "e1da7dc0-7b8f-4b26-bacb-c929388c75d5", + "_link": "https://data.d4science.org/shub/E_UGMxTisrV21uUTlFVktXVDFrNFpuQ0s5bGMvbDhRRWxkUDVlM2JPUVBjWjQxU3piOXVWcXBPdTl4SFFkSTJRbA==", + "_name": "gna_relazione_timpone_della_motta.pdf" + } + ] + } + }, + "immaginiRappresentative": [ + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7a", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "0753cd63-8ea4-47c8-9096-76ec87bf031c", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:31.822" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "1d5b1b80-15ce-4729-be63-5d07ef43c2e7", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "40145ec5-c13e-48f6-9cb8-7d93d62c9d92", + "_link": "https://data.d4science.org/shub/E_L0lLcnBQY3h6alpTR0FvdWM5OGNBR2R3bHhrMWd2UHN3QStzZjR0UUN5VXJGK2l2M2FpdHVMVjczdkZwbkZDaw==", + "_name": "gna_foto_timpone_della_motta_saggio_7a.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 7b", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "cb008239-e0c1-4553-9c00-ab584a3ed5dd", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:35.781" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "d1d70cd8-fca2-49d2-8378-74d8ac34596c", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "5a79e153-8462-4060-bd19-c0f3978daebf", + "_link": "https://data.d4science.org/shub/E_YXRoVHd4VE9QVWdxOEoyaGlPaWFQeTFvV1RQRzB3M2dKd1NYcEc2OUVBUTZnQ1paUDNJZGg3VlJXQ1N4dVJVRg==", + "_name": "gna_foto_timpone_della_motta_saggio_7b.jpg" + } + ] + } + }, + { + "didascalia": "GNA_foto_Timpone della Motta saggio 15", + "responsabili": "Luciano Altomare", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "soggetto": "Research Excavation", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "da98f3c7-9484-4c88-84b3-57318c2c7c95", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:39.439" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "e017e4e2-f894-4770-9f2b-4ea9d5b618e9", + "_payloads": [ + { + "_mimetype": "image/jpeg", + "_storageID": "e9166bc3-5db8-462f-8d17-f344422c1d7a", + "_link": "https://data.d4science.org/shub/E_Qktobk9panlIVml2V2JKRUtLR1JoZHkvdlhLVEJLWjRFWjd1SThjNlM2TXNuN2pWaXczeFJGUjRLYTlEZFRONA==", + "_name": "gna_foto_timpone_della_motta_saggio_15.jpg" + } + ] + } + } + ], + "posizionamentoScavo": { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "policy": "OPEN", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta posizionamento scavo", + "abstractSection": "Posizionamento topografico georeferenziato dell’area interessata dalle indagini", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "7078ebc4-05a7-45e4-ac58-dfb44dbb2994", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:40.864" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "a663c392-8fff-4e64-9d1b-5af8442c37c4", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "d60bb454-5282-4030-a07d-19d2e763f45c", + "_link": "https://data.d4science.org/shub/E_REUyajZPeFF0V2dMcmIxMllRRHBSdStvSHdLeGR4Z1kzNkhwM0RjQkl2a2c1b2R5VFBkRzdOakxaamN6Uzg0NQ==", + "_name": "d. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "1af704df-64a8-44bd-9292-1c23a16fec6b", + "_link": "https://data.d4science.org/shub/E_SlRzSDVsUzdvUFU0TjVUK05rTE1CSHJEZFRMSm1iOFo5MWZOMkdxOXRWckVoNEpnMU52UlltZ2VINTNWMEtYcw==", + "_name": "d. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "d904278a-e738-4c12-8cbd-ca9ac9f24da9", + "_link": "https://data.d4science.org/shub/E_SWR6Qjc4L2NXZmxKNEdmRU9QaGxYUjJMeVVRZnVmK000cUVXelJNbkd5aEJEMnY5WVVXaGl3Z1A1ZTNFMEpOcw==", + "_name": "d. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "93d7831b-dd16-402f-9bd5-c998f265bb72", + "_link": "https://data.d4science.org/shub/E_VVQrWXBqWFc3MVZWVGYxenNSRzhSL09wUkZKbVJNa0dQSmtQOG42OTdXUW9RSVFFcDh3YkNwaTZqL21lVURSVw==", + "_name": "d. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "5bdcd098-f41d-489b-b3be-4a2b4ecd8e93", + "_link": "https://data.d4science.org/shub/E_bnAwOTFWSFgzb2xDVlJiUVVCUEMxN0FFM1JhbjI4SmszckYwbzNqaER5Qmhia0J5V0NxcTFqcU45ZW1ETUVoMg==", + "_name": "d. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "73214f25-ca41-43c6-adbc-7687fcca9dbc", + "_link": "https://data.d4science.org/shub/E_NHBybmZGaHFHRjRVcWJTbmpxV3h6R1JwdHNSbnRYVkZQYUpMb3kxRG4wdS9TeTF3VUVtSU1CRFlDei9LTTVOWA==", + "_name": "d. gna_topografia_timponedellamotta.shx" + } + ] + } + }, + "pianteFineScavo": [ + { + "valutazioneQualita": "Qualità elevata in quanto tutti i dati provengono da rilievo strumentale effettuato in occasione delle indagini", + "metodoRaccoltaDati": "Restituzione di dati da stazione totale e laserscanner.", + "scalaAcquisizione": "1:1", + "authors": "Antonio Lio", + "licenseID": "CC-BY-4.0", + "titolo": "Scavo nell'abitato del Timpone della Motta pianta fine scavo", + "abstractSection": "Planimetria georeferenziata dell'area indagata al termine delle attività", + "topicCategory": "Society", + "subTopic": "Archeology", + "paroleChiaveLibere": [ + "Francavilla Marittima", + "Timpone della Motta", + "Enotri", + "Magna Grecia" + ], + "paroleChiaveICCD": [ + "Età del Bronzo", + "Età del Ferro", + "Età Orientalizzante", + "Età Arcaica", + "Età Classica" + ], + "responsabile": "Paolo Brocato", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:24.361" + }, + "_access": { + "_policy": "OPEN", + "_license": "CC0-1.0" + }, + "fileset": { + "_uuid": "c267807b-0ea5-4f9b-bcee-a8d70d5248ee", + "_creationInfo": { + "_user": { + "_username": "domenico.marino-019b85c" + }, + "_context": { + "_id": "/d4science.research-infrastructures.eu/D4OS/GNA", + "_name": "/GNA" + }, + "_instant": "2023-01-11T13:23:45.573" + }, + "_access": { + "_policy": "OPEN", + "_license": "" + }, + "_folderID": "2210df2c-aa3a-4f8d-947a-d258853e82f0", + "_payloads": [ + { + "_mimetype": "text/plain", + "_storageID": "8181f176-7f6a-4cd4-886c-3126a90482bf", + "_link": "https://data.d4science.org/shub/E_RmxSbnExNzk5dXVIaEtGOWlDVGtIaEJON0hrZ25BSkcwNlZFeFgyU3lFaG1sZ0RzYThCWUI4NDhFejNHUnpCNA==", + "_name": "e. gna_topografia_timponedellamotta.cpg" + }, + { + "_mimetype": "application/x-dbf", + "_storageID": "96b833a2-0ddd-4b45-8408-6b51b9d85eb0", + "_link": "https://data.d4science.org/shub/E_NS9BaHRVYm5zSDlqMkk1V1FkUWMrMG1IQlBCWVRtdW5DenZnUnNvVzByUzNDbzFwdk9KS1RmdDJZemRCNzBhZw==", + "_name": "e. gna_topografia_timponedellamotta.dbf" + }, + { + "_mimetype": "text/plain", + "_storageID": "8ab4665d-5c6f-4296-a73d-c93561fd6668", + "_link": "https://data.d4science.org/shub/E_WEV6cGhlOU5GOUJ0WXJJdmgzZXdkOVpncXQxa3dveTFSQUNTeno2MEw0TFdCWURqRlRsd1FmODZRdHhLN25EMQ==", + "_name": "e. gna_topografia_timponedellamotta.prj" + }, + { + "_mimetype": "text/plain", + "_storageID": "fabf64ac-0d80-4c9e-8caa-22b5a67cf772", + "_link": "https://data.d4science.org/shub/E_Y0xNZlVGYitGbVZCY0NrTEFoNWpZSGdPVGo2UVNITWFyekpORkdzai9ySTQrbG5YcnZQRE0yRnlXYXM4VVYwRA==", + "_name": "e. gna_topografia_timponedellamotta.qmd" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "15f9dfe3-38c2-480c-9606-9803eeeec4a1", + "_link": "https://data.d4science.org/shub/E_ODJWWCt3ZHliRC9USmhTRmkxUmxzV3FnTVc0MGpjandNTDlBcDJDSVJoTGdndEszbWRaRlVsSWRmR3c3N0xXNQ==", + "_name": "e. gna_topografia_timponedellamotta.shp" + }, + { + "_mimetype": "application/x-shapefile", + "_storageID": "2d3b8e3c-32ec-4e44-805d-8aca61d412b1", + "_link": "https://data.d4science.org/shub/E_ZFVpZ05jRWhkcUJObnJSaUMxanVMMWxPWCs1dXlybFU1Q3cyeGliSXNkbVhhd1hhMXNGV1hIajM0M01MaWlDYw==", + "_name": "e. gna_topografia_timponedellamotta.shx" + } + ] + } + } + ], + "descrizioneContenuto": "Relazione di fine scavo e relativo abstract; selezione di immagini rappresentative; posizionamento topografico dell'area indagata, pianta di fine scavo." + }, + "_lock": null +} \ No newline at end of file diff --git a/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java b/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java new file mode 100644 index 0000000..a0cd185 --- /dev/null +++ b/use-cases/src/test/java/org/gcube/application/cms/usecases/SingleTest.java @@ -0,0 +1,39 @@ +package org.gcube.application.cms.usecases; + +import org.bson.Document; +import org.gcube.application.cms.tests.TestDocuments; +import org.gcube.application.cms.tests.TokenSetter; +import org.gcube.application.geoportal.client.utils.Serialization; +import org.gcube.application.geoportal.common.model.document.Project; +import org.gcube.application.geoportal.common.model.rest.StepExecutionRequest; +import org.gcube.application.geoportal.common.rest.Projects; +import org.gcube.application.geoportal.common.utils.Files; +import org.gcube.application.geoportal.common.utils.tests.GCubeTest; + +import java.io.File; +import java.io.IOException; +import java.nio.charset.Charset; + +import static org.gcube.application.geoportal.client.plugins.GeoportalAbstractPlugin.projects; + +public class SingleTest { + + public static void main(String[] args) throws IOException { + TokenSetter.set(GCubeTest.getContext()); + + Projects client=projects("profiledConcessioni").build(); + + String toTestDocument = "/Users/fabioisti/git/gcube-cms-suite/test-data/profiledDocuments/sampleFiles/timpone.json"; + + Project p =client.createNew(Document.parse(Files.readFileAsString( + toTestDocument, Charset.defaultCharset()))); + + final StepExecutionRequest step = new StepExecutionRequest(); + step.setStepID("SUBMIT-FOR-REVIEW"); + p = client.performStep(p.getId(),step); + + System.out.println(Serialization.write(p)); + System.out.println("DONE"); + } + +} From b8cb4e86f0573c0dc9ac84e1c532fb4bcdee3c4d Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Tue, 24 Jan 2023 17:43:31 +0100 Subject: [PATCH 5/8] Advancing the right plugin component, since the service doesn't need upgrade. --- geoportal-service/CHANGELOG.md | 3 --- geoportal-service/pom.xml | 2 +- sdi-plugins/CHANGELOG.md | 3 +++ sdi-plugins/pom.xml | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/geoportal-service/CHANGELOG.md b/geoportal-service/CHANGELOG.md index 8685004..c10350d 100644 --- a/geoportal-service/CHANGELOG.md +++ b/geoportal-service/CHANGELOG.md @@ -1,9 +1,6 @@ # Changelog for org.gcube.application.geoportal-service -## [v1.0.13-SNAPSHOT] - 2023-01-24 -- Fixes [#24476](https://support.d4science.org/issues/24476) - ## [v1.0.12] - 2023-01-10 - Refactored UserUtils into framework plugin diff --git a/geoportal-service/pom.xml b/geoportal-service/pom.xml index f5d562b..82c7ac5 100644 --- a/geoportal-service/pom.xml +++ b/geoportal-service/pom.xml @@ -4,7 +4,7 @@ 4.0.0 org.gcube.application geoportal-service - 1.0.13-SNAPSHOT + 1.0.12 Geoportal Service war diff --git a/sdi-plugins/CHANGELOG.md b/sdi-plugins/CHANGELOG.md index a3c4abc..afbf212 100644 --- a/sdi-plugins/CHANGELOG.md +++ b/sdi-plugins/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog for org.gcube.application.cms.sdi-plugins +## [v1.0.3-SNAPSHOT] - 2023-01-24 +- Fixes [#24476](https://support.d4science.org/issues/24476) + ## [v1.0.2] - 2023-01-10 - Pom updates diff --git a/sdi-plugins/pom.xml b/sdi-plugins/pom.xml index e95a416..25f6de6 100644 --- a/sdi-plugins/pom.xml +++ b/sdi-plugins/pom.xml @@ -5,7 +5,7 @@ 4.0.0 sdi-plugins - 1.0.2 + 1.0.3-SNAPSHOT gCube CMS - SDI Plugins From 9ba3559a1537653438502901ebc0e8d2e242beae Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Mon, 30 Jan 2023 12:01:56 +0100 Subject: [PATCH 6/8] Tests --- .../geoportal/clients/UCDTests.java | 28 +++++++++++++++++++ .../useCaseDescriptor/UseCaseDescriptor.java | 2 ++ .../common/utils/tests/GCubeTest.java | 2 +- .../profiles/basicProfile.json | 16 +++++++---- .../usecases/ExportConcessioniAsProjects.java | 2 +- 5 files changed, 42 insertions(+), 8 deletions(-) diff --git a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java index 5e9d949..58b4c6f 100644 --- a/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java +++ b/geoportal-client/src/test/java/org/gcube/application/geoportal/clients/UCDTests.java @@ -2,15 +2,23 @@ package org.gcube.application.geoportal.clients; import org.bson.Document; import org.gcube.application.cms.tests.TokenSetter; +import org.gcube.application.geoportal.client.utils.Serialization; +import org.gcube.application.geoportal.common.model.document.accounting.User; import org.gcube.application.geoportal.common.model.rest.QueryRequest; +import org.gcube.application.geoportal.common.model.useCaseDescriptor.DataAccessPolicy; +import org.gcube.application.geoportal.common.model.useCaseDescriptor.UseCaseDescriptor; import org.gcube.application.geoportal.common.rest.UseCaseDescriptorsI; import org.gcube.application.geoportal.common.utils.tests.GCubeTest; import org.junit.Assert; import org.junit.Test; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashSet; import java.util.concurrent.atomic.AtomicLong; import static org.gcube.application.geoportal.client.plugins.GeoportalAbstractPlugin.useCaseDescriptors; +import static org.junit.Assert.assertEquals; import static org.junit.Assume.assumeTrue; public class UCDTests{ @@ -26,6 +34,7 @@ public class UCDTests{ @Test public void query() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); QueryRequest request = new QueryRequest(); // All @@ -40,6 +49,7 @@ public class UCDTests{ @Test public void getByIdAll() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); QueryRequest request = new QueryRequest(); @@ -57,8 +67,26 @@ public class UCDTests{ @Test public void getById() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); UseCaseDescriptorsI client =getClient(); System.out.println(client.getById("profiledConcessioni")); } + + @Test + public void checkPolicies() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); + UseCaseDescriptorsI client =getClient(); + UseCaseDescriptor ucd = client.getById("profiledConcessioni"); + System.out.println(Serialization.write(ucd)); + User u = new User(); + u.setRoles(new HashSet<>()); + u.getRoles().addAll(Arrays.asList("Members","Data-Manager")); + + DataAccessPolicy p = ucd.getMatching(u); + System.out.println("Evaluated policy : "+Serialization.write(p)); + assertEquals(p.getPolicy().getRead(), DataAccessPolicy.Policy.Type.any); + assertEquals(p.getPolicy().getWrite(), DataAccessPolicy.Policy.Type.any); + + } } diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java index c8d0a9f..67c0142 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/model/useCaseDescriptor/UseCaseDescriptor.java @@ -121,6 +121,8 @@ public class UseCaseDescriptor implements Serializable { @JsonIgnore public DataAccessPolicy getMatching(User u){ + // TODO Evaluate higher permits + DataAccessPolicy defaultPolicy = null; if(dataAccessPolicies!=null) for (DataAccessPolicy dataAccessPolicy : dataAccessPolicies) { diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java index 72f0be0..b0f1a6c 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java @@ -17,7 +17,7 @@ public class GCubeTest { testContext = "/pred4s/preprod/preVRE"; // testContext = "/d4science.research-infrastructures.eu/D4OS/GNA"; - // testContext= "/gcube/devsec/devVRE"; + // testContext= "/gcube/devsec/devVRE"; System.out.println("TEST CONTEXT = "+testContext); return testContext; diff --git a/test-data/profiledDocuments/profiles/basicProfile.json b/test-data/profiledDocuments/profiles/basicProfile.json index 1a38d36..45784ec 100644 --- a/test-data/profiledDocuments/profiles/basicProfile.json +++ b/test-data/profiledDocuments/profiles/basicProfile.json @@ -18,12 +18,16 @@ ] } }, - "_dataAccessPolicies" : [ - {"_policy" : {"_read" : "own", "_write" : "own"}, "_roles":[]}, - {"_policy" : {"_read" : "any", "_write" : "none"}, "_roles":["Guest"], - "_enforcer": {"_filter" : "{\"_lifecycleInformation._phase\" : {\"$eq\" : \"PUBLISHED\"}}"}}, - {"_policy" : {"_read" : "any", "_write" : "none"}, "_roles":["Editor"]}, - {"_policy" : {"_read" : "any", "_write" : "any"}, "_roles":["Admin"]} + "_dataAccessPolicies": [ + {"_policy": {"_read": "any","_write": "any"}, + "_roles": ["Data-Manager"]}, + {"_policy": {"_read": "own","_write": "own"}, + "_roles": ["Data-Editor"]}, + {"_policy": {"_read": "any","_write": "none"}, + "_roles": ["Member"], + "_enforcer": {"_filter": "{\"_lifecycleInformation._phase\" : {\"$eq\" : \"Published\"}}"}}, + {"_policy": {"_read": "none","_write": "none"}, + "_roles": []} ], "_relationshipDefinitions" : [ diff --git a/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java b/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java index fbe41e5..72af194 100644 --- a/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java +++ b/use-cases/src/test/java/org/gcube/application/cms/usecases/ExportConcessioniAsProjects.java @@ -53,7 +53,7 @@ public class ExportConcessioniAsProjects { File dir= new File("/Users/fabioisti/git/gcube-cms-suite/import1669889538860"); // select only cluster -// dir = new File(dir,"cluster_1"); + dir = new File(dir,"61d5ec7495184b186ad0c2e4"); From 409df28cc168eff9174d5605c234b08bfce3ec22 Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Mon, 30 Jan 2023 17:42:51 +0100 Subject: [PATCH 7/8] Tests --- .../geoportal/common/utils/tests/GCubeTest.java | 1 + .../profiledDocuments/ProfiledConcessioniTests.java | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java index b0f1a6c..d3b57ab 100644 --- a/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java +++ b/geoportal-common/src/main/java/org/gcube/application/geoportal/common/utils/tests/GCubeTest.java @@ -16,6 +16,7 @@ public class GCubeTest { testContext = "/pred4s/preprod/preVRE"; + testContext = "/pred4s/preprod/preVRE_ext"; // testContext = "/d4science.research-infrastructures.eu/D4OS/GNA"; // testContext= "/gcube/devsec/devVRE"; diff --git a/geoportal-service/src/test/java/org/gcube/application/geoportal/service/profiledDocuments/ProfiledConcessioniTests.java b/geoportal-service/src/test/java/org/gcube/application/geoportal/service/profiledDocuments/ProfiledConcessioniTests.java index 97b91a8..f4caa38 100644 --- a/geoportal-service/src/test/java/org/gcube/application/geoportal/service/profiledDocuments/ProfiledConcessioniTests.java +++ b/geoportal-service/src/test/java/org/gcube/application/geoportal/service/profiledDocuments/ProfiledConcessioniTests.java @@ -98,7 +98,12 @@ public class ProfiledConcessioniTests extends AbstractProfiledDocumentsTests{ } - + @Test + public void testGetById() throws Exception { + assumeTrue(GCubeTest.isTestInfrastructureEnabled()); + getById("63cffb238f66b84c444dae4f"); + System.out.println("Done"); + } @Test From bac779b20d58b29b25b514880c3448beba12b8ec Mon Sep 17 00:00:00 2001 From: Fabio Sinibaldi Date: Mon, 30 Jan 2023 17:43:20 +0100 Subject: [PATCH 8/8] Release sdi-plugins.1.0.3 --- sdi-plugins/CHANGELOG.md | 2 +- sdi-plugins/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sdi-plugins/CHANGELOG.md b/sdi-plugins/CHANGELOG.md index afbf212..c401260 100644 --- a/sdi-plugins/CHANGELOG.md +++ b/sdi-plugins/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog for org.gcube.application.cms.sdi-plugins -## [v1.0.3-SNAPSHOT] - 2023-01-24 +## [v1.0.3] - 2023-01-24 - Fixes [#24476](https://support.d4science.org/issues/24476) ## [v1.0.2] - 2023-01-10 diff --git a/sdi-plugins/pom.xml b/sdi-plugins/pom.xml index 25f6de6..24d34e6 100644 --- a/sdi-plugins/pom.xml +++ b/sdi-plugins/pom.xml @@ -5,7 +5,7 @@ 4.0.0 sdi-plugins - 1.0.3-SNAPSHOT + 1.0.3 gCube CMS - SDI Plugins