|
| 1 | +DESCRIPTION > |
| 2 | + - `repositories` contains repository definitions linked to projects and integrations. |
| 3 | + - Replicated from Postgres - defines repository URLs and their associations with segments, integrations, and insights projects. |
| 4 | + - `id` is the primary key identifier for the repository record. |
| 5 | + - `url` is the full URL of the repository (e.g., GitHub, GitLab repository URL). |
| 6 | + - `segmentId` links to the segment this repository belongs to. |
| 7 | + - `gitIntegrationId` references the git integration used for this repository. |
| 8 | + - `sourceIntegrationId` references the source integration for this repository. |
| 9 | + - `insightsProjectId` links to the insights project this repository is associated with. |
| 10 | + - `archived` indicates whether the repository has been archived. |
| 11 | + - `forkedFrom` contains the URL of the parent repository if this is a fork (empty string if not a fork). |
| 12 | + - `excluded` indicates whether the repository is excluded from processing. |
| 13 | + - `createdAt` and `updatedAt` are standard timestamp fields for record lifecycle tracking. |
| 14 | + - `deletedAt` is set when the repository is soft-deleted. |
| 15 | + - `lastArchivedCheckAt` is the timestamp of the last check for repository archived status. |
| 16 | + |
| 17 | +TAGS "Repositories" |
| 18 | + |
| 19 | +SCHEMA > |
| 20 | + `id` String `json:$.record.id`, |
| 21 | + `url` String `json:$.record.url`, |
| 22 | + `segmentId` String `json:$.record.segmentId`, |
| 23 | + `gitIntegrationId` String `json:$.record.gitIntegrationId`, |
| 24 | + `sourceIntegrationId` String `json:$.record.sourceIntegrationId`, |
| 25 | + `insightsProjectId` String `json:$.record.insightsProjectId`, |
| 26 | + `archived` Bool `json:$.record.archived` DEFAULT false, |
| 27 | + `forkedFrom` String `json:$.record.forkedFrom` DEFAULT '', |
| 28 | + `excluded` Bool `json:$.record.excluded` DEFAULT false, |
| 29 | + `createdAt` DateTime64(3) `json:$.record.createdAt`, |
| 30 | + `updatedAt` DateTime64(3) `json:$.record.updatedAt`, |
| 31 | + `deletedAt` Nullable(DateTime64(3)) `json:$.record.deletedAt`, |
| 32 | + `lastArchivedCheckAt` Nullable(DateTime64(3)) `json:$.record.lastArchivedCheckAt` |
| 33 | + |
| 34 | +ENGINE ReplacingMergeTree |
| 35 | +ENGINE_PARTITION_KEY toYear(createdAt) |
| 36 | +ENGINE_SORTING_KEY url |
| 37 | +ENGINE_VER updatedAt |
0 commit comments