Open ashcrow opened 4 years ago
The main reason I was using interface{}
is that the data type might be subject to changes since the client data collection code has not been finalized. So I thought it might be better to accept generic types and change to specific types later.
I see. Is there a plan to specify the format of incoming data? I'd hate for someone to shove large amounts of dummy data in to overwhelm the backend.
Totally understand the concern, I will adjust the types as soon as the client code is ready. Is that okay..
I believe so. I'd avoid running it in production until then though (just in case :-))
interface{}
is used instead of specific types. Ex: https://github.com/zonggen/fcos-pinger-backend/blob/master/main.go#L40 Is this because the data reported isn't known or is it more so a MondoDB driver requirement?