[go-nuts] sync/mutex locking race condition issues

2018-10-16 Thread agruetz45
Hi, I am having issues with some concurrency and race conditions. I believe this is not doing what I think it does. IE I am thinking this would allow locking of any variable in the struct however it does not seem to be applying to buffer of type bytes.Buffer. What am I missing here? I have:

[go-nuts] Help with bytes/writing to aws

2018-09-17 Thread agruetz45
OK, I know I am doing something dumb and have a case of the Monday's. If anyone is able to point out my stupid it would be much appreciated. Output when opening the file in S3:

Re: [go-nuts] Character Replacement/Algorithm for Replacement

2018-08-29 Thread agruetz45
Makes sense. Best I am going to get is a linear search w/ a divide and conquer if I want to speed it up. Thanks needed the sounding board and feed back. Thanks, Anthony On Wednesday, August 29, 2018 at 8:16:44 PM UTC-7, Daniela Petruzalek wrote: > > Do you have an example? > > I'm assuming tha

[go-nuts] Character Replacement/Algorithm for Replacement

2018-08-29 Thread agruetz45
I have approximately 9 characters that all need to be replaced with different characters. I know there are a number of ways to do this but what is the most efficient? - 1) Do a []byte walk and compare each byte and replace when found? - Seems expensive if you have a 100 bytes in the []byt

Re: [go-nuts] math/big oddities

2018-04-18 Thread agruetz45
Jakob, Thank you. I knew I had to be missing some nuance of how to use the library correctly. Thanks, Anthony On Wednesday, April 18, 2018 at 1:44:13 AM UTC-7, Jakob Borg wrote: > > That is a much too large value to be precisely represented by a float64. > You need more bits, and you need to t

[go-nuts] math/big oddities

2018-04-18 Thread agruetz45
I have been playing with the karatsuba algorithm and was doing some testing testing to compute the correct values of two large numbers 3141592653589793238462643383279502884197169399375105820974944592 and 2718281828459045235360287471352662497757247093699959574966967627. When working with the mat

Re: [go-nuts] Re: Short Term DSN for database/sql

2017-11-09 Thread agruetz45
Makes sense. I think my question was more asking about the details of how the pool (sql.DB) worked. So this clears it up. The driver would provide the pool this connector to use vs the DNS string and that Connector could re-auth etc... This definitely allows for what I am looking for to be solv

Re: [go-nuts] Re: Short Term DSN for database/sql

2017-11-09 Thread agruetz45
What would happen if idle/closed connections that are in the SQL interface's connection pool? They go back to the driver provided Connector interface to re-authenticate/create a connection? Thanks, Anthony On Thursday, November 9, 2017 at 10:49:00 AM UTC-8, Daniel Theophanes wrote: > > It allow

[go-nuts] Re: Short Term DSN for database/sql

2017-11-09 Thread agruetz45
So this would allow for the driver to support a different method of opening the connection that the sql interface would use when it needed to open a new connection correct? Anthony On Tuesday, November 7, 2017 at 9:44:05 AM UTC-8, Daniel Theophanes wrote: > > Go1.10 will ship with a driver conn

Re: [go-nuts] Short Term DSN for database/sql

2017-11-07 Thread agruetz45
This does not help because if there is no connection in the connection pool the interface will open a new connection with previously supplied DSN from the sql.Open call. Anthony On Tuesday, November 7, 2017 at 7:22:00 AM UTC-8, Konstantin Khomoutov wrote: > > On Tue, Nov 07, 2017 at 12:06:27AM

[go-nuts] Short Term DSN for database/sql

2017-11-07 Thread agruetz45
It appears the Generic Interface for SQL (database/sql) does not support the ability to use short lived DSN's for cases like AWS's IAM Authentication to RDS instances. It appears that when doing its connection pooling activities it always uses whatever DSN was passed initially on Open. 1) Is th