Documentation ¶
Index ¶
- Constants
- Variables
- func CollectAccounts(taskCtx plugin.SubTaskContext) errors.Error
- func CollectAdditionalFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
- func CollectFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
- func CollectHotspots(taskCtx plugin.SubTaskContext) errors.Error
- func CollectIssues(taskCtx plugin.SubTaskContext) (err errors.Error)
- func ConvertAccounts(taskCtx plugin.SubTaskContext) errors.Error
- func ConvertFileMetrics(taskCtx plugin.SubTaskContext) errors.Error
- func ConvertHotspots(taskCtx plugin.SubTaskContext) errors.Error
- func ConvertIssueCodeBlocks(taskCtx plugin.SubTaskContext) errors.Error
- func ConvertIssues(taskCtx plugin.SubTaskContext) errors.Error
- func ConvertProjects(taskCtx plugin.SubTaskContext) errors.Error
- func CreateApiClient(taskCtx plugin.TaskContext, connection *models.SonarqubeConnection) (*api.ApiAsyncClient, errors.Error)
- func ExtractAccounts(taskCtx plugin.SubTaskContext) errors.Error
- func ExtractAdditionalFileMetrics(taskCtx plugin.SubTaskContext) errors.Error
- func ExtractFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
- func ExtractHotspots(taskCtx plugin.SubTaskContext) errors.Error
- func ExtractIssues(taskCtx plugin.SubTaskContext) errors.Error
- func GetFormatTime(t *time.Time) string
- func GetTotalPagesFromResponse(res *http.Response, args *api.ApiCollectorArgs) (int, errors.Error)
- type IssuesResponse
- type Location
- type Measure
- type Paging
- type SonarqubeIssueTimeIteratorNode
- type SonarqubeOptions
- type SonarqubePagination
- type SonarqubeTaskData
- type TextRange
Constants ¶
View Source
const RAW_ACCOUNTS_TABLE = "sonarqube_api_accounts"
View Source
const RAW_FILEMETRICS_ADDITIONAL_TABLE = "sonarqube_api_filemetrics_additional"
View Source
const RAW_FILEMETRICS_TABLE = "sonarqube_api_filemetrics"
View Source
const RAW_HOTSPOTS_TABLE = "sonarqube_api_hotspots"
View Source
const RAW_ISSUES_TABLE = "sonarqube_api_issues"
View Source
const RAW_PROJECTS_TABLE = "sonarqube_api_projects"
Variables ¶
View Source
var CollectAccountsMeta = plugin.SubTaskMeta{ Name: "CollectAccounts", EntryPoint: CollectAccounts, EnabledByDefault: true, Description: "Collect Accounts data from Sonarqube user api", DomainTypes: []string{plugin.DOMAIN_TYPE_CROSS}, }
View Source
var CollectAdditionalFilemetricsMeta = plugin.SubTaskMeta{ Name: "CollectAdditionalFilemetrics", EntryPoint: CollectAdditionalFilemetrics, EnabledByDefault: true, Description: "Collect Filemetrics data from Sonarqube api", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var CollectFilemetricsMeta = plugin.SubTaskMeta{ Name: "CollectFilemetrics", EntryPoint: CollectFilemetrics, EnabledByDefault: true, Description: "Collect Filemetrics data from Sonarqube api", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var CollectHotspotsMeta = plugin.SubTaskMeta{ Name: "CollectHotspots", EntryPoint: CollectHotspots, EnabledByDefault: true, Description: "Collect Hotspots data from Sonarqube api", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var CollectIssuesMeta = plugin.SubTaskMeta{ Name: "CollectIssues", EntryPoint: CollectIssues, EnabledByDefault: true, Description: "Collect issues data from Sonarqube api", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ConvertAccountsMeta = plugin.SubTaskMeta{ Name: "convertAccounts", EntryPoint: ConvertAccounts, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_accounts into domain layer table accounts", DomainTypes: []string{plugin.DOMAIN_TYPE_CROSS}, }
View Source
var ConvertFileMetricsMeta = plugin.SubTaskMeta{ Name: "convertFileMetrics", EntryPoint: ConvertFileMetrics, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_file_metrics into domain layer table cq_file_metrics", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ConvertHotspotsMeta = plugin.SubTaskMeta{ Name: "convertHotspots", EntryPoint: ConvertHotspots, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_hotspots into domain layer table cq_hotspots", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ConvertIssueCodeBlocksMeta = plugin.SubTaskMeta{ Name: "convertIssueCodeBlocks", EntryPoint: ConvertIssueCodeBlocks, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_issues into domain layer table cq_issue_code_blocks", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ConvertIssuesMeta = plugin.SubTaskMeta{ Name: "convertIssues", EntryPoint: ConvertIssues, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_issues into domain layer table cq_issues", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ConvertProjectsMeta = plugin.SubTaskMeta{ Name: "convertProjects", EntryPoint: ConvertProjects, EnabledByDefault: true, Description: "Convert tool layer table sonarqube_projects into domain layer table projects", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ExtractAccountsMeta = plugin.SubTaskMeta{ Name: "ExtractAccounts", EntryPoint: ExtractAccounts, EnabledByDefault: true, Description: "Extract raw data into tool layer table sonarqube_accounts", DomainTypes: []string{plugin.DOMAIN_TYPE_CROSS}, }
View Source
var ExtractAdditionalFileMetricsMeta = plugin.SubTaskMeta{ Name: "ExtractAdditionalFileMetrics", EntryPoint: ExtractAdditionalFileMetrics, EnabledByDefault: true, Description: "Extract raw data into tool layer table sonarqube_api_filemetrics", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ExtractFilemetricsMeta = plugin.SubTaskMeta{ Name: "ExtractFilemetrics", EntryPoint: ExtractFilemetrics, EnabledByDefault: true, Description: "Extract raw data into tool layer table sonarqube_filemetrics", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ExtractHotspotsMeta = plugin.SubTaskMeta{ Name: "ExtractHotspots", EntryPoint: ExtractHotspots, EnabledByDefault: true, Description: "Extract raw data into tool layer table sonarqube_hotspots", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
View Source
var ExtractIssuesMeta = plugin.SubTaskMeta{ Name: "ExtractIssues", EntryPoint: ExtractIssues, EnabledByDefault: true, Description: "Extract raw data into tool layer table sonarqube_issues", DomainTypes: []string{plugin.DOMAIN_TYPE_CODE_QUALITY}, }
Functions ¶
func CollectAccounts ¶
func CollectAccounts(taskCtx plugin.SubTaskContext) errors.Error
func CollectAdditionalFilemetrics ¶
func CollectAdditionalFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
func CollectFilemetrics ¶
func CollectFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
func CollectHotspots ¶
func CollectHotspots(taskCtx plugin.SubTaskContext) errors.Error
func CollectIssues ¶
func CollectIssues(taskCtx plugin.SubTaskContext) (err errors.Error)
func ConvertAccounts ¶
func ConvertAccounts(taskCtx plugin.SubTaskContext) errors.Error
func ConvertFileMetrics ¶
func ConvertFileMetrics(taskCtx plugin.SubTaskContext) errors.Error
func ConvertHotspots ¶
func ConvertHotspots(taskCtx plugin.SubTaskContext) errors.Error
func ConvertIssueCodeBlocks ¶
func ConvertIssueCodeBlocks(taskCtx plugin.SubTaskContext) errors.Error
func ConvertIssues ¶
func ConvertIssues(taskCtx plugin.SubTaskContext) errors.Error
func ConvertProjects ¶
func ConvertProjects(taskCtx plugin.SubTaskContext) errors.Error
func CreateApiClient ¶
func CreateApiClient(taskCtx plugin.TaskContext, connection *models.SonarqubeConnection) (*api.ApiAsyncClient, errors.Error)
CreateApiClient creates a new asynchronize API Client for AE
func ExtractAccounts ¶
func ExtractAccounts(taskCtx plugin.SubTaskContext) errors.Error
func ExtractAdditionalFileMetrics ¶
func ExtractAdditionalFileMetrics(taskCtx plugin.SubTaskContext) errors.Error
func ExtractFilemetrics ¶
func ExtractFilemetrics(taskCtx plugin.SubTaskContext) errors.Error
func ExtractHotspots ¶
func ExtractHotspots(taskCtx plugin.SubTaskContext) errors.Error
func ExtractIssues ¶
func ExtractIssues(taskCtx plugin.SubTaskContext) errors.Error
func GetFormatTime ¶
Types ¶
type IssuesResponse ¶
type IssuesResponse struct { Key string `json:"key"` Rule string `json:"rule"` Severity string `json:"severity"` Component string `json:"component"` Project string `json:"project"` Line int `json:"line"` Hash string `json:"hash"` TextRange struct { StartLine int `json:"startLine"` EndLine int `json:"endLine"` StartOffset int `json:"startOffset"` EndOffset int `json:"endOffset"` } `json:"textRange"` Flows []flow `json:"flows"` Status string `json:"status"` Message string `json:"message"` Effort string `json:"effort"` Debt string `json:"debt"` Author string `json:"author"` Tags []string `json:"tags"` CreationDate *utils.Iso8601Time `json:"creationDate"` UpdateDate *utils.Iso8601Time `json:"updateDate"` Type string `json:"type"` Scope string `json:"scope"` QuickFixAvailable bool `json:"quickFixAvailable"` }
type SonarqubeOptions ¶
type SonarqubeOptions struct { // options means some custom params required by plugin running. // Such As How many rows do your want // You can use it in subtasks, and you need to pass it to main.go and pipelines. ConnectionId uint64 `json:"connectionId"` ProjectKey string `json:"projectKey"` Tasks []string `json:"tasks,omitempty"` }
func DecodeAndValidateTaskOptions ¶
func DecodeAndValidateTaskOptions(options map[string]interface{}) (*SonarqubeOptions, errors.Error)
type SonarqubePagination ¶
type SonarqubePagination struct {
Paging Paging `json:"paging"`
}
type SonarqubeTaskData ¶
type SonarqubeTaskData struct { Options *SonarqubeOptions ApiClient *api.ApiAsyncClient LastAnalysisDate *time.Time TaskStartTime time.Time }
func CreateRawDataSubTaskArgs ¶
func CreateRawDataSubTaskArgs(taskCtx plugin.SubTaskContext, rawTable string) (*api.RawDataSubTaskArgs, *SonarqubeTaskData)
Source Files ¶
- account_convertor.go
- accounts_collector.go
- accounts_extractor.go
- api_client.go
- filemetrics_additional_collector.go
- filemetrics_additional_extractor.go
- filemetrics_collector.go
- filemetrics_convertor.go
- filemetrics_extractor.go
- hotspots_collector.go
- hotspots_convertor.go
- hotspots_extractor.go
- issue_code_blocks_convertor.go
- issues_collector.go
- issues_convertor.go
- issues_extractor.go
- projects_convertor.go
- shared.go
- task_data.go
Click to show internal directories.
Click to hide internal directories.