tasks

package
v0.15.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 31, 2023 License: Apache-2.0, MIT Imports: 23 Imported by: 4

Documentation

Index

Constants

View Source
const RAW_ACCOUNT_ORG_TABLE = "github_api_account_orgs"
View Source
const RAW_ACCOUNT_TABLE = "github_api_accounts"
View Source
const RAW_COMMENTS_TABLE = "github_api_comments"
View Source
const RAW_COMMIT_STATS_TABLE = "github_api_commit_stats"
View Source
const RAW_COMMIT_TABLE = "github_api_commits"
View Source
const RAW_EVENTS_TABLE = "github_api_events"
View Source
const RAW_ISSUE_TABLE = "github_api_issues"
View Source
const RAW_JOB_TABLE = "github_api_jobs"
View Source
const RAW_MILESTONE_TABLE = "github_milestones"
View Source
const RAW_PR_COMMIT_TABLE = "github_api_pull_request_commits"
View Source
const RAW_PR_REVIEW_COMMENTS_TABLE = "github_api_pull_request_review_comments"
View Source
const RAW_PR_REVIEW_TABLE = "github_api_pull_request_reviews"
View Source
const RAW_PULL_REQUEST_TABLE = "github_api_pull_requests"
View Source
const RAW_REPOSITORIES_TABLE = "github_api_repositories"
View Source
const RAW_RUN_TABLE = "github_api_runs"

Variables

View Source
var CollectAccountOrgMeta = core.SubTaskMeta{
	Name:             "collectAccountOrg",
	EntryPoint:       CollectAccountOrg,
	EnabledByDefault: true,
	Description:      "Collect accounts org data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var CollectAccountsMeta = core.SubTaskMeta{
	Name:             "collectAccounts",
	EntryPoint:       CollectAccounts,
	EnabledByDefault: true,
	Description:      "Collect accounts data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var CollectApiCommentsMeta = core.SubTaskMeta{
	Name:             "collectApiComments",
	EntryPoint:       CollectApiComments,
	EnabledByDefault: true,
	Description:      "Collect comments data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE_REVIEW, core.DOMAIN_TYPE_TICKET},
}
View Source
var CollectApiCommitStatsMeta = core.SubTaskMeta{
	Name:             "collectApiCommitStats",
	EntryPoint:       CollectApiCommitStats,
	EnabledByDefault: false,
	Description:      "Collect commitStats data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE},
}
View Source
var CollectApiCommitsMeta = core.SubTaskMeta{
	Name:             "collectApiCommits",
	EntryPoint:       CollectApiCommits,
	EnabledByDefault: false,
	Description:      "Collect commits data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE},
}
View Source
var CollectApiEventsMeta = core.SubTaskMeta{
	Name:             "collectApiEvents",
	EntryPoint:       CollectApiEvents,
	EnabledByDefault: true,
	Description:      "Collect Events data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var CollectApiIssuesMeta = core.SubTaskMeta{
	Name:             "collectApiIssues",
	EntryPoint:       CollectApiIssues,
	EnabledByDefault: true,
	Description:      "Collect issues data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var CollectApiPrReviewCommentsMeta = core.SubTaskMeta{
	Name:             "collectApiPrReviewCommentsMeta",
	EntryPoint:       CollectPrReviewComments,
	EnabledByDefault: true,
	Description:      "Collect pr review comments data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var CollectApiPullRequestCommitsMeta = core.SubTaskMeta{
	Name:             "collectApiPullRequestCommits",
	EntryPoint:       CollectApiPullRequestCommits,
	EnabledByDefault: true,
	Description:      "Collect PullRequestCommits data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var CollectApiPullRequestReviewsMeta = core.SubTaskMeta{
	Name:             "collectApiPullRequestReviews",
	EntryPoint:       CollectApiPullRequestReviews,
	EnabledByDefault: true,
	Description:      "Collect PullRequestReviews data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var CollectApiPullRequestsMeta = core.SubTaskMeta{
	Name:             "collectApiPullRequests",
	EntryPoint:       CollectApiPullRequests,
	EnabledByDefault: true,
	Description:      "Collect PullRequests data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var CollectJobsMeta = core.SubTaskMeta{
	Name:             "collectJobs",
	EntryPoint:       CollectJobs,
	EnabledByDefault: true,
	Description:      "Collect Jobs data from Github action api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}
View Source
var CollectMilestonesMeta = core.SubTaskMeta{
	Name:             "collectApiMilestones",
	EntryPoint:       CollectApiMilestones,
	EnabledByDefault: true,
	Description:      "Collect milestone data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var CollectRunsMeta = core.SubTaskMeta{
	Name:             "collectRuns",
	EntryPoint:       CollectRuns,
	EnabledByDefault: true,
	Description:      "Collect Runs data from Github action api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}
View Source
var ConvertAccountsMeta = core.SubTaskMeta{
	Name:             "convertAccounts",
	EntryPoint:       ConvertAccounts,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_accounts into  domain layer table accounts",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var ConvertCommitsMeta = core.SubTaskMeta{
	Name:             "convertCommits",
	EntryPoint:       ConvertCommits,
	EnabledByDefault: false,
	Description:      "Convert tool layer table github_commits into  domain layer table commits",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE},
}
View Source
var ConvertIssueCommentsMeta = core.SubTaskMeta{
	Name:             "convertIssueComments",
	EntryPoint:       ConvertIssueComments,
	EnabledByDefault: true,
	Description:      "ConvertIssueComments data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ConvertIssueLabelsMeta = core.SubTaskMeta{
	Name:             "convertIssueLabels",
	EntryPoint:       ConvertIssueLabels,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_issue_labels into  domain layer table issue_labels",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ConvertIssuesMeta = core.SubTaskMeta{
	Name:             "convertIssues",
	EntryPoint:       ConvertIssues,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_issues into  domain layer table issues",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ConvertJobsMeta = core.SubTaskMeta{
	Name:             "convertJobs",
	EntryPoint:       ConvertJobs,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_jobs into  domain layer table cicd_tasks",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}
View Source
var ConvertMilestonesMeta = core.SubTaskMeta{
	Name:             "convertMilestones",
	EntryPoint:       ConvertMilestones,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_milestones into  domain layer table milestones",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ConvertPullRequestCommentsMeta = core.SubTaskMeta{
	Name:             "convertPullRequestComments",
	EntryPoint:       ConvertPullRequestComments,
	EnabledByDefault: true,
	Description:      "ConvertPullRequestComments data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ConvertPullRequestCommitsMeta = core.SubTaskMeta{
	Name:             "convertPullRequestCommits",
	EntryPoint:       ConvertPullRequestCommits,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_pull_request_commits into  domain layer table pull_request_commits",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ConvertPullRequestIssuesMeta = core.SubTaskMeta{
	Name:             "convertPullRequestIssues",
	EntryPoint:       ConvertPullRequestIssues,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_pull_request_issues into  domain layer table pull_request_issues",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var ConvertPullRequestLabelsMeta = core.SubTaskMeta{
	Name:             "convertPullRequestLabels",
	EntryPoint:       ConvertPullRequestLabels,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_pull_request_labels into  domain layer table pull_request_labels",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ConvertPullRequestReviewsMeta = core.SubTaskMeta{
	Name:             "convertPullRequestReviews",
	EntryPoint:       ConvertPullRequestReviews,
	EnabledByDefault: true,
	Description:      "ConvertPullRequestReviews data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ConvertPullRequestsMeta = core.SubTaskMeta{
	Name:             "convertPullRequests",
	EntryPoint:       ConvertPullRequests,
	EnabledByDefault: true,
	Description:      "ConvertPullRequests data from Github api",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ConvertRepoMeta = core.SubTaskMeta{
	Name:             "convertRepo",
	EntryPoint:       ConvertRepo,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_repos into  domain layer table repos and boards",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE, core.DOMAIN_TYPE_TICKET, core.DOMAIN_TYPE_CICD, core.DOMAIN_TYPE_CODE_REVIEW, core.DOMAIN_TYPE_CROSS},
}
View Source
var ConvertRunsMeta = core.SubTaskMeta{
	Name:             "convertRuns",
	EntryPoint:       ConvertRuns,
	EnabledByDefault: true,
	Description:      "Convert tool layer table github_runs into  domain layer table cicd_pipeline",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}
View Source
var EnrichPullRequestIssuesMeta = core.SubTaskMeta{
	Name:             "enrichPullRequestIssues",
	EntryPoint:       EnrichPullRequestIssues,
	EnabledByDefault: true,
	Description:      "Create tool layer table github_pull_request_issues from github_pull_reqeusts",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var ExtractAccountOrgMeta = core.SubTaskMeta{
	Name:             "ExtractAccountOrg",
	EntryPoint:       ExtractAccountOrg,
	EnabledByDefault: true,
	Description:      "Extract raw account org data into tool layer table github_account_orgs",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var ExtractAccountsMeta = core.SubTaskMeta{
	Name:             "extractAccounts",
	EntryPoint:       ExtractAccounts,
	EnabledByDefault: true,
	Description:      "Extract raw account data  into tool layer table github_accounts",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS},
}
View Source
var ExtractApiCommentsMeta = core.SubTaskMeta{
	Name:             "extractApiComments",
	EntryPoint:       ExtractApiComments,
	EnabledByDefault: true,
	Description: "Extract raw comment data  into tool layer table github_pull_request_comments" +
		"and github_issue_comments",
	DomainTypes: []string{core.DOMAIN_TYPE_CODE_REVIEW, core.DOMAIN_TYPE_TICKET},
}
View Source
var ExtractApiCommitStatsMeta = core.SubTaskMeta{
	Name:             "extractApiCommitStats",
	EntryPoint:       ExtractApiCommitStats,
	EnabledByDefault: false,
	Description:      "Extract raw commit stats data into tool layer table github_commit_stats",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE},
}
View Source
var ExtractApiCommitsMeta = core.SubTaskMeta{
	Name:             "extractApiCommits",
	EntryPoint:       ExtractApiCommits,
	EnabledByDefault: false,
	Description:      "Extract raw commit data into tool layer table github_commits",
	DomainTypes:      []string{core.DOMAIN_TYPE_CODE},
}
View Source
var ExtractApiEventsMeta = core.SubTaskMeta{
	Name:             "extractApiEvents",
	EntryPoint:       ExtractApiEvents,
	EnabledByDefault: true,
	Description:      "Extract raw Events data into tool layer table github_issue_events",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ExtractApiIssuesMeta = core.SubTaskMeta{
	Name:             "extractApiIssues",
	EntryPoint:       ExtractApiIssues,
	EnabledByDefault: true,
	Description:      "Extract raw Issues data into tool layer table github_issues",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ExtractApiPrReviewCommentsMeta = core.SubTaskMeta{
	Name:             "extractApiPrReviewComments",
	EntryPoint:       ExtractApiPrReviewComments,
	EnabledByDefault: true,
	Description: "Extract raw comment data  into tool layer table github_pull_request_comments" +
		"and github_issue_comments",
	DomainTypes: []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ExtractApiPullRequestCommitsMeta = core.SubTaskMeta{
	Name:             "extractApiPullRequestCommits",
	EntryPoint:       ExtractApiPullRequestCommits,
	EnabledByDefault: true,
	Description:      "Extract raw PullRequestCommits data into tool layer table github_commits",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ExtractApiPullRequestReviewsMeta = core.SubTaskMeta{
	Name:             "extractApiPullRequestReviews",
	EntryPoint:       ExtractApiPullRequestReviews,
	EnabledByDefault: true,
	Description:      "Extract raw PullRequestReviewers data into tool layer table github_reviewers",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ExtractApiPullRequestsMeta = core.SubTaskMeta{
	Name:             "extractApiPullRequests",
	EntryPoint:       ExtractApiPullRequests,
	EnabledByDefault: true,
	Description:      "Extract raw PullRequests data into tool layer table github_pull_requests",
	DomainTypes:      []string{core.DOMAIN_TYPE_CROSS, core.DOMAIN_TYPE_CODE_REVIEW},
}
View Source
var ExtractJobsMeta = core.SubTaskMeta{
	Name:             "extractJobs",
	EntryPoint:       ExtractJobs,
	EnabledByDefault: true,
	Description:      "Extract raw run data into tool layer table github_jobs",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}
View Source
var ExtractMilestonesMeta = core.SubTaskMeta{
	Name:             "extractMilestones",
	EntryPoint:       ExtractMilestones,
	EnabledByDefault: true,
	Description:      "Extract raw milestone data into tool layer table github_milestones",
	DomainTypes:      []string{core.DOMAIN_TYPE_TICKET},
}
View Source
var ExtractRunsMeta = core.SubTaskMeta{
	Name:             "extractRuns",
	EntryPoint:       ExtractRuns,
	EnabledByDefault: true,
	Description:      "Extract raw run data into tool layer table github_runs",
	DomainTypes:      []string{core.DOMAIN_TYPE_CICD},
}

Functions

func CollectAccountOrg added in v0.12.0

func CollectAccountOrg(taskCtx core.SubTaskContext) errors.Error

func CollectAccounts added in v0.12.0

func CollectAccounts(taskCtx core.SubTaskContext) errors.Error

func CollectApiComments

func CollectApiComments(taskCtx core.SubTaskContext) errors.Error

func CollectApiCommitStats

func CollectApiCommitStats(taskCtx core.SubTaskContext) errors.Error

func CollectApiCommits

func CollectApiCommits(taskCtx core.SubTaskContext) errors.Error

func CollectApiEvents

func CollectApiEvents(taskCtx core.SubTaskContext) errors.Error

func CollectApiIssues

func CollectApiIssues(taskCtx core.SubTaskContext) errors.Error

func CollectApiMilestones added in v0.12.0

func CollectApiMilestones(taskCtx core.SubTaskContext) errors.Error

func CollectApiPullRequestCommits

func CollectApiPullRequestCommits(taskCtx core.SubTaskContext) errors.Error

func CollectApiPullRequestReviews

func CollectApiPullRequestReviews(taskCtx core.SubTaskContext) errors.Error

func CollectApiPullRequests

func CollectApiPullRequests(taskCtx core.SubTaskContext) errors.Error

func CollectJobs added in v0.13.0

func CollectJobs(taskCtx core.SubTaskContext) errors.Error

func CollectPrReviewComments added in v0.12.0

func CollectPrReviewComments(taskCtx core.SubTaskContext) errors.Error

func CollectRuns added in v0.13.0

func CollectRuns(taskCtx core.SubTaskContext) errors.Error

func ConvertAccounts added in v0.12.0

func ConvertAccounts(taskCtx core.SubTaskContext) errors.Error

func ConvertCommits

func ConvertCommits(taskCtx core.SubTaskContext) errors.Error

func ConvertIssueComments

func ConvertIssueComments(taskCtx core.SubTaskContext) errors.Error

func ConvertIssueLabels

func ConvertIssueLabels(taskCtx core.SubTaskContext) errors.Error

func ConvertIssues

func ConvertIssues(taskCtx core.SubTaskContext) errors.Error

func ConvertJobs added in v0.15.0

func ConvertJobs(taskCtx core.SubTaskContext) (err errors.Error)

func ConvertMilestones added in v0.12.0

func ConvertMilestones(taskCtx core.SubTaskContext) errors.Error

func ConvertPullRequestComments

func ConvertPullRequestComments(taskCtx core.SubTaskContext) errors.Error

func ConvertPullRequestCommits

func ConvertPullRequestCommits(taskCtx core.SubTaskContext) (err errors.Error)

func ConvertPullRequestIssues

func ConvertPullRequestIssues(taskCtx core.SubTaskContext) errors.Error

func ConvertPullRequestLabels

func ConvertPullRequestLabels(taskCtx core.SubTaskContext) errors.Error

func ConvertPullRequestReviews added in v0.12.0

func ConvertPullRequestReviews(taskCtx core.SubTaskContext) errors.Error

func ConvertPullRequests

func ConvertPullRequests(taskCtx core.SubTaskContext) errors.Error

func ConvertRepo

func ConvertRepo(taskCtx core.SubTaskContext) errors.Error

func ConvertRuns added in v0.15.0

func ConvertRuns(taskCtx core.SubTaskContext) errors.Error

func CreateApiClient

func CreateApiClient(taskCtx core.TaskContext, connection *models.GithubConnection) (*helper.ApiAsyncClient, errors.Error)

func EncodeTaskOptions added in v0.15.0

func EncodeTaskOptions(op *GithubOptions) (map[string]interface{}, errors.Error)

func EnrichPullRequestIssues

func EnrichPullRequestIssues(taskCtx core.SubTaskContext) (err errors.Error)

func ExtractAccountOrg added in v0.12.0

func ExtractAccountOrg(taskCtx core.SubTaskContext) errors.Error

func ExtractAccounts added in v0.12.0

func ExtractAccounts(taskCtx core.SubTaskContext) errors.Error

func ExtractApiComments

func ExtractApiComments(taskCtx core.SubTaskContext) errors.Error

func ExtractApiCommitStats

func ExtractApiCommitStats(taskCtx core.SubTaskContext) errors.Error

func ExtractApiCommits

func ExtractApiCommits(taskCtx core.SubTaskContext) errors.Error

func ExtractApiEvents

func ExtractApiEvents(taskCtx core.SubTaskContext) errors.Error

func ExtractApiIssues

func ExtractApiIssues(taskCtx core.SubTaskContext) errors.Error

func ExtractApiPrReviewComments added in v0.12.0

func ExtractApiPrReviewComments(taskCtx core.SubTaskContext) errors.Error

func ExtractApiPullRequestCommits

func ExtractApiPullRequestCommits(taskCtx core.SubTaskContext) errors.Error

func ExtractApiPullRequestReviews

func ExtractApiPullRequestReviews(taskCtx core.SubTaskContext) errors.Error

func ExtractApiPullRequests

func ExtractApiPullRequests(taskCtx core.SubTaskContext) errors.Error

func ExtractJobs added in v0.13.0

func ExtractJobs(taskCtx core.SubTaskContext) errors.Error

func ExtractMilestones added in v0.12.0

func ExtractMilestones(taskCtx core.SubTaskContext) errors.Error

func ExtractRuns added in v0.13.0

func ExtractRuns(taskCtx core.SubTaskContext) errors.Error

func GetTotalPagesFromResponse

func GetTotalPagesFromResponse(res *http.Response, args *helper.ApiCollectorArgs) (int, errors.Error)

func ValidateTaskOptions added in v0.15.0

func ValidateTaskOptions(op *GithubOptions) errors.Error

Types

type ApiRepoResponse

type ApiRepoResponse GithubApiRepo

type ApiSingleCommitResponse

type ApiSingleCommitResponse struct {
	Sha   string
	Stats struct {
		Additions int
		Deletions int
	}
	Commit struct {
		Committer struct {
			Name  string
			Email string
			Date  helper.Iso8601Time
		}
	}
}

type Commit

type Commit struct {
	Author struct {
		Name  string
		Email string
		Date  helper.Iso8601Time
	}
	Committer struct {
		Name  string
		Email string
		Date  helper.Iso8601Time
	}
	Message string
}

type CommitsResponse

type CommitsResponse struct {
	Sha       string `json:"sha"`
	Commit    Commit
	Url       string
	Author    *models.GithubAccount
	Committer *models.GithubAccount
}

type DetailGithubAccountResponse added in v0.12.0

type DetailGithubAccountResponse struct {
	GithubAccountResponse
	Name            string    `json:"name"`
	Company         string    `json:"company"`
	Blog            string    `json:"blog"`
	Location        string    `json:"location"`
	Email           string    `json:"email"`
	Hireable        bool      `json:"hireable"`
	Bio             string    `json:"bio"`
	TwitterUsername string    `json:"twitter_username"`
	PublicRepos     int       `json:"public_repos"`
	PublicGists     int       `json:"public_gists"`
	Followers       int       `json:"followers"`
	Following       int       `json:"following"`
	CreatedAt       time.Time `json:"created_at"`
	UpdatedAt       time.Time `json:"updated_at"`
}

type GithubAccountOrgsResponse added in v0.12.0

type GithubAccountOrgsResponse struct {
	Login       string `json:"login"`
	Id          int    `json:"id"`
	NodeId      string `json:"node_id"`
	AvatarUrl   string `json:"avatar_url"`
	Description string `json:"description"`
}

type GithubAccountResponse added in v0.12.0

type GithubAccountResponse struct {
	Login             string `json:"login"`
	Id                int    `json:"id"`
	NodeId            string `json:"node_id"`
	AvatarUrl         string `json:"avatar_url"`
	GravatarId        string `json:"gravatar_id"`
	Url               string `json:"url"`
	HtmlUrl           string `json:"html_url"`
	FollowersUrl      string `json:"followers_url"`
	FollowingUrl      string `json:"following_url"`
	GistsUrl          string `json:"gists_url"`
	StarredUrl        string `json:"starred_url"`
	SubscriptionsUrl  string `json:"subscriptions_url"`
	OrganizationsUrl  string `json:"organizations_url"`
	ReposUrl          string `json:"repos_url"`
	EventsUrl         string `json:"events_url"`
	ReceivedEventsUrl string `json:"received_events_url"`
	Type              string `json:"type"`
	SiteAdmin         bool   `json:"site_admin"`
}

type GithubAccountWithOrg added in v0.12.0

type GithubAccountWithOrg struct {
	githubModels.GithubAccount
	Login string `json:"login" gorm:"type:varchar(255)"`
	common.NoPKModel
}

type GithubApiParams

type GithubApiParams struct {
	ConnectionId uint64
	Name         string
}

type GithubApiPullRequest

type GithubApiPullRequest struct {
	GithubId int             `json:"id"`
	Number   int             `json:"number"`
	State    string          `json:"state"`
	Title    string          `json:"title"`
	Body     json.RawMessage `json:"body"`
	HtmlUrl  string          `json:"html_url"`
	Labels   []struct {
		Name string `json:"name"`
	} `json:"labels"`
	Assignee        *GithubAccountResponse `json:"assignee"`
	User            *GithubAccountResponse `json:"user"`
	ClosedAt        *helper.Iso8601Time    `json:"closed_at"`
	MergedAt        *helper.Iso8601Time    `json:"merged_at"`
	GithubCreatedAt helper.Iso8601Time     `json:"created_at"`
	GithubUpdatedAt helper.Iso8601Time     `json:"updated_at"`
	MergeCommitSha  string                 `json:"merge_commit_sha"`
	Head            struct {
		Ref  string         `json:"ref"`
		Sha  string         `json:"sha"`
		Repo *GithubApiRepo `json:"repo"`
	} `json:"head"`
	Base struct {
		Ref  string         `json:"ref"`
		Sha  string         `json:"sha"`
		Repo *GithubApiRepo `json:"repo"`
	} `json:"base"`
}

type GithubApiRepo

type GithubApiRepo struct {
	Name        string `json:"name"`
	FullName    string `json:"full_name"`
	GithubId    int    `json:"id"`
	HTMLUrl     string `json:"html_url"`
	Language    string `json:"language"`
	Description string `json:"description"`
	Owner       *GithubAccountResponse
	Parent      *GithubApiRepo      `json:"parent"`
	CreatedAt   helper.Iso8601Time  `json:"created_at"`
	UpdatedAt   *helper.Iso8601Time `json:"updated_at"`
	CloneUrl    string              `json:"clone_url"`
}

type GithubOptions

type GithubOptions struct {
	ConnectionId                     uint64   `json:"connectionId" mapstructure:"connectionId,omitempty"`
	TransformationRuleId             uint64   `json:"transformationRuleId" mapstructure:"transformationRuleId,omitempty"`
	GithubId                         int      `json:"githubId" mapstructure:"githubId,omitempty"`
	Tasks                            []string `json:"tasks,omitempty" mapstructure:",omitempty"`
	CreatedDateAfter                 string   `json:"createdDateAfter" mapstructure:"createdDateAfter,omitempty"`
	Owner                            string   `json:"owner" mapstructure:"owner,omitempty"`
	Repo                             string   `json:"repo"  mapstructure:"repo,omitempty"`
	Name                             string   `json:"name"  mapstructure:"name,omitempty"`
	*models.GithubTransformationRule `mapstructure:"transformationRules,omitempty" json:"transformationRules"`
}

func DecodeAndValidateTaskOptions added in v0.12.0

func DecodeAndValidateTaskOptions(options map[string]interface{}) (*GithubOptions, errors.Error)

func DecodeTaskOptions added in v0.15.0

func DecodeTaskOptions(options map[string]interface{}) (*GithubOptions, errors.Error)

type GithubRawJobsResult added in v0.13.0

type GithubRawJobsResult struct {
	TotalCount         int64             `json:"total_count"`
	GithubWorkflowJobs []json.RawMessage `json:"jobs"`
}

type GithubRawRunsResult added in v0.13.0

type GithubRawRunsResult struct {
	TotalCount         int64             `json:"total_count"`
	GithubWorkflowRuns []json.RawMessage `json:"workflow_runs"`
}

type GithubTaskData

type GithubTaskData struct {
	Options          *GithubOptions
	ApiClient        *helper.ApiAsyncClient
	GraphqlClient    *helper.GraphqlAsyncClient
	CreatedDateAfter *time.Time
}

type IssueComment

type IssueComment struct {
	GithubId        int `json:"id"`
	Body            json.RawMessage
	User            *GithubAccountResponse
	IssueUrl        string             `json:"issue_url"`
	GithubCreatedAt helper.Iso8601Time `json:"created_at"`
	GithubUpdatedAt helper.Iso8601Time `json:"updated_at"`
}

type IssueEvent

type IssueEvent struct {
	GithubId int `json:"id"`
	Event    string
	Actor    *GithubAccountResponse
	Issue    struct {
		Id int
	}
	GithubCreatedAt helper.Iso8601Time `json:"created_at"`
}

type IssueRegexes added in v0.12.0

type IssueRegexes struct {
	SeverityRegex        *regexp.Regexp
	ComponentRegex       *regexp.Regexp
	PriorityRegex        *regexp.Regexp
	TypeBugRegex         *regexp.Regexp
	TypeRequirementRegex *regexp.Regexp
	TypeIncidentRegex    *regexp.Regexp
}

func NewIssueRegexes added in v0.12.0

func NewIssueRegexes(config *models.GithubTransformationRule) (*IssueRegexes, errors.Error)

type IssuesResponse

type IssuesResponse struct {
	GithubId    int `json:"id"`
	Number      int
	State       string
	Title       string
	Body        json.RawMessage
	HtmlUrl     string `json:"html_url"`
	PullRequest struct {
		Url     string `json:"url"`
		HtmlUrl string `json:"html_url"`
	} `json:"pull_request"`
	Labels []struct {
		Name string `json:"name"`
	} `json:"labels"`
	Assignee  *GithubAccountResponse
	User      *GithubAccountResponse
	Milestone *struct {
		Id int
	}
	ClosedAt        *helper.Iso8601Time `json:"closed_at"`
	GithubCreatedAt helper.Iso8601Time  `json:"created_at"`
	GithubUpdatedAt helper.Iso8601Time  `json:"updated_at"`
}

type MilestoneConverterModel added in v0.12.0

type MilestoneConverterModel struct {
	common.RawDataOrigin
	githubModels.GithubMilestone
	GithubId int
}

type MilestonesResponse added in v0.12.0

type MilestonesResponse struct {
	Url         string `json:"url"`
	HtmlUrl     string `json:"html_url"`
	LabelsUrl   string `json:"labels_url"`
	Id          int    `json:"id"`
	NodeId      string `json:"node_id"`
	Number      int    `json:"number"`
	Title       string `json:"title"`
	Description string `json:"description"`
	Creator     struct {
		Login             string `json:"login"`
		Id                int    `json:"id"`
		NodeId            string `json:"node_id"`
		AvatarUrl         string `json:"avatar_url"`
		GravatarId        string `json:"gravatar_id"`
		Url               string `json:"url"`
		HtmlUrl           string `json:"html_url"`
		FollowersUrl      string `json:"followers_url"`
		FollowingUrl      string `json:"following_url"`
		GistsUrl          string `json:"gists_url"`
		StarredUrl        string `json:"starred_url"`
		SubscriptionsUrl  string `json:"subscriptions_url"`
		OrganizationsUrl  string `json:"organizations_url"`
		ReposUrl          string `json:"repos_url"`
		EventsUrl         string `json:"events_url"`
		ReceivedEventsUrl string `json:"received_events_url"`
		Type              string `json:"type"`
		SiteAdmin         bool   `json:"site_admin"`
	} `json:"creator"`
	OpenIssues   int                 `json:"open_issues"`
	ClosedIssues int                 `json:"closed_issues"`
	State        string              `json:"state"`
	CreatedAt    helper.Iso8601Time  `json:"created_at"`
	UpdatedAt    helper.Iso8601Time  `json:"updated_at"`
	DueOn        *helper.Iso8601Time `json:"due_on"`
	ClosedAt     *helper.Iso8601Time `json:"closed_at"`
}

type PrCommitsResponse

type PrCommitsResponse struct {
	Sha    string `json:"sha"`
	Commit PullRequestCommit
	Url    string
}

type PullRequestCommit

type PullRequestCommit struct {
	Author struct {
		Id    int
		Name  string
		Email string
		Date  helper.Iso8601Time
	}
	Committer struct {
		Name  string
		Email string
		Date  helper.Iso8601Time
	}
	Message json.RawMessage
}

type PullRequestReview

type PullRequestReview struct {
	GithubId    int `json:"id"`
	User        *GithubAccountResponse
	Body        string
	State       string
	CommitId    string             `json:"commit_id"`
	SubmittedAt helper.Iso8601Time `json:"submitted_at"`
}

type SimpleAccount added in v0.12.0

type SimpleAccount struct {
	Login string
}

type SimpleAccountWithId added in v0.12.0

type SimpleAccountWithId struct {
	Login     string
	AccountId int
}

type SimpleBranch added in v0.13.0

type SimpleBranch struct {
	HeadBranch string `json:"head_branch" gorm:"type:varchar(255)"`
}

type SimpleGithubRun added in v0.13.0

type SimpleGithubRun struct {
	ID int64
}

type SimplePr

type SimplePr struct {
	Number   int
	GithubId int
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL