This repository was archived by the owner on Sep 28, 2022. It is now read-only.

Description
When providing a gopilosa.ImportStatusUpdate to pdk.SetupPilosa() via:
statusChan := make(chan gopilosa.ImportStatusUpdate, 1000)
indexer, err := pdk.SetupPilosa(m.PilosaHosts, m.Index, frames,
gopilosa.OptImportStatusChannel(statusChan))
and when multiple frames are passed in to frames, then two problems occur:
- multiple frames share the same status channel
- upon import completion, all frames try to close the channel, which causes a panic
I'm still not sure if it's best to handle this in PDK or go-pilosa, but it seems we need a way to provide multiple channels (one per frame) for status updates. An alternative would be to modify go-pilosa such that the single status channel is aware of index/frame, and therefore supports multiple frames.
This needs more investigation.