功能修改
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
"$id": "https://browser.local/schemas/game-plugin.manifest.schema.json",
|
||||
"title": "GamePluginManifest",
|
||||
"type": "object",
|
||||
"required": ["id", "name", "version", "kind", "server", "capabilities", "permissions"],
|
||||
"required": ["id", "name", "version", "kind", "server", "capabilities", "permissions", "productionLifecycle"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"$schema": { "type": "string" },
|
||||
@@ -42,6 +42,9 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"gameClientBridge": {
|
||||
"$ref": "#/$defs/gameClientBridgeManifest"
|
||||
},
|
||||
"capabilities": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/runCapability" },
|
||||
@@ -106,6 +109,12 @@
|
||||
"items": { "$ref": "#/$defs/runtimeLogSource" },
|
||||
"uniqueItems": true
|
||||
},
|
||||
"logEvents": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/runtimeLogEvent" },
|
||||
"uniqueItems": true,
|
||||
"maxItems": 128
|
||||
},
|
||||
"transportProfiles": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/runtimeTransportProfile" },
|
||||
@@ -130,6 +139,25 @@
|
||||
"status": { "$ref": "#/$defs/relativeJsonRef" }
|
||||
}
|
||||
},
|
||||
"productionLifecycle": {
|
||||
"type": "object",
|
||||
"required": ["operations", "dependencyPolicy", "approvalRequired"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"operations": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/productionLifecycleOperation" },
|
||||
"uniqueItems": true,
|
||||
"minItems": 1
|
||||
},
|
||||
"dependencyPolicy": { "enum": ["required", "optional"] },
|
||||
"approvalRequired": {
|
||||
"type": "array",
|
||||
"items": { "enum": ["disable", "rollback", "retire"] },
|
||||
"uniqueItems": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"pages": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
@@ -147,13 +175,124 @@
|
||||
},
|
||||
"ai": {
|
||||
"type": "object",
|
||||
"required": ["mediation", "configWritePolicy"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"purposes": { "type": "array", "items": { "$ref": "#/$defs/aiPurpose" }, "uniqueItems": true }
|
||||
"purposes": { "type": "array", "items": { "$ref": "#/$defs/aiPurpose" }, "uniqueItems": true },
|
||||
"mediation": { "const": "platform" },
|
||||
"configWritePolicy": { "const": "review-required" }
|
||||
}
|
||||
}
|
||||
},
|
||||
"$defs": {
|
||||
"gameClientBridgeManifest": {
|
||||
"type": "object",
|
||||
"required": ["commands", "snapshots", "commandRetentionSeconds", "maxCommands"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"commands": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/gameClientBridgeCommand" },
|
||||
"maxItems": 128
|
||||
},
|
||||
"snapshots": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/gameClientBridgeSnapshot" },
|
||||
"maxItems": 128
|
||||
},
|
||||
"queryTemplates": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/gameClientBridgeQueryTemplate" },
|
||||
"maxItems": 128
|
||||
},
|
||||
"commandRetentionSeconds": { "type": "integer", "minimum": 1, "maximum": 31536000 },
|
||||
"maxCommands": { "type": "integer", "minimum": 1, "maximum": 100000 },
|
||||
"pages": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/gameClientBridgePageContract" },
|
||||
"maxItems": 64
|
||||
},
|
||||
"companion": { "$ref": "#/$defs/gameClientBridgeCompanion" }
|
||||
}
|
||||
},
|
||||
"gameClientBridgeCompanion": {
|
||||
"type": "object",
|
||||
"required": ["profileKey", "configTemplateKey", "configSchemaRef", "configFormat", "platformBaseUrlSource", "registrationProof", "proofMaterialSource", "proofMaterialEnv", "sessionMode", "tlsPolicy", "heartbeatIntervalSeconds", "commandPollIntervalSeconds", "requestTimeoutSeconds"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"profileKey": { "$ref": "#/$defs/logicalKey" },
|
||||
"configTemplateKey": { "$ref": "#/$defs/logicalKey" },
|
||||
"configSchemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"configFormat": { "const": "yaml" },
|
||||
"platformBaseUrlSource": { "const": "run-control" },
|
||||
"registrationProof": { "const": "hmac-sha256" },
|
||||
"proofMaterialSource": { "const": "component-package" },
|
||||
"proofMaterialEnv": { "type": "string", "pattern": "^[A-Z][A-Z0-9_]{2,63}$" },
|
||||
"sessionMode": { "const": "component-session" },
|
||||
"tlsPolicy": { "const": "verify-system-roots" },
|
||||
"heartbeatIntervalSeconds": { "type": "integer", "minimum": 5, "maximum": 300 },
|
||||
"commandPollIntervalSeconds": { "type": "integer", "minimum": 1, "maximum": 60 },
|
||||
"requestTimeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 60 }
|
||||
}
|
||||
},
|
||||
"gameClientBridgeCommand": {
|
||||
"type": "object",
|
||||
"required": ["type", "title", "permission", "approvalLevel", "payloadSchemaRef", "timeoutSeconds", "maxPayloadBytes"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"type": { "type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,159}$" },
|
||||
"title": { "type": "string", "minLength": 1, "maxLength": 80 },
|
||||
"permission": { "$ref": "#/$defs/pluginPermission" },
|
||||
"approvalLevel": { "enum": ["none", "operator", "platform-admin"] },
|
||||
"payloadSchemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"resultSchemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 3600 },
|
||||
"maxPayloadBytes": { "type": "integer", "minimum": 1, "maximum": 65536 }
|
||||
}
|
||||
},
|
||||
"gameClientBridgeSnapshot": {
|
||||
"type": "object",
|
||||
"required": ["type", "schemaVersion", "schemaRef", "keepForSeconds", "maxRecords"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"type": { "type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,159}$" },
|
||||
"schemaVersion": { "type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,159}$" },
|
||||
"schemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"keepForSeconds": { "type": "integer", "minimum": 1, "maximum": 2678400 },
|
||||
"maxRecords": { "type": "integer", "minimum": 1, "maximum": 10000 }
|
||||
}
|
||||
},
|
||||
"gameClientBridgeQueryTemplate": {
|
||||
"type": "object",
|
||||
"required": ["key", "title", "permission", "engine", "transportKey", "targetKey", "parameterSchemaRef", "resultSchemaRef", "maxRows", "timeoutSeconds"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"key": { "type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,159}$" },
|
||||
"title": { "type": "string", "minLength": 1, "maxLength": 80 },
|
||||
"permission": { "$ref": "#/$defs/pluginPermission" },
|
||||
"engine": { "const": "sqlite" },
|
||||
"transportKey": { "$ref": "#/$defs/logicalKey" },
|
||||
"targetKey": { "$ref": "#/$defs/logicalKey" },
|
||||
"parameterSchemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"resultSchemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"maxRows": { "type": "integer", "minimum": 1, "maximum": 500 },
|
||||
"timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 60 }
|
||||
}
|
||||
},
|
||||
"gameClientBridgePageContract": {
|
||||
"type": "object",
|
||||
"required": ["pageKey"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"pageKey": { "type": "string", "pattern": "^[a-z0-9][a-z0-9-]*$" },
|
||||
"commandTypes": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
||||
"snapshotTypes": { "type": "array", "items": { "type": "string" }, "uniqueItems": true },
|
||||
"queryTemplateKeys": { "type": "array", "items": { "type": "string" }, "uniqueItems": true }
|
||||
}
|
||||
},
|
||||
"productionLifecycleOperation": {
|
||||
"enum": ["install", "enable", "disable", "upgrade", "rollback", "retire", "dependency-check"]
|
||||
},
|
||||
"relativeJsonRef": {
|
||||
"type": "string",
|
||||
"pattern": "^(?!/)(?![A-Za-z]:)(?!.*://)(?!.*\\.\\.)[a-zA-Z0-9_./-]+\\.json$"
|
||||
@@ -165,6 +304,7 @@
|
||||
"process.stop",
|
||||
"process.restart",
|
||||
"process.status",
|
||||
"config.write",
|
||||
"files.list",
|
||||
"files.read",
|
||||
"files.write",
|
||||
@@ -206,6 +346,9 @@
|
||||
"server.run.distribution",
|
||||
"server.dependencies.manage",
|
||||
"server.client-manager.manage",
|
||||
"server.game-client.read",
|
||||
"server.game-client.command",
|
||||
"server.game-client.maintenance",
|
||||
"ai.invoke"
|
||||
]
|
||||
},
|
||||
@@ -221,6 +364,7 @@
|
||||
"dependencies.request",
|
||||
"logs.backfill.request",
|
||||
"client-manager.request",
|
||||
"plugin-lifecycle.request",
|
||||
"ai.invoke"
|
||||
]
|
||||
},
|
||||
@@ -361,6 +505,21 @@
|
||||
"retentionDays": { "type": "integer", "minimum": 1, "maximum": 365 }
|
||||
}
|
||||
},
|
||||
"runtimeLogEvent": {
|
||||
"type": "object",
|
||||
"required": ["key", "title", "sourceKey", "eventType", "permission", "schemaRef", "retentionDays", "severity"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"key": { "$ref": "#/$defs/logicalKey" },
|
||||
"title": { "type": "string", "minLength": 1, "maxLength": 80 },
|
||||
"sourceKey": { "$ref": "#/$defs/logicalKey" },
|
||||
"eventType": { "type": "string", "pattern": "^[a-z0-9][a-z0-9._-]{0,119}$" },
|
||||
"permission": { "$ref": "#/$defs/pluginPermission" },
|
||||
"schemaRef": { "$ref": "#/$defs/relativeJsonRef" },
|
||||
"retentionDays": { "type": "integer", "minimum": 1, "maximum": 365 },
|
||||
"severity": { "enum": ["info", "notice", "warning", "critical"] }
|
||||
}
|
||||
},
|
||||
"runtimeTransportProfile": {
|
||||
"type": "object",
|
||||
"required": ["key", "kind", "capabilities"],
|
||||
|
||||
Reference in New Issue
Block a user