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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 0 additions & 18 deletions src/main/kotlin/com/cosmotech/api/clients/EventBusClient.kt

This file was deleted.

22 changes: 0 additions & 22 deletions src/main/kotlin/com/cosmotech/api/clients/ResultDataClient.kt

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,6 @@ data class CsmPlatformProperties(

/** Container image to send data to DataWarehouse */
val sendDataWarehouse: String,
val scenarioDataUpload: String = "cosmo-tech/azure-storage-publish:latest",
)

data class CsmContainers(
Expand Down Expand Up @@ -502,17 +501,17 @@ data class CsmPlatformProperties(
/** Twin cache query page information for workspace */
val workspace: PageSizing = PageSizing(),

/** Twin cache query page information for scenario */
val scenario: PageSizing = PageSizing(),
/** Twin cache query page information for runner */
val runner: PageSizing = PageSizing(),

/** Twin cache query page information for connector */
val connector: PageSizing = PageSizing(),

/** Twin cache query page information for dataset */
val dataset: PageSizing = PageSizing(),

/** Twin cache query page information for scenariorun */
val scenariorun: PageSizing = PageSizing(),
/** Twin cache query page information for run */
val run: PageSizing = PageSizing(),

/** Twin cache query page information for solution */
val solution: PageSizing = PageSizing(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
// Licensed under the MIT license.
package com.cosmotech.api.events

import java.time.ZonedDateTime

sealed class CsmRequestResponseEvent<T>(publisher: Any) : CsmEvent(publisher) {
var response: T? = null
}
Expand All @@ -14,20 +12,6 @@ class WorkflowStatusRequest(
val workflowName: String,
) : CsmRequestResponseEvent<String>(publisher)

class ScenarioDataDownloadRequest(
publisher: Any,
val jobId: String,
val organizationId: String,
val workspaceId: String,
val scenarioId: String
) : CsmRequestResponseEvent<Map<String, Any>>(publisher)

class ScenarioDataDownloadJobInfoRequest(
publisher: Any,
val jobId: String,
val organizationId: String,
) : CsmRequestResponseEvent<Pair<String?, String>>(publisher)

class WorkflowPhaseToStateRequest(
publisher: Any,
val organizationId: String,
Expand All @@ -36,20 +20,6 @@ class WorkflowPhaseToStateRequest(
val workflowPhase: String?,
) : CsmRequestResponseEvent<String>(publisher)

class ScenarioRunEndToEndStateRequest(
publisher: Any,
val organizationId: String,
val workspaceId: String,
val scenarioRunId: String
) : CsmRequestResponseEvent<String>(publisher)

class ScenarioRunEndTimeRequest(
publisher: Any,
val organizationId: String,
val workspaceId: String,
val scenarioRunId: String
) : CsmRequestResponseEvent<ZonedDateTime>(publisher)

class AddDatasetToWorkspace(
publisher: Any,
val organizationId: String,
Expand Down
40 changes: 0 additions & 40 deletions src/main/kotlin/com/cosmotech/api/events/ScenarioEvents.kt

This file was deleted.

17 changes: 0 additions & 17 deletions src/main/kotlin/com/cosmotech/api/events/ScenarioRunEvents.kt

This file was deleted.

22 changes: 11 additions & 11 deletions src/main/kotlin/com/cosmotech/api/rbac/RolesDefinition.kt
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,17 @@ val COMMON_ROLE_ADMIN_PERMISSIONS =
)

// Scenario roles & permissions
val SCENARIO_ROLE_VIEWER_PERMISSIONS = listOf(PERMISSION_READ, PERMISSION_READ_SECURITY)
val SCENARIO_ROLE_EDITOR_PERMISSIONS =
val RUNNER_ROLE_VIEWER_PERMISSIONS = listOf(PERMISSION_READ, PERMISSION_READ_SECURITY)
val RUNNER_ROLE_EDITOR_PERMISSIONS =
listOf(PERMISSION_READ, PERMISSION_READ_SECURITY, PERMISSION_LAUNCH, PERMISSION_WRITE)
val SCENARIO_ROLE_VALIDATOR_PERMISSIONS =
val RUNNER_ROLE_VALIDATOR_PERMISSIONS =
listOf(
PERMISSION_READ,
PERMISSION_READ_SECURITY,
PERMISSION_LAUNCH,
PERMISSION_WRITE,
PERMISSION_VALIDATE)
val SCENARIO_ROLE_ADMIN_PERMISSIONS =
val RUNNER_ROLE_ADMIN_PERMISSIONS =
listOf(
PERMISSION_READ,
PERMISSION_READ_SECURITY,
Expand Down Expand Up @@ -77,8 +77,8 @@ fun getAllRolesDefinition(): Map<String, MutableMap<String, MutableList<String>>
.permissions
.mapValues { it.value.toMutableList() }
.toMutableMap(),
"scenario" to
getScenarioRolesDefinition()
"runner" to
getRunnerRolesDefinition()
.permissions
.mapValues { it.value.toMutableList() }
.toMutableMap())
Expand All @@ -100,14 +100,14 @@ fun getCommonRolesDefinition(): RolesDefinition {
adminRole = ROLE_ADMIN)
}

fun getScenarioRolesDefinition(): RolesDefinition {
fun getRunnerRolesDefinition(): RolesDefinition {
return RolesDefinition(
permissions =
mutableMapOf(
ROLE_VIEWER to SCENARIO_ROLE_VIEWER_PERMISSIONS,
ROLE_EDITOR to SCENARIO_ROLE_EDITOR_PERMISSIONS,
ROLE_VALIDATOR to SCENARIO_ROLE_VALIDATOR_PERMISSIONS,
ROLE_ADMIN to SCENARIO_ROLE_ADMIN_PERMISSIONS,
ROLE_VIEWER to RUNNER_ROLE_VIEWER_PERMISSIONS,
ROLE_EDITOR to RUNNER_ROLE_EDITOR_PERMISSIONS,
ROLE_VALIDATOR to RUNNER_ROLE_VALIDATOR_PERMISSIONS,
ROLE_ADMIN to RUNNER_ROLE_ADMIN_PERMISSIONS,
),
adminRole = ROLE_ADMIN)
}
5 changes: 0 additions & 5 deletions src/main/kotlin/com/cosmotech/api/scenario/MetaData.kt

This file was deleted.

16 changes: 0 additions & 16 deletions src/main/kotlin/com/cosmotech/api/scenario/ScenarioMetaData.kt

This file was deleted.

This file was deleted.

This file was deleted.

Loading