-
Notifications
You must be signed in to change notification settings - Fork 337
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
Integration task architecture spec'd #5968
Comments
Storing integration for
|
Storing integration provider specific dataLegacy integration auth tables
|
Thank you so much for getting this kicked off! Questions:
|
I understand that it is inconvenient that all integrations would have different field names for storing their data. Not sure if we need to store separate fields as a single string, as I agree with Matt, it will not allow us to use database constraints, indexes and make queries more complex. What if we go this way:
We do not use We use only two fields, However, it is also not a problem to have an additional So alternative is :
I would still prefer to have no parsing probably and go with having separate field for What do you think? |
Which exact fields are on |
No strong preference here, just as long as it's not cumbersome or expensive for tasks connected via github, gitlab, et al |
I faced this issue while doing #6238: "Store issueId instead of issueNumber for GitHub issue integration #6252" We need to recalculate GitHub hashes or store Considering this, I would suggest the following:
|
i think search queries probably deserve their own table. It makes sense to index them on
IIRC projectIds are just a GUID consisting of a cloudId + projectKey. If that's correct, then we can just make it as long as we have both of those values. |
I haven't started implementing the search query for GitLab, but creating their own table sounds good to me. For GitLab, I'm storing the |
@Dschoordsch now that we're a few integrations in, should this issue be closed? |
I would have to take another look, but I suspect we could unify search and also could migrate GitHub and Jira to IntegrationProvider. Both doesn't solve any immediate problems, so let's just skip this for now until we're in there again. |
Now we have a generic data structure for multiple integrations and should move towards unifying the existing Jira and GitHub integrations to avoid duplication and simplify adding new ones. We're adding Jira Server and GitLab as new integrations and these should already follow a new generic design.
Notification integrations (i.e. slack/mattermost) are out of scope here.
Current state
IntegrationProvider
, it can be 'org', 'team' or 'global'. GlobalIntegrationProvider
s are also stored in the DB and added inyarn postDeploy
based on environment variables.TeamMember
for a specificIntegrationProvider
and is used instead of separate tables per service. Conceptually it is a union of different authentication methods (e.g. OAuth1, OAuth2, PAT, ...)New and shiny mutations
addIntegrationProvider
removeIntegrationProvider
updateIntegrationProvider
createTaskIntegration
1addTeamMemberIntegrationAuth
removeTeamMemberIntegrationAuth
Legacy mutations
GitHub and Jira both have their own tables and mutations.
addGitHubAuth
addAtlassianAuth
removeAtlassianAuth
createGitHubTask
createJiraTask
createGitHubTaskIntegration
1createJiraTaskIntegration
1persistGitHubSearchQuery
persistJiraSearchQuery
updateGitHubDimensionField
updateJiraDimensionField
pushEstimateToGitHub
addMissingJiraField
Legacy queries
fetchGitHubRepos
fetchAtlassianProjects
Goal
We want to make adding new IntegrationProvider services easy. Service specific logic on the backend side should be encapsulated in their respective
<Service>Manager
and the data stored in a common table.If there is something specific to one service only (e.g. adding a missing field), this does not need to be forced into one generic method.
Acceptance criteria
ServiceManager
which supports these new mutationsNext steps (out of scope)
Footnotes
createGitHubTaskIntegration
andcreateJiraTaskIntegration
are currently combined intocreateTaskIntegration
in Make createJiraTaskIntegration/createGitHubTaskIntegration generic #5819 ↩ ↩2 ↩3The text was updated successfully, but these errors were encountered: