contest
contest copied to clipboard
Re-evaluate performances for []*Struct over []Struct
Issue by marcoguerri
Wednesday Feb 05, 2020 at 12:48 GMT
Originally opened as https://github.com/facebookincubator/contest/issues/21
Using []Struct
is in most cases probably desirable, but in some cases []*Struct
might make sense (e.g. Targets). We should re-evaluate these cases. Here is where we use []*
, excluding Targets:
pkg/test/fetcher.go:16: Fetch(interface{}) (string, []*TestStepDescriptor, error)
pkg/job/reporter.go:20: Report(cancel <-chan struct{}, parameters interface{}, results []*test.TestResult, ev testevent.Fetcher) (bool, interface{}, error)
pkg/job/job.go:27: TestDescriptors []*test.TestDescriptor
pkg/job/job.go:63: Tests []*test.Test
pkg/runner/job_runner.go:49: testResults []*test.TestResult
pkg/jobmanager/jobmanager.go:88: tests := make([]*test.Test, 0, len(jd.TestDescriptors))
plugins/testfetchers/uri/uri.go:86:func (tf *URI) Fetch(params interface{}) (string, []*test.TestStepDescriptor, error) {
plugins/testfetchers/uri/uri.go:117: Steps []*test.TestStepDescriptor
plugins/testfetchers/literal/literal.go:29: Steps []*test.TestStepDescriptor
plugins/testfetchers/literal/literal.go:54:func (tf *Literal) Fetch(params interface{}) (string, []*test.TestStepDescriptor, error)