Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch from GetCommits to ListCommits #8

Merged
merged 1 commit into from
Mar 28, 2024

Conversation

stefanvanburen
Copy link
Owner

GetCommits will only return a single commit for each ResourceRef given; we want to get a list of commits here, starting with the given ResourceRef.

Waiting to merge this until it's implemented. (Apparently you can't create draft PRs without an upgraded GitHub plan??)

GetCommits will only return a single commit for each ResourceRef given;
we want to get a list of commits here, starting with the given
ResourceRef.

Waiting to merge this until it's implemented.
@stefanvanburen
Copy link
Owner Author

Looks like this is working now:

$ buf curl --schema buf.build/bufbuild/registry --data '{ "pageSize": 10, "resourceRef": { "name": { "owner": "bufbuild", "module": "registry" } } }' https://buf.build/buf.registry.module.v1.CommitService/ListCommits
{
  "nextPageToken": "e5f1a178-f7f7-4966-ac3b-3cb28526479a",
  "commits": [
    {
      "id": "2f185409-3b57-475c-8e64-3c23784cd7dc",
      "createTime": "2024-03-27T20:54:14.055123Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "BB0h/wZ2LBzbwreehTJ5OfhTEbCVKe7p5p0adw9hYgcNiTkt/37R+zUH5GPsgU7Yl1mgbaErQttif6NHlR5C/w=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "1d87523a-12b4-4caa-8d63-41f8a90e9ecb",
      "createTime": "2024-03-25T23:58:33.787686Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "TVDYvv3IWZi5P8Fq6oht+n1gtrkzkWAIrHdnOV/XYsTlUiv8rj+Remb9CfoY7miK4sTCNIC1TQ0i+UqfqRgp/g=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "1c87dc95-55ae-4618-9f20-a03c967d035b",
      "createTime": "2024-03-19T00:10:36.777199Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "oZmtiW+ifqTB35Zc/JvriLgNduIeN7EeC3Os3Yaim1p/BmRzsFfpEz4zUX49MoKQb5OgSgebKCWCBZNVe8bMKA=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "1bc3a253-fead-44a8-ad0d-536e96eb5f52",
      "createTime": "2024-03-18T22:59:22.844352Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "d/zmeNl2W0Uco7Q1mCmGRbQwaOnvWH88WoXYbTBNnv9D4KPgz8c2on4IOHFNUfPr/zgj0zZJdExGijzfj9QC2A=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "78e5a5be-c59d-4a15-93f8-93209554de87",
      "createTime": "2024-03-18T20:53:09.887009Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "qGU9nlQXviPH601JmgbXVQ3drW0R70r3G3RHJkoUutNikA+4rPUlxuiDX//ELWxbFbhDsbjKwRHRcgyy+yEhyw=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "9574ab30-024d-4c4d-b44c-0a7c19ce5dc8",
      "createTime": "2024-03-18T15:22:00.790481Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "H4WWjifV9d7WUFhM6ZIGeM+HHaAfAQZAj/GSO+RjwAu72UWGylALoIM6yIst8hF7atEE62qZsMM8g/OaVwcL1w=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "4350a0ec-c53b-40a7-bb0a-021f473c98a3",
      "createTime": "2024-03-11T19:26:02.239058Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "TY3ho8wj+wsavsC3aFMbWx/yBpkn7nGNCFElr9hWW+utGK3nUcrl830Lx5po6gY/euKYz3NL5Xf+TSfh60A79w=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "148855da-0f07-4e47-af6d-cc58cb235598",
      "createTime": "2024-03-11T16:56:45.747365Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "z/0crpL9G/2731+5vVqCl9DTMl9fDnCHEp0gRWdE2aeNqO6VAUNHR/m9Dw+/DbctjCvS+LiMbZMIkRppB6KEHA=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "f5cf5cc4-01ff-45c1-9d28-2aafcffe33cf",
      "createTime": "2024-03-11T03:31:53.334771Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "t2pkwACTBgMl2ASzgYwJEL7D3m752tqFfeIb7Ag576fZKNb6kmdSRTs1f/3FUSQaNQO0QRm96gLbbP5JX8DuUQ=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    },
    {
      "id": "e4b154a0-1e41-4234-b938-036557a970c0",
      "createTime": "2024-03-08T23:43:19.574393Z",
      "ownerId": "84a2ccce-08d6-4889-837f-dfc5047c4cbd",
      "moduleId": "11bdb5ab-fb54-4d54-b2a3-b7a354a07112",
      "digest": {
        "type": "DIGEST_TYPE_B5",
        "value": "jT1TYgLuiPgAILGlk6GtLmhKSC0iRgwyYG5uz1P78GxmL9JK+oTrSUNg2BzSW5xPaHC7tVLzh/cbnmmwNXVJ9w=="
      },
      "createdByUserId": "616103da-48a7-47a0-aa06-cfe1116ea778"
    }
  ]
}

@stefanvanburen stefanvanburen merged commit 8966ed3 into main Mar 28, 2024
1 check passed
@stefanvanburen stefanvanburen deleted the svanburen/list-commits branch March 28, 2024 01:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant