Let's say I have some piece of code like this:
type Foo struct {
}
func (this *Foo) Do() {
}
If I want to test that method Foo will pass in a certain scenario and fail
in another scenario should I have a test for each scenario or should I have
all scenarios tested in a method TestFoo_Do()?
When does it make sense for a package to be named in plural? For example,
I'm currently working on a MVC framework and for me it makes sense to have
a "controller" package as opposed to "controllers", but I saw that Beego
prefers plural for the same case.
--
You received this message because y
I have an HTTP server in AWS on an instance with 4 cores and 8g of memory.
The server is not processing anything, just replying with 500.
I have another machine in AWS issuing POST requests with Vegeta.
These are my results:
*10k req/s *
Requests [total, rate]1, 9628.13
I thought it was self explanatory, the handler does nothing, just returning
an error.
On Monday, July 18, 2016 at 4:34:52 PM UTC+3, Peter Waller wrote:
>
> It really depends on what you're doing while handling your requests. It
> may or may not be reasonable. Are you touching external resources
Any thoughts on how to attack this problem?
On Monday, July 18, 2016 at 4:46:26 PM UTC+3, Michael Jones wrote:
>
> When you move the rate up by 5x, from 1k => 5k, your wait time moves up by
> 2846x. That is suspicious in any system, language, etc. ;-)
>
>
>
> *From:
The command I used is: vegeta attack -targets=address.txt -body=request.txt
-duration=1s -rate=1000 > output.txt
On Monday, July 18, 2016 at 4:34:52 PM UTC+3, Peter Waller wrote:
>
> It really depends on what you're doing while handling your requests. It
> may or may not be reasonable. Are you t
The problem was the client server. It was too small (1 core, 4G of memory).
On Monday, July 18, 2016 at 4:03:26 PM UTC+3, Rayland wrote:
>
> I have an HTTP server in AWS on an instance with 4 cores and 8g of memory.
> The server is not processing anything, just replying with 500.
&
Let's say I have an object A of some type. Is there a way to create a new
object B with the same type as A without knowing the type of A in advance?
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receivin
values, which contain references to other values, sometimes leading back to
> the previous values.
>
> On Tuesday, 2 August 2016 17:13:21 UTC+10, Rayland wrote:
>>
>> Let's say I have an object A of some type. Is there a way to create a new
>> object B with the same
August 2016 18:18:05 UTC+10, Rayland wrote:
>>
>> I basically need something like this:
>>
>> var obj = &Person{Name: "John"} // I don't know what type obj will be
>> everytime
>> var newObj interface{}
>>
>> initNewObj(obj) // now
Hi all,
How can I use reflect to detect all fields that have the zero value, on a
pointer object?
Thank 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 g
Greetings fellow gophers,
I have a library in my vendor folder that looks like this:
package gorm
import (
"fmt"
"github.com/jinzhu/gorm"
_ "github.com/jinzhu/gorm/dialects/mysql"
conf "github.com/spf13/viper"
"math/rand"
"time"
)
var DB *gorm.DB
func
ndi 14 novembre 2016 09:54:40 UTC+1, Rayland a écrit :
>>
>> Greetings fellow gophers,
>>
>> I have a library in my vendor folder that looks like this:
>>
>> package gorm
>>
>> import (
>>"fmt"
>>"github
13 matches
Mail list logo