{
  "description": "Replica is where Longhorn stores replica object.",
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
      "type": [
        "string",
        "null"
      ]
    },
    "kind": {
      "description": "Kind is a string value representing the REST resource this object represents.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": [
        "string",
        "null"
      ]
    },
    "metadata": {
      "type": [
        "object",
        "null"
      ]
    },
    "spec": {
      "additionalProperties": false,
      "description": "ReplicaSpec defines the desired state of the Longhorn replica",
      "properties": {
        "active": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "backingImage": {
          "type": [
            "string",
            "null"
          ]
        },
        "dataDirectoryName": {
          "type": [
            "string",
            "null"
          ]
        },
        "dataEngine": {
          "enum": [
            "v1",
            "v2"
          ],
          "type": [
            "string",
            "null"
          ]
        },
        "desireState": {
          "type": [
            "string",
            "null"
          ]
        },
        "diskID": {
          "type": [
            "string",
            "null"
          ]
        },
        "diskPath": {
          "type": [
            "string",
            "null"
          ]
        },
        "engineName": {
          "type": [
            "string",
            "null"
          ]
        },
        "evictionRequested": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "failedAt": {
          "description": "FailedAt is set when a running replica fails or when a running engine is unable to use a replica for any reason.\nFailedAt indicates the time the failure occurred. When FailedAt is set, a replica is likely to have useful\n(though possibly stale) data. A replica with FailedAt set must be rebuilt from a non-failed replica (or it can\nbe used in a salvage if all replicas are failed). FailedAt is cleared before a rebuild or salvage. FailedAt may\nbe later than the corresponding entry in an engine's replicaTransitionTimeMap because it is set when the volume\ncontroller acknowledges the change.",
          "type": [
            "string",
            "null"
          ]
        },
        "hardNodeAffinity": {
          "type": [
            "string",
            "null"
          ]
        },
        "healthyAt": {
          "description": "HealthyAt is set the first time a replica becomes read/write in an engine after creation or rebuild. HealthyAt\nindicates the time the last successful rebuild occurred. When HealthyAt is set, a replica is likely to have\nuseful (though possibly stale) data. HealthyAt is cleared before a rebuild. HealthyAt may be later than the\ncorresponding entry in an engine's replicaTransitionTimeMap because it is set when the volume controller\nacknowledges the change.",
          "type": [
            "string",
            "null"
          ]
        },
        "image": {
          "type": [
            "string",
            "null"
          ]
        },
        "lastFailedAt": {
          "description": "LastFailedAt is always set at the same time as FailedAt. Unlike FailedAt, LastFailedAt is never cleared.\nLastFailedAt is not a reliable indicator of the state of a replica's data. For example, a replica with\nLastFailedAt may already be healthy and in use again. However, because it is never cleared, it can be compared to\nLastHealthyAt to help prevent dangerous replica deletion in some corner cases. LastFailedAt may be later than the\ncorresponding entry in an engine's replicaTransitionTimeMap because it is set when the volume controller\nacknowledges the change.",
          "type": [
            "string",
            "null"
          ]
        },
        "lastHealthyAt": {
          "description": "LastHealthyAt is set every time a replica becomes read/write in an engine. Unlike HealthyAt, LastHealthyAt is\nnever cleared. LastHealthyAt is not a reliable indicator of the state of a replica's data. For example, a\nreplica with LastHealthyAt set may be in the middle of a rebuild. However, because it is never cleared, it can be\ncompared to LastFailedAt to help prevent dangerous replica deletion in some corner cases. LastHealthyAt may be\nlater than the corresponding entry in an engine's replicaTransitionTimeMap because it is set when the volume\ncontroller acknowledges the change.",
          "type": [
            "string",
            "null"
          ]
        },
        "logRequested": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "migrationEngineName": {
          "description": "MigrationEngineName is indicating the migrating engine which current connected to this replica. This is only\nused for live migration of v2 data engine",
          "type": [
            "string",
            "null"
          ]
        },
        "nodeID": {
          "type": [
            "string",
            "null"
          ]
        },
        "rebuildRetryCount": {
          "type": [
            "integer",
            "null"
          ]
        },
        "revisionCounterDisabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "salvageRequested": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "snapshotMaxCount": {
          "type": [
            "integer",
            "null"
          ]
        },
        "snapshotMaxSize": {
          "format": "int64",
          "type": [
            "string",
            "null"
          ]
        },
        "unmapMarkDiskChainRemovedEnabled": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "volumeName": {
          "type": [
            "string",
            "null"
          ]
        },
        "volumeSize": {
          "format": "int64",
          "type": [
            "string",
            "null"
          ]
        }
      },
      "type": [
        "object",
        "null"
      ]
    },
    "status": {
      "additionalProperties": false,
      "description": "ReplicaStatus defines the observed state of the Longhorn replica",
      "properties": {
        "conditions": {
          "items": {
            "additionalProperties": false,
            "properties": {
              "lastProbeTime": {
                "description": "Last time we probed the condition.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "lastTransitionTime": {
                "description": "Last time the condition transitioned from one status to another.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "message": {
                "description": "Human-readable message indicating details about last transition.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "reason": {
                "description": "Unique, one-word, CamelCase reason for the condition's last transition.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "status": {
                "description": "Status is the status of the condition.\nCan be True, False, Unknown.",
                "type": [
                  "string",
                  "null"
                ]
              },
              "type": {
                "description": "Type is the type of the condition.",
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "type": "object"
          },
          "nullable": true,
          "type": [
            "array",
            "null"
          ]
        },
        "currentImage": {
          "type": [
            "string",
            "null"
          ]
        },
        "currentState": {
          "type": [
            "string",
            "null"
          ]
        },
        "instanceManagerName": {
          "type": [
            "string",
            "null"
          ]
        },
        "ip": {
          "type": [
            "string",
            "null"
          ]
        },
        "logFetched": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "ownerID": {
          "type": [
            "string",
            "null"
          ]
        },
        "port": {
          "type": [
            "integer",
            "null"
          ]
        },
        "salvageExecuted": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "started": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "starting": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "storageIP": {
          "type": [
            "string",
            "null"
          ]
        },
        "ublkID": {
          "format": "int32",
          "type": [
            "integer",
            "null"
          ]
        },
        "uuid": {
          "type": [
            "string",
            "null"
          ]
        }
      },
      "type": [
        "object",
        "null"
      ]
    }
  },
  "type": "object"
}