`contributor_repo` table does not relate to `repo`

Đang mở
#551 9 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
20/100
Loại issue
Tái cấu trúc
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Sôi nổi
Công nghệ
python, sql
Lĩnh vực
databases

Hướng nghiên cứu

The contributor_repo table is filled by the contributor breadth worker; inspect that worker and the database schema to see how repo_git and gh_repo_id are written. First read the worker code and any migration scripts, then discuss with maintainers whether to link to repo via repo_src_id. Done means an agreed plan to reclaim space and add the foreign key before multi-forge support.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

database discussion needs-plan tech debt

the contributor_repo table does not have a foreign key to the repo table.

It has its own repo_git column and repo_name column which i dont believe is getting updated when repos move/get renamed. it appears to store events from the github events api (such as PushEvent and CreateEvent). Do we want to keep storing the historical names as they were when the data was collected? the urls seem likely redundant.

We do also have a gh_repo_id column so we can maybe associate this table with repo using the repo_src_id - this would be best to do before we move over to supporting other forges, otherwise this migration may be more difficult

In our 42k repo instance, this table is ~120GB

This table seems to be filled in by the contributor breadth worker.

The unique key on this table seems to be up to ~1.4 billion (im pretty sure its an autoincrement integer)

I suspect this table also has not been the target of any deletion queries we have ever run on this database

This table does not appear to be used by 8Knot but may be used by DSWG notebooks (and some internal stuff)

What should we do to make this table a more sensible use of space?

Ngôn ngữ chính
Python
Star
17
Fork
30
Merge trung bình
6 giờ 16 phút
Pull request đã merge (30 ngày)
9

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của chaoss/CollectOSS

Tất cả issue của chaoss/CollectOSS

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.