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
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,15 @@
"tenantId",
"occurredAt"
],
"x-event-type-settings": {
"x-gts-traits-schema": {
"type": "object",
"additionalProperties": false,
"topicRef": {
"description": "ID of the topic where events of this type are stored.",
"type": "string",
"x-gts-ref":"gts.x.core.events.topic.v1~"
"properties": {
"topicRef": {
"description": "ID of the topic where events of this type are stored.",
"type": "string",
"x-gts-ref": "gts.x.core.events.topic.v1~"
}
}
},
"properties": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,27 @@
"displayName": "WebStore Product Catalog module",
"description": "WebStore module providing Products Catalog capabilities.",
"capabilities": [
"gts.x.core.modules.capability.v1~x.core.api.has_rest.v1"
"gts.x.core.modules.capability.v1~x.core.api.has_rest.v1"
],
"requirements": [],
"configSchema": {
"type": "object",
"properties": {
"default_products_view": { "type": "string", "enum": ["table", "list"] },
"default_products_per_page": { "type": "int", "minimum": 1, "maximum": 100, "default": 20 },
"default_region": { "type": "string", "description": "Default region for product availability" },
"default_products_view": {
"type": "string",
"enum": [
"table",
"list"
]
},
"default_region": {
"type": "string",
"description": "Default region for product availability"
}
},
"required": ["default_region"],
"required": [
"default_region"
],
"additionalProperties": false
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
"capabilities": [
"gts.x.core.modules.capability.v1~x.core.api.has_rest.v1",
"gts.x.core.modules.capability.v1~x.core.api.has_ws.v1",
"gts.x.core.modules.capability.v1~x.core.api.has_sse.v1"
"gts.x.core.modules.capability.v1~x.core.api.has_sse.v1"
],
"requirements": [
"gts.x.core.modules.module.v1~x.webstore._.catalog.v1"
"gts.x.core.modules.module.v1~x.webstore._.catalog.v1"
],
"configSchema": {
"type": "object",
Expand All @@ -18,7 +18,7 @@
"description": "Max chat messages retention in days",
"default": "90",
"minimum": 0,
"maximum": 356,
"maximum": 356
},
"max_file_size": {
"type": "int",
Expand All @@ -30,7 +30,9 @@
"default": true
}
},
"required": ["max_file_size"],
"required": [
"max_file_size"
],
"additionalProperties": false
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "gts://gts.x.core.modules.capability.v1~",
"description": "Base schema for any application modules capabilities",
"required": ["description", "id"],
"required": [
"description",
"id"
],
"properties": {
"id": {
"type": "string",
Expand All @@ -11,7 +14,7 @@
"description": {
"type": "string",
"maxLength": 500
},
"additionalProperties": false
}
}
},
"additionalProperties": false
}
2 changes: 1 addition & 1 deletion examples/typespec/vms/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ These examples demonstrate:

- **[gts.x.infra.compute.vm.v1~](schemas/gts.x.infra.compute.vm.v1~.tsp)** ([JSON Schema](schemas/gts.x.infra.compute.vm.v1~.schema.json))
- Base virtual machine type with common properties
- Properties: `gtsId`, `id`, `name`, `cpuCores`, `ramMb`, `powerState`, `osType`, `createdAt`, `environment`, `owner`, `metadata`
- Properties: `type`, `id`, `name`, `cpuCores`, `ramMb`, `powerState`, `osType`, `createdAt`, `environment`, `owner`, `metadata`
- `powerState` uses GTS reference pattern for backward-compatible extensibility

### Derived Types
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.migrating.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.migrating.v1",
"description": "Virtual machine is being migrated to another host",
"isTransient": true,
"icon": "move"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.paused.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.paused.v1",
"description": "Virtual machine is temporarily paused, memory state preserved",
"isTransient": false,
"icon": "pause-circle"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.rebooting.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.rebooting.v1",
"description": "Virtual machine is rebooting",
"isTransient": true,
"icon": "refresh"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.running.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.running.v1",
"description": "Virtual machine is running and operational",
"isTransient": false,
"icon": "play"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.starting.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.starting.v1",
"description": "Virtual machine is starting up",
"isTransient": true,
"icon": "loader"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.stopped.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.stopped.v1",
"description": "Virtual machine is stopped and not consuming compute resources",
"isTransient": false,
"icon": "stop"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.stopping.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.stopping.v1",
"description": "Virtual machine is shutting down",
"isTransient": true,
"icon": "loader"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.suspended.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.suspended.v1",
"description": "Virtual machine state is saved to disk and can be resumed quickly",
"isTransient": false,
"icon": "pause"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm_state.v1~x.infra._.suspending.v1",
"id": "gts.x.infra.compute.vm_state.v1~x.infra._.suspending.v1",
"description": "Virtual machine is saving state to disk",
"isTransient": true,
"icon": "loader"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~",
"type": "gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~",
"id": "550e8400-e29b-41d4-a716-446655440002",
"name": "db-server-01",
"cpuCores": 8,
Expand All @@ -25,4 +25,4 @@
"haPriority": "high",
"backupSchedule": "daily"
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~",
"type": "gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~",
"id": "550e8400-e29b-41d4-a716-446655440001",
"name": "web-server-01",
"cpuCores": 4,
Expand All @@ -21,4 +21,4 @@
"vMotionEnabled": true,
"costCenter": "CC-1001"
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"gtsId": "gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~",
"type": "gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~",
"id": "550e8400-e29b-41d4-a716-446655440003",
"name": "app-server-01",
"cpuCores": 2,
Expand All @@ -23,4 +23,4 @@
"backupNodeName": "vz-node-02.example.com",
"project": "microservices-platform"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"description": "Base type for all virtual machine definitions across different virtualization platforms.",
"type": "object",
"required": [
"gtsId",
"type",
"id",
"name",
"cpuCores",
Expand All @@ -14,7 +14,7 @@
"createdAt"
],
"properties": {
"gtsId": {
"type": {
"type": "string",
"description": "GTS identifier of the VM type",
"x-gts-ref": "/$id"
Expand Down Expand Up @@ -45,7 +45,7 @@
"powerState": {
"type": "string",
"description": "Current power state of the virtual machine. Reference to gts.x.infra.compute.vm_state.v1~ type.",
"x-gts-ref": "/gts.x.infra.compute.vm_state.v1~"
"x-gts-ref": "gts.x.infra.compute.vm_state.v1~"
},
"osType": {
"type": "string",
Expand All @@ -69,4 +69,4 @@
"description": "Additional metadata and platform-specific properties"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ model BaseVM {
* GTS identifier of the VM type
*/
@extension("x-gts-ref", "/$id")
gtsId: string;
type: string;

/**
* Unique identifier of the VM instance
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
{
"type": "object",
"properties": {
"gtsId": {
"type": {
"type": "string",
"const": "gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~",
"description": "GTS identifier of the VM type",
Expand Down Expand Up @@ -73,4 +73,4 @@
}
}
]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using TypeSpec.JsonSchema;
@jsonSchema("/schemas/gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~.schema.json")
model NutanixAHVVM {
@extension("x-gts-ref", "/$id")
gtsId: "gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~";
type: "gts.x.infra.compute.vm.v1~nutanix.ahv._.vm.v1~";

@format("uuid")
id: string;
Expand Down Expand Up @@ -41,7 +41,7 @@ model NutanixAHVVM {

environment?: string;
owner?: string;

/** Nutanix-specific metadata (strictly typed) */
metadata?: NutanixMetadata;
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
{
"type": "object",
"properties": {
"gtsId": {
"type": {
"type": "string",
"const": "gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~",
"description": "GTS identifier of the VM type",
Expand Down Expand Up @@ -70,4 +70,4 @@
}
}
]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using TypeSpec.JsonSchema;
@jsonSchema("/schemas/gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~.schema.json")
model VMWareESXiVM {
@extension("x-gts-ref", "/$id")
gtsId: "gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~";
type: "gts.x.infra.compute.vm.v1~vmware.esxi._.vm.v1~";

@format("uuid")
id: string;
Expand Down Expand Up @@ -41,7 +41,7 @@ model VMWareESXiVM {

environment?: string;
owner?: string;

/** VMWare-specific metadata (strictly typed) */
metadata?: VMWareMetadata;
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
{
"type": "object",
"properties": {
"gtsId": {
"type": {
"type": "string",
"const": "gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~",
"description": "GTS identifier of the VM type",
Expand Down Expand Up @@ -69,4 +69,4 @@
}
}
]
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using TypeSpec.JsonSchema;
@jsonSchema("/schemas/gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~.schema.json")
model VirtuozzoVM {
@extension("x-gts-ref", "/$id")
gtsId: "gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~";
type: "gts.x.infra.compute.vm.v1~vz.vz._.vm.v1~";

@format("uuid")
id: string;
Expand Down Expand Up @@ -41,7 +41,7 @@ model VirtuozzoVM {

environment?: string;
owner?: string;

/** Virtuozzo-specific metadata (strictly typed) */
metadata?: VirtuozzoMetadata;
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
gtsId: gts.x.ui.core.item.v1~x.ui.components.grid.v1~
gtsType: gts.x.ui.core.item.v1~x.ui.components.grid.v1~
id: 550e8400-e29b-41d4-a716-446655440012
type: grid
label: Users List
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
gtsId: gts.x.ui.core.item.v1~x.ui.components.menu_item.v1~
gtsType: gts.x.ui.core.item.v1~x.ui.components.menu_item.v1~
id: 550e8400-e29b-41d4-a716-446655440010
type: menu_item
label: Dashboard
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
gtsId: gts.x.ui.core.item.v1~x.ui.components.menu_item.v1~
gtsType: gts.x.ui.core.item.v1~x.ui.components.menu_item.v1~
id: 550e8400-e29b-41d4-a716-446655440011
type: menu_item
label: Settings
Expand Down