{
  "schema": 1,
  "sqlstate": "58030",
  "condition_name": "io_error",
  "sources": [
    {
      "id": "src.errcodes.18.6",
      "kind": "upstream_source",
      "source_role": "condition_definition",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/errcodes.txt",
      "sha256": "6e8de346643ba84aa3c9c6a73360acfc7b2dfb89162c06c08ce9bf5bcd5bbcba",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/errcodes.txt#L445",
      "lines": "445"
    },
    {
      "id": "src.path.0",
      "kind": "upstream_source",
      "source_role": "buffer_write_path",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/storage/buffer/bufmgr.c",
      "sha256": "453528ad5ab1bf8b7190ed9f866b934646278e06d802de9e5c25b6b807fcda23",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/storage/buffer/bufmgr.c#L4307",
      "lines": "4307-4436"
    },
    {
      "id": "src.path.1",
      "kind": "upstream_source",
      "source_role": "buffer_error_unwind",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/storage/buffer/bufmgr.c",
      "sha256": "453528ad5ab1bf8b7190ed9f866b934646278e06d802de9e5c25b6b807fcda23",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/storage/buffer/bufmgr.c#L6164",
      "lines": "6164-6225"
    },
    {
      "id": "src.path.2",
      "kind": "upstream_source",
      "source_role": "relation_extension_write_error",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/storage/smgr/md.c",
      "sha256": "c7e885c50b381337b8b8624bfc8effbd3abba7aa95a290083996354926ec9f69",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/storage/smgr/md.c#L512",
      "lines": "512-519"
    },
    {
      "id": "src.path.3",
      "kind": "upstream_source",
      "source_role": "file_access_errno_mapping",
      "tag": "REL_18_6",
      "commit": "724edf9bde9d356724ad384a2e196edc3c9f80f7",
      "path": "src/backend/utils/error/elog.c",
      "sha256": "766d30a426ba1d9597657bd46fb890da3e37e4ae53a83d1245bf082ed9433c33",
      "url": "https://github.com/postgres/postgres/blob/724edf9bde9d356724ad384a2e196edc3c9f80f7/src/backend/utils/error/elog.c#L867",
      "lines": "867-942"
    }
  ],
  "claims": [
    {
      "id": "identity",
      "statement": "58030 is io_error in SQLSTATE Class 58.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Read locked definition snapshot."
    },
    {
      "id": "resolved-paths",
      "statement": "FlushBuffer writes a shared buffer through smgrwrite, and AbortBufferIO emits the fixed 58030 warning only after a prior I/O error is present on a valid dirty buffer.",
      "sources": [
        "src.path.0",
        "src.path.1"
      ],
      "method": "Read the complete fixed write and error-unwind contexts.",
      "limits": "Source confirmation is not natural runtime."
    },
    {
      "id": "relation-extension-errno",
      "statement": "The relation-extension FileWrite path emits ERROR with a %m primary and errcode_for_file_access(); saved EIO maps to 58030 and saved ENOSPC maps to 53100.",
      "sources": [
        "src.path.2",
        "src.path.3"
      ],
      "method": "Read the complete negative-write branch and the saved-errno switch.",
      "limits": "The source establishes message roles and code mapping, not a natural I/O failure on a host."
    },
    {
      "id": "history",
      "statement": "The locked catalogue records 58030 from 7.4; it does not prove the exact introduction or every historical emitter.",
      "sources": [
        "src.errcodes.18.6"
      ],
      "method": "Use locked catalogue boundary."
    }
  ],
  "messages": [
    {
      "id": "message.0",
      "sqlstate": "58030",
      "primary_template": "could not write block %u of %s",
      "severity_source": "WARNING",
      "sources": [
        "src.path.0",
        "src.path.1"
      ],
      "detail_template": "Multiple failures --- write error might be permanent.",
      "context_template": "writing block %u of relation \"%s\""
    },
    {
      "id": "message.1",
      "sqlstate": "58030",
      "primary_template": "could not extend file \"%s\": %m",
      "severity_source": "ERROR",
      "sources": [
        "src.path.2"
      ],
      "code_selection": "errcode_for_file_access()",
      "errno_condition": "saved errno EIO",
      "hint_template": "Check free disk space."
    }
  ],
  "usage_evidence": [
    {
      "scope": "definition",
      "status": "definition_only",
      "evidence_ids": [
        "identity"
      ]
    },
    {
      "scope": "fixed-source-path",
      "status": "source_path_confirmed",
      "evidence_ids": [
        "resolved-paths",
        "relation-extension-errno"
      ]
    },
    {
      "scope": "history",
      "status": "unknown",
      "evidence_ids": [
        "history"
      ]
    },
    {
      "scope": "natural-runtime",
      "status": "unknown",
      "evidence_ids": [
        "resolved-paths",
        "relation-extension-errno"
      ]
    }
  ],
  "runtime": []
}
