Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread Jan Mercl
On Wed, Jun 19, 2019 at 4:55 AM hui zhang  wrote:

> is there a goroutine scope global veriable ?   so  I can do this ?

Go has no global scope. The closest is universe scope but that scope
contains only predeclared identifiers. I think you are meaning package
scope.

Goroutines can access variables visible to them in any scope, but the
only ones that are private to the goroutine have block scope.

-- 
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/CAA40n-VtHTQanJGxiEa2xz0LU5xTLLSYVYm3bYtXma5M7VVa3Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread hui zhang
thanks ,  I also google blew links.
It is called goroutine local storage (gls)  and  many third party 
implement(https://github.com/jtolds/gls)
however,   the golang official suggest to use go context.
but, very few document mention , how to do it as goroutine local storage .  
Can anyone give an example to solve my problem , refer the code I attached?


在 2019年6月19日星期三 UTC+8上午11:03:59,Kurtis Rader写道:
>
> On Tue, Jun 18, 2019 at 7:56 PM hui zhang  > wrote:
>
>>
>> is there a goroutine scope global veriable ?   so  I can do this ?
>>
>
> You're asking if Go supports the equivalent of thread local storage as 
> used in Java, C++, and Python. The answer is, no. See 
> https://stackoverflow.com/questions/31932945/does-go-have-something-like-threadlocal-from-java
>  and https://github.com/golang/go/issues/21355 
> 
>
> -- 
> Kurtis Rader
> Caretaker of the exceptional canines Junior and Hank
>

-- 
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/a06da5ca-4967-4697-bfbe-e043a838844d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread Jan Mercl
On Wed, Jun 19, 2019 at 10:41 AM hui zhang  wrote:

> but, very few document mention , how to do it as goroutine local storage .  
> Can anyone give an example to solve my problem , refer the code I attached?

Make the goroutine a method of a struct that contains any context the
goroutine needs. The data in the struct becomes your goroutine-local
storage.

type gls struct { id int }

func newG(id int) {
g := &gls{id}
go g.run()
}

func (g *gls) run() { fmt.Println(g.id) }

-- 
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/CAA40n-XOTauyR9YEj2LSw-N39HiUbM0PeNrHxAroGPthWkNhjg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread hui zhang
thank you very much.  
Is there a  golang context way to do it?

在 2019年6月19日星期三 UTC+8下午4:55:09,Jan Mercl写道:
>
> On Wed, Jun 19, 2019 at 10:41 AM hui zhang  > wrote: 
>
> > but, very few document mention , how to do it as goroutine local storage 
> .  Can anyone give an example to solve my problem , refer the code I 
> attached? 
>
> Make the goroutine a method of a struct that contains any context the 
> goroutine needs. The data in the struct becomes your goroutine-local 
> storage. 
>
> type gls struct { id int } 
>
> func newG(id int) { 
> g := &gls{id} 
> go g.run() 
> } 
>
> func (g *gls) run() { fmt.Println(g.id) } 
>

-- 
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/62562359-5c78-4053-b2e4-1defe6ebdb8a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread Jan Mercl
On Wed, Jun 19, 2019 at 11:15 AM hui zhang  wrote:

> Is there a  golang context way to do it?

Some bits are at https://golang.org/pkg/context/#pkg-examples

-- 
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/CAA40n-WhnsBLqKX2YHrNNaX_zEA9MK90vH0onRh0%2BDCda_NfPQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread hui zhang
this implement does not solve the problem.
still need pass the parameter in all functions. 
func (g *gls) run()orfunc run (g *gls) 

在 2019年6月19日星期三 UTC+8下午4:55:09,Jan Mercl写道:
>
> On Wed, Jun 19, 2019 at 10:41 AM hui zhang  > wrote: 
>
> > but, very few document mention , how to do it as goroutine local storage 
> .  Can anyone give an example to solve my problem , refer the code I 
> attached? 
>
> Make the goroutine a method of a struct that contains any context the 
> goroutine needs. The data in the struct becomes your goroutine-local 
> storage. 
>
> type gls struct { id int } 
>
> func newG(id int) { 
> g := &gls{id} 
> go g.run() 
> } 
>
> func (g *gls) run() { fmt.Println(g.id) } 
>

-- 
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/35de6b92-8240-4892-bc2e-d5cda3980582%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[go-nuts] Re: Panic during proto Marshal

2019-06-19 Thread Agniva De Sarker
This happens when you are trying to access a nil pointer. Check from where 
the stack trace originates, go to that line and add a "!= nil" check. I 
guess that is what's happening.

P.S. Your stack trace is in a json format which is for machines to read, 
not humans. While reporting issues, it helps a lot you present your data 
(logs, stack trace, etc) in the most clearest way possible.



On Wednesday, 19 June 2019 11:32:09 UTC+5:30, Mayank Jha wrote:
>
> I am getting the *runtime error: invalid memory address or nil pointer 
> dereference, *with the following stack trace, but only occasionally when 
> I try to proto.Marshal() a proto message. 
>
> [{"file":"/go/src/github.com/carousell/Cats/Cats/analytics/analytics.go",
>> "line":92,"function":"(*producer).Produce.func1"},{"file":
>> "/usr/local/go/src/runtime/asm_amd64.s","line":573,"function":"call32"},{
>> "file":"/usr/local/go/src/runtime/panic.go","line":502,"function":
>> "gopanic"},{"file":"/usr/local/go/src/runtime/panic.go","line":63,
>> "function":"panicmem"},{"file":"/usr/local/go/src/runtime/signal_unix.go"
>> ,"line":388,"function":"sigpanic"},{"file":
>> "/usr/local/go/src/unicode/utf8/utf8.go","line":483,"function":
>> "ValidString"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":2074,"function":"appendUTF8StringValueNoZero"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":270,"function":"(*marshalInfo).marshal"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":2264,"function":"makeMessageSliceMarshaler.func2"},{"file":
>> "/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":270,"function":"(*marshalInfo).marshal"{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":2234,"function":"makeMessageMarshaler.func2"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":270,"function":"(*marshalInfo).marshal"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":141,"function":"(*InternalMessageInfo).Marshal"},{"file":
>> "/go/src/github.com/carousell/Cats/Cats/Cats_proto/analytics.pb.go",
>> "line":447,"function":"(*AdRequestMsg).XXX_Marshal"},{"file":"/go/src/
>> github.com/carousell/Cats/vendor/github.com/golang/protobuf/proto/table_marshal.go
>> ","line":2715,"function":"Marshal"}]
>>
>>
>  Have omitted the initial part of the stack trace. Can someone tell me 
> when all could this happen ? Could it be because of a difference in 
> protobuf library versions ? I am unable to get the message, as when the 
> panic happens when the serialization is taking place. Any ideas on how to 
> approach this kind of problem ?
>

-- 
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/eb43e86c-b595-4ae7-8a9b-a6645bc013e0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Possible memory leak in HTTPS connections

2019-06-19 Thread qihua . lin
I run into this problem now. How do you solve it?

On Friday, October 24, 2014 at 3:52:27 AM UTC+8, James Bardin wrote:
>
>
>
> On Thursday, October 23, 2014 3:23:48 PM UTC-4, Vincent Batts wrote:
>>
>> From my experience, it is due to the duplicate instances of 
>> http.Transport. By default keeps around idle connections for resuse, so it 
>> is not tagged for garbage collection once its immediately out of scope. The 
>> Work around is to set DisableKeepAlive to true.
>>
>
>  Not sure if you intended to respond to me or not, but the version I was 
> experimenting with was sing a single instance if Transport and Client and 
> set DisableKeepAlive to true.
>

-- 
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/2460a0ac-c62a-435c-9a1a-b509348e9326%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[go-nuts] Do I pass nil arguments method ?

2019-06-19 Thread Ali Hassan
Do you want to pass nil arguments then checkout my blog 
https://koohinoorgo.blogspot.com/2019/06/do-receiver-nil-argument.html. 


 Good Programmer, who write code for humans, not for machines 

-- 
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/9da94a7f-4186-40bf-8f73-101d52d468eb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Do I pass nil arguments method ?

2019-06-19 Thread Jan Mercl
Are you using some machine translator?

Many sentences in the article make little sense. Some others do, but are
either incorrect or the use wrong terminology. Also capitalization of some
words is not right.

Please do not post links to your blog to this mailing list, thank you.


On Wed, Jun 19, 2019, 17:41 Ali Hassan  wrote:

> Do you want to pass nil arguments then checkout my blog
> https://koohinoorgo.blogspot.com/2019/06/do-receiver-nil-argument.html.
>
>
>  Good Programmer, who write code for humans, not for machines
>
> --
> 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/9da94a7f-4186-40bf-8f73-101d52d468eb%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CAA40n-X776nSw_ttC2BNRXM8zZQaiD2tLtDL5zXBvJ_3anhgYw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread jake6502
This has been discussed many times before. Searching "local storage" on 
this group brings up many discussions, including:

https://groups.google.com/d/topic/golang-nuts/Nt0hVV_nqHE/discussion
https://groups.google.com/d/topic/golang-nuts/_Vv7Bzn8yH4/discussion
https://groups.google.com/d/topic/golang-nuts/zuWWBHKn6iw/discussion

My take is that GLS could be genuinely useful in a few cases, but would 
undoubtedly lead to abuse in most cases. In the vast majority of  
situations, what you really want to track, or log, is the specific work 
being done, not actually which goroutine it happens to be running on. For 
example, tracking a specific request, etc. My advice is to pass around a 
context, or some other identifying information about the specific work 
being done. At first this will seem tedious and annoying, but you will 
likely get used to it.


On Tuesday, June 18, 2019 at 10:59:09 PM UTC-4, hui zhang wrote:
>
> is there a goroutine scope global veriable ?
> like  fork a variable from main ?
>

-- 
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/53512dd1-8c24-460d-9bf5-646ea1e95d0f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread Robert Engels
Side-managed thread/execution context has been around since the concept of a thread. It is highly useful, and is more robust and secure than a Context object passed among methods.If Go had any concept of a "secure runtime" it would be essential, but it doesn't, so you make do with what you have.-Original Message-
From: jake6...@gmail.com
Sent: Jun 19, 2019 11:08 AM
To: golang-nuts 
Subject: [go-nuts] Re: is there a goroutine scope global veriable ?

This has been discussed many times before. Searching "local storage" on this group brings up many discussions, including:https://groups.google.com/d/topic/golang-nuts/Nt0hVV_nqHE/discussionhttps://groups.google.com/d/topic/golang-nuts/_Vv7Bzn8yH4/discussionhttps://groups.google.com/d/topic/golang-nuts/zuWWBHKn6iw/discussionMy take is that GLS could be genuinely useful in a few cases, but would undoubtedly lead to abuse in most cases. In the vast majority of  situations, what you really want to track, or log, is the specific work being done, not actually which goroutine it happens to be running on. For example, tracking a specific request, etc. My advice is to pass around a context, or some other identifying information about the specific work being done. At first this will seem tedious and annoying, but you will likely get used to it.On Tuesday, June 18, 2019 at 10:59:09 PM UTC-4, hui zhang wrote:is there a goroutine scope global veriable ?like  fork a variable from main ?



-- 
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/53512dd1-8c24-460d-9bf5-646ea1e95d0f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.




-- 
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/1187971360.3926.1560962237733%40wamui-berry.atl.sa.earthlink.net.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: godoc memory leak

2019-06-19 Thread 'Christopher Dang' via golang-nuts
Thanks for the feedback. For anyone experiencing this issue you can follow
it here: https://github.com/golang/go/issues/32692

On Tue, Jun 18, 2019 at 9:34 PM Agniva De Sarker <
agniva.quicksil...@gmail.com> wrote:

> I can see that files are getting added. Which means index size is expected
> to increase. But it seems sometimes it is increasing even when there is no
> change.
>
> Could you please file an issue so that folks can investigate this ? Thanks.
>
> On Tue, Jun 18, 2019, 10:17 PM Christopher Dang <
> christopher.d...@wework.com> wrote:
>
>> Hello Agniva,
>>
>> Here is the information you've asked for:
>>
>> go version: 1.12.0
>> godoc version: latest
>>
>> I don't read from an index file because I need live updating from godoc
>> and boot time isn't a high priority. This is because the service I'm
>> creating can expect many files to be added, removed, or updated while godoc
>> is running. While it would be convenient to restart godoc between file
>> system changes my superiors would prefer I not use this option.
>>
>> I've attached a log dump from godoc -v below.
>>
>> I'm running the godoc process from within a docker so I use three methods
>> to measure the memory usage:
>> 1.) I docker exec into the container and run *top. *The *VSZ% *is the
>> stat I use to measure memory from inside the docker.
>> 2.) I run *docker stats* on the container from my host process
>> 3.) since I run godoc with the verbose flag I get logs that tell me how
>> many bytes are consumed by godoc. Example:
>> 2019/06/17 23:28:26 index updated (88.264700559s, 211342912 bytes of
>> source, 17421 files, 6533095 lines, 173980 unique words, 8997500 spots)
>> 2019/06/17 23:28:26 before GC: bytes = 2385978984 *footprint* =
>> 6429047608
>> 2019/06/17 23:28:26 after  GC: bytes = 614368968* footprint *= 6429047608
>>
>> The charts and excel sheet above get their data points from godoc's
>> footprint logs. I double check every now and then that footprint's output
>> is accurate by comparing it against *top* and *docker stats. *
>>
>> The docker image is golang:1.12.0-alpine3.9
>>
>> On Mon, Jun 17, 2019 at 9:40 PM Agniva De Sarker <
>> agniva.quicksil...@gmail.com> wrote:
>>
>>> Couple of questions:
>>>
>>> 1. What version of godoc and Go are you using ? What is your go env ?
>>>
>>> 2. You are using -index but not passing an index file. Any reason for
>>> that ? godoc will load faster if you write an index beforehand and pass
>>> that.
>>>
>>> 3. I am guessing since you have set index_interval, you expect files to
>>> be added in your GOPATH. How many new files are getting added while godoc
>>> is running ?
>>>
>>> 4. Please show us the output by adding -v flag.
>>>
>>>
>>>
>>> On Tuesday, 18 June 2019 05:28:39 UTC+5:30, christo...@wework.com wrote:

 Hi all,


 I've been playing around with an internal godoc server and noticed that
 over long periods of time the memory growth is unbounded. The command I use
 to invoke godoc is *godoc -index=true -index_interval=15m
 -index_throttle=.30 -maxresults=0*. The following images below track
 the memory usage and change in memory usage over a 24 hour period on a 8
 GiB machine. I've also attached a pdf with the data points I gathered
 during the experiment. Notice how the godoc process consumes 76% of memory
 by the end of the experiment. Is this indicative of a memory leak in the
 godoc source code or is this expected behavior?


 [image: Δ Mem Usage %.png][image: Mem Usage %.png]


 --
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "golang-nuts" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/golang-nuts/nU706aM7QpM/unsubscribe.
>>> To unsubscribe from this group and all its topics, 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/60b70a8c-3a3d-49c6-b9dc-b2bd1053c435%40googlegroups.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>

-- 
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/CAM8TFU6s87RTws%2BxgMuLaoNmsNbbaCJT9GOC_fn1JDs7ahk%2Btw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] Re: is there a goroutine scope global veriable ?

2019-06-19 Thread Michael Jones
For the OP:

A thought to share on the general topic: Go is pioneering a sufficiently
different model of concurrent computation that it may not make much sense
to ask for or seek equivalencies with classic thread/process models.

This says nothing against the standard model, nor against the “missing”
services; it is a note to encourage design in Go along with coding in Go,
instead of design in C/C++/Java/POSIX/... and a best-effort realization in
Go.

By way of analogy, I’ve long been involved in boat design and construction.
We always use a pair Furuno or Simrad RADAR antennas, one of long range and
one short, to optimize object detection/clutter rejection and as a
redundancy safety factor. However, when sailing on a HobeeCat, i’ve never
looked for nor missed the Radar or any other instruments of navigation. A
HobieCat is just such a different idea of sailing that *all* the normal
mechanisms have no place.  There is no “where do I stow the anchor” or
“where do I control the RAM signal lights.” There are whole chapters of the
USCG instructions (ColRegs) where the thing discussed is not on a HobeeCat.
That does not make such boats inadequate; it makes them fun.

If you can stop thinking of concurrency in Go as a small group of
exquisitely instrumented machines and instead imagine a swarm of ants,
you’ll find new and interesting ways to solve problems. They often work
even better, and are also more fun.

On Wed, Jun 19, 2019 at 9:37 AM Robert Engels  wrote:

> Side-managed thread/execution context has been around since the concept of
> a thread. It is highly useful, and is more robust and secure than a Context
> object passed among methods.
>
> If Go had any concept of a "secure runtime" it would be essential, but it
> doesn't, so you make do with what you have.
>
>
> -Original Message-
> From: jake6...@gmail.com
> Sent: Jun 19, 2019 11:08 AM
> To: golang-nuts
> Subject: [go-nuts] Re: is there a goroutine scope global veriable ?
>
> This has been discussed many times before. Searching "local storage" on
> this group brings up many discussions, including:
>
> https://groups.google.com/d/topic/golang-nuts/Nt0hVV_nqHE/discussion
> https://groups.google.com/d/topic/golang-nuts/_Vv7Bzn8yH4/discussion
> https://groups.google.com/d/topic/golang-nuts/zuWWBHKn6iw/discussion
>
> My take is that GLS could be genuinely useful in a few cases, but would
> undoubtedly lead to abuse in most cases. In the vast majority of
> situations, what you really want to track, or log, is the specific work
> being done, not actually which goroutine it happens to be running on. For
> example, tracking a specific request, etc. My advice is to pass around a
> context, or some other identifying information about the specific work
> being done. At first this will seem tedious and annoying, but you will
> likely get used to it.
>
>
> On Tuesday, June 18, 2019 at 10:59:09 PM UTC-4, hui zhang wrote:
>>
>> is there a goroutine scope global veriable ?
>> like  fork a variable from main ?
>>
> --
> 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/53512dd1-8c24-460d-9bf5-646ea1e95d0f%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>
>
>
>
> --
> 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/1187971360.3926.1560962237733%40wamui-berry.atl.sa.earthlink.net
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>
-- 

*Michael T. jonesmichael.jo...@gmail.com *

-- 
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/CALoEmQy_p7hs%3DxrWGFx65r7xb63wGi_dg6aL6PRFfG7%2BwFP7-Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-nuts] [Job] remote Go developer at Mattel (fulltime, US-only)

2019-06-19 Thread Nate Finch
It's pretty great. and they really take work-life balance seriously. We 
launched a major project last week, and almost no one worked over time, 
certainly not any of significance, and no weekend work. 

On Wednesday, June 19, 2019 at 2:57:11 AM UTC-4, Henrik Johansson wrote:
>
> Wow! I live outside the US but this really makes me want to work for 
> Mattel. Sounds like a great place to work.
>
> On Tue, Jun 18, 2019, 22:07 Nate Finch > 
> wrote:
>
>> Want to work with me at Mattel on a Go platform?
>>
>> Mattel’s Connected Products Platform team is *the model* of where Mattel 
>> is going with its products. It is a service platform expanding to be used 
>> by teams all across the whole 30,000 person company.
>>
>> We’re looking for a senior backend developer who is very comfortable with 
>> writing Go.
>> Preferably you have experience working on backend game servers and/or 
>> delivering backend API services in production used by large numbers of end 
>> users.
>>
>> The recently launched Hotwheels id 
>>  
>> track and app leverage our Platform for login, stat storage, firmware 
>> upgrades and more.
>>
>> Brands all across Mattel are making products shipping soon that leverage 
>> the services that our team is building – identity and login services, data 
>> and download APIs, all written in Go, running on Kubernetes in Google Cloud.
>>
>> We store data in postgres and redis, leverage Google’s pubsub service, 
>> and are looking more into serverless to scale our loads.
>>
>> We monitor with prometheus, grafana, pagerduty and sentry.  We talk on 
>> Teams, all changes get reviewed on github and tests must pass in CI on 
>> Jenkins
>>
>> Want great benefits? How about great pay, half day Fridays in the summer, 
>> unlimited vacation, very low deductible health insurance, high match 401k, 
>> and more.
>>
>> We are very conscious of work-life balance, and many people on the team 
>> have kids and work around busy life schedules.
>>
>> You’ll join a fully remote dev team and mostly remote wider team that has 
>> a big impact on a huge company. While Mattel is big, our division is small 
>> and given a lot of leeway in how we run things.
>>
>> Here’s the place to apply, please ignore basically everything on that 
>> page except the apply button. I have Opinions™ about its contents, and 
>> since I’m the hiring manager, what I say goes :)
>>
>> Yes it really is (US) remote, even though it says otherwise.
>>
>>
>> https://jobs.mattel.com/job/el-segundo/platform-software-engineer-game-service/2015/12083533
>>
>> Please feel free to message me any questions before or after.
>>
>> If you don’t hear from someone within two business days of applying 
>> *PLEASE MESSAGE ME*.  <-- that’s in caps so you know you won’t be 
>> “bothering” me. Getting someone hired is super important, but sometimes 
>> balls get dropped.
>>
>> If you are underrepresented in tech, please consider applying. If you 
>> aren’t looking, please share this. Mattel values diversity, and so do I. 
>> Everyone loves toys, everyone can be a parent. We need a variety of 
>> viewpoints to ensure our products are great for everyone.
>>
>> If you want to talk before applying, feel free to DM me. If you’d rather 
>> talk to someone other than some cis white dude, ping @Claudia4Justice on 
>> Twitter.
>>
>> If you identity as a woman, non-binary, gay, bi, ace, queer, black, 
>> brown, differently abled, or otherwise, please apply. We need your 
>> particular insight. Diversity makes better products and teams. If you need 
>> special considerations, we will fight to get them for them for you.
>>
>> -- 
>> 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 golan...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/golang-nuts/84974a28-66bf-4e6a-b341-c646cc7dee3c%40googlegroups.com
>>  
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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/d089a467-d8f2-40b9-934b-07a949f29e3d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.