Currently, Caliper temporarily sets GOPATH to the Caliper root directory during benchmark execution. This makes it impossible to install Golang chaincodes from outside the caliper/src directory structure.
However, this would be desirable when, for example, we want to store our chaincodes for benchmarking in a different repository, outside of Caliper (and do not want to copy them to caliper/src before benchmarking).
Related issue: #53
To fix this issue, I added the option to leave GOPATH unchanged if the user sets the OVERWRITE_GOPATHenvironment variable to FALSE. If this environment variable is undefined or explicitly set to TRUE, then Caliper will use its root directory as GOPATH for backward compatibility reason.
This behaviour is also documented in the Fabric configuration document.
Currently, Caliper temporarily sets
GOPATH
to the Caliper root directory during benchmark execution. This makes it impossible to install Golang chaincodes from outside thecaliper/src
directory structure.However, this would be desirable when, for example, we want to store our chaincodes for benchmarking in a different repository, outside of Caliper (and do not want to copy them to
caliper/src
before benchmarking).Related issue: #53
To fix this issue, I added the option to leave
GOPATH
unchanged if the user sets theOVERWRITE_GOPATH
environment variable toFALSE
. If this environment variable is undefined or explicitly set toTRUE
, then Caliper will use its root directory asGOPATH
for backward compatibility reason.This behaviour is also documented in the Fabric configuration document.