milvus/reader/result.go
bigsheeper 6d777b7518 Init reader component
Signed-off-by: bigsheeper <yihao.dai@zilliz.com>
2020-08-25 15:38:35 +08:00

29 lines
694 B
Go

package reader
import (
"../pulsar/schema"
"fmt"
)
type ResultEntityIds []int64
func getResultTopicByClientId(clientId int64) string {
// TODO: Result topic?
return "result-topic/partition-" + string(clientId)
}
func publishResult(ids *ResultEntityIds, clientId int64) schema.Status {
// TODO: Pulsar publish
var resultTopic = getResultTopicByClientId(clientId)
fmt.Println(resultTopic)
return schema.Status{Error_code: schema.ErrorCode_SUCCESS}
}
func publicStatistic(statisticTopic string) schema.Status {
// TODO: get statistic info
// getStatisticInfo()
// var info = getStatisticInfo()
// TODO: Pulsar publish
return schema.Status{Error_code: schema.ErrorCode_SUCCESS}
}