I have copied the problematic lines of your code into a tiny programme on 
the Go playground.
https://play.golang.org/p/9vMrdtC-2zX

If you run it you will see the problem.

I would play around with the code to get a feel for what is happening.

If you want to append job names, then you probably want to use a slice 
rather than a map.

And to get the lifetime of this slice right, it should be created outside 
the loop which processes each new request.

Like I said, play around with the small example, until you understand what 
is happening and you can get the code to do the right thing.
Then you can update your original program.

Good luck!

On Friday, 3 January 2020 09:02:26 UTC, MUNGAI wrote:
>
> Hi, as indicated above, all is a local variable to you function. Maybe you 
> meant to have all variable on a global scope and as a map of maps.
>
> Regards
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/a9faf0f9-26c8-414c-a4f3-012da8b3a742%40googlegroups.com.

Reply via email to