-
Notifications
You must be signed in to change notification settings - Fork 63
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
[FAI-14747] Support ingesting deployments data from bigquery #1892
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some small comment / suggestions
build: { | ||
uid: buildUid, | ||
}, | ||
changeset: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't those line be removed since we add the DeploymentChangeset object below?
if (uid) { | ||
res.push({ | ||
model: 'cicd_Deployment', | ||
record: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typically, for the changeset feed to work, we need the application; i understand we may not have it in the example, but maybe we should have support for it?
const res: DestinationRecord[] = []; | ||
|
||
//cicd_Deployment | ||
const uid = record.record.data.uid; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are we documenting anywhere what is the structure of the expected record?
}, | ||
changeset: { | ||
commit: { | ||
sha: commit, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typically, the commit sha of the deployment goes in a different object: vcs_Commit through a cicd_ArtifactCommitAssociation object through a dummy cicd_Artifact object through a dummy cicd_ArtifactDeployment object
See what the changeset feed queries to find it here: https://github.com/faros-ai/feeds/blob/master/feeds/cicd/changeset-feed/resources/graphql/deployments.gql#L28
}); | ||
|
||
res.push({ | ||
model: 'cicd_DeploymentChangeset', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
assuming you write the commit sha through a vcs_Commit object as stated above, I would remove this and let the changeset feed set it
No description provided.