[go-nuts] Reusing tcp connections on tunnels

2020-01-16 Thread XXX ZZZ
Hello, I'm trying to write an application that will basically serve as a tunnel between some servers outside our network and our internal servers. For this I've started using a snippet that creates a tcp listener and then dials to a remote host. Code is shown here:

Re: [go-nuts] Re: Random panic in production with Sprintf

2019-05-02 Thread XXX ZZZ
gt; wrote: > > > > On Thu, May 2, 2019 at 2:50 PM Anthony Martin > wrote: > > > > > > What version of Go are you using? > > > > > > XXX ZZZ > once said: > > > > fmt.(*pp).fmtString(0xc023c17740, 0x0, 0x5, 0xc00076) > > > >

[go-nuts] Re: Random panic in production with Sprintf

2019-05-02 Thread XXX ZZZ
using go version go1.12.4 linux/amd64 El jueves, 2 de mayo de 2019, 18:50:24 (UTC-3), Anthony Martin escribió: > > What version of Go are you using? > > XXX ZZZ > once said: > > fmt.(*pp).fmtString(0xc023c17740, 0x0, 0x5, 0xc00076) > > /usr/local/go/src/fmt/p

Re: [go-nuts] Random panic in production with Sprintf

2019-05-02 Thread XXX ZZZ
; -- Marcin > > > On Thu, May 2, 2019 at 11:13 AM Burak Serdar > wrote: > >> On Thu, May 2, 2019 at 11:31 AM XXX ZZZ > > wrote: >> > >> > Hello, >> > >> > We are having a random panic on our go application that is happening >> o

Re: [go-nuts] Random panic in production with Sprintf

2019-05-02 Thread XXX ZZZ
I did but nothing detected. However there aren't any goroutined involved (except for the http request), other than that, this variable isn't shared among routines. El jueves, 2 de mayo de 2019, 14:54:42 (UTC-3), Ian Lance Taylor escribió: > > On Thu, May 2, 2019 at 10:31 AM XXX ZZZ >

[go-nuts] Random panic in production with Sprintf

2019-05-02 Thread XXX ZZZ
Hello, We are having a random panic on our go application that is happening once every million requests or so, and so far we haven't been able to reproduce it nor to even grasp what's going on. Basically our code goes like: type Subid_info struct{ Affiliate_subid string

[go-nuts] Re: Launching a windows app from command line with paths in arguments problem

2019-03-21 Thread XXX ZZZ
being said, to reiterate, the quoting of args i.e. constructing a > single string out of multiple args and then parsing it back into parts is > not formally specified and even if it was, different implementations can > have bugs. It could just as well be issue on the chrome side. >

[go-nuts] Re: Launching a windows app from command line with paths in arguments problem

2019-03-21 Thread XXX ZZZ
\Local\\Google\\Chrome\\Application\\chrome.exe" > > > > > > On Thursday, March 21, 2019 at 12:13:52 PM UTC-4, XXX ZZZ wrote: >> >> Hello, >> >> I'm trying to launch Chrome from Go under windows, some of the arguments >> I'm passing have cus

[go-nuts] Launching a windows app from command line with paths in arguments problem

2019-03-21 Thread XXX ZZZ
Hello, I'm trying to launch Chrome from Go under windows, some of the arguments I'm passing have custom paths in it and it seems that go is sanitizing these arguments and not recognizing the paths. Basically it seems to be appending the application path into the arguments with a path. Code is

[go-nuts] Re: Checking IP against CIDR ranges

2018-05-16 Thread XXX ZZZ
Thanks guys, Patricia Tree did the trick -- 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. For more options, visit

[go-nuts] Checking IP against CIDR ranges

2018-05-15 Thread XXX ZZZ
Hello, I'm trying to check an IP against a list of several CIDR ranges, so far the most obvious way to do it seems to parse both the IP and the cidr ranges ( ParseCIDR) and then do a net.contain() however, if we have more than 1 CIDR we have to loop checking one by one which imho is incredible

[go-nuts] Re: Help with XML parsing

2018-04-03 Thread XXX ZZZ
rg/p/MwpdBwvRnUP > > On Tuesday, April 3, 2018 at 2:47:49 PM UTC-6, XXX ZZZ wrote: >> >> Hello, >> >> I'm trying to parse an XML with golang but I'm having a hard time >> creating a parser for the string, in fact I couldn't even get an output >> using

[go-nuts] Help with XML parsing

2018-04-03 Thread XXX ZZZ
Hello, I'm trying to parse an XML with golang but I'm having a hard time creating a parser for the string, in fact I couldn't even get an output using interface{}. package main import ( "fmt" "encoding/xml" ) type MMXML_Listing struct { Original_title string `xml:"title"`

[go-nuts] Sync pool old data

2017-10-11 Thread XXX ZZZ
Hello, So I'm starting to play with sync pool on a program that needs to allocate a ton of short lived objects per server request. Performance seems to be better when using sync pool however I've noticed that upon releasing the object and then retrieving it again, will produce a "new object"

[go-nuts] when to use Sync pool

2017-10-06 Thread XXX ZZZ
Hello, So we are making a platform where we have to use a TON of short lived structs, in order to optimize this we intend to use sync pool, however on our benchmark tests I have found that it only seems to improve performance when the struct is big enough, for smaller structs ie: (4-5 string