跳到主要内容
版本:v2.5.x

GetImportProgress()

This operation gets the progress of the specified bulk-import job.

Go
func GetImportProgress(ctx context.Context, option *GetImportProgressOption) (*GetImportProgressResponse, error)

Request Parameters

Parameter

Description

Type

ctx

Context for the current call to work.

context.Context

option

Optional parameters of the methods.

GetImportProgressOption

callOpts

Optional parameters for calling the methods.

grpc.CallOption

GetImportProgressOption

This is a struct type. You can use NewGetImportProgressOption() to get its concrete implementation.

NewGetImportProgressOption

The signature of NewGetImportProgressOption() is as follows:

Go
func NewGetImportProgressOption(uri string, jobID string) *GetImportProgressOption

Parameter

Description

Type

uri

The URI of your Milvus instance.

string

jobID

The ID of the target data import job.

string

grpc.CallOption

This interface provided by the gRPC Go library allows you to specify additional options or configurations when making requests. For possible implementations of this interface, refer to this file.

GetImportProgressResponse

The GetImportProgressResponse struct type is as follows:

Go
type GetImportProgressResponse struct {
Status int `json:"status"`
Message string `json:"message"`
Data *ImportProgressData `json:"data"`
}

The struct type that appears in the GetImportProgressResponse struct type is as follows:

ImportProgressData

The ImportProgressData struct type is as follows:

Go
type ImportProgressData struct {
CollectionName string `json:"collectionName"`
JobID string `json:"jobId"`
CompleteTime string `json:"completeTime"`
State string `json:"state"`
Progress int64 `json:"progress"`
ImportedRows int64 `json:"importedRows"`
TotalRows int64 `json:"totalRows"`
Reason string `json:"reason"`
FileSize int64 `json:"fileSize"`
Details []*ImportProgressDetail `json:"details"`
}

The struct type that appears in the ImportProgressData struct type is as follows:

ImportProgressDetail

The ImportProgressDetail struct type is as follows:

Go
type ImportProgressDetail struct {
FileName string `json:"fileName"`
FileSize int64 `json:"fileSize"`
Progress int64 `json:"progress"`
CompleteTime string `json:"completeTime"`
State string `json:"state"`
ImportedRows int64 `json:"importedRows"`
TotalRows int64 `json:"totalRows"`
}

Return

*[GetImportProgressResponse](GetImportProgress.md#getimportprogressresponse)

Example