You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: cmd/gitbase/command/server.go
+46-4Lines changed: 46 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -10,8 +10,10 @@ import (
10
10
"github.com/src-d/gitbase/internal/function"
11
11
"github.com/src-d/gitbase/internal/rule"
12
12
13
+
"github.com/opentracing/opentracing-go"
13
14
gopilosa "github.com/pilosa/go-pilosa"
14
15
"github.com/sirupsen/logrus"
16
+
"github.com/uber/jaeger-client-go/config"
15
17
sqle "gopkg.in/src-d/go-mysql-server.v0"
16
18
"gopkg.in/src-d/go-mysql-server.v0/server"
17
19
"gopkg.in/src-d/go-mysql-server.v0/sql/analyzer"
@@ -22,9 +24,10 @@ import (
22
24
const (
23
25
ServerDescription="Starts a gitbase server instance"
24
26
ServerHelp=ServerDescription+"\n\n"+
25
-
"By default when gitbase encounters and error in a repository it\n"+
27
+
"By default when gitbase encounters an error in a repository it\n"+
26
28
"stops the query. With GITBASE_SKIP_GIT_ERRORS variable it won't\n"+
27
29
"complain and just skip those rows or repositories."
30
+
TracerServiceName="gitbase"
28
31
)
29
32
30
33
// Server represents the `server` command of gitbase cli tool.
@@ -39,16 +42,24 @@ type Server struct {
39
42
PilosaURLstring`long:"pilosa" default:"http://localhost:10101" description:"URL to your pilosa server" env:"PILOSA_ENDPOINT"`
40
43
IndexDirstring`short:"i" long:"index" default:"/var/lib/gitbase/index" description:"Directory where the gitbase indexes information will be persisted." env:"GITBASE_INDEX_DIR"`
41
44
DisableSquashbool`long:"no-squash" description:"Disables the table squashing."`
42
-
// IgnoreGitErrors by default when gitbase encounters and error in a
43
-
// repository it stops the query. With this parameter it won't complain and
*Extracted from https://github.com/jaegertracing/jaeger-client-go/blob/master/README.md*
18
+
19
+
Property| Description
20
+
--- | ---
21
+
JAEGER_SERVICE_NAME | The service name
22
+
JAEGER_AGENT_HOST | The hostname for communicating with agent via UDP
23
+
JAEGER_AGENT_PORT | The port for communicating with agent via UDP
24
+
JAEGER_REPORTER_LOG_SPANS | Whether the reporter should also log the spans
25
+
JAEGER_REPORTER_MAX_QUEUE_SIZE | The reporter's maximum queue size
26
+
JAEGER_REPORTER_FLUSH_INTERVAL | The reporter's flush interval (ms)
27
+
JAEGER_SAMPLER_TYPE | The sampler type
28
+
JAEGER_SAMPLER_PARAM | The sampler parameter (number)
29
+
JAEGER_SAMPLER_MANAGER_HOST_PORT | The host name and port when using the remote controlled sampler
30
+
JAEGER_SAMPLER_MAX_OPERATIONS | The maximum number of operations that the sampler will keep track of
31
+
JAEGER_SAMPLER_REFRESH_INTERVAL | How often the remotely controlled sampler will poll jaeger-agent for the appropriate sampling strategy
32
+
JAEGER_TAGS | A comma separated list of `name = value` tracer level tags, which get added to all reported spans. The value can also refer to an environment variable using the format `${envVarName:default}`, where the `:default` is optional, and identifies a value to be used if the environment variable cannot be found
33
+
JAEGER_DISABLED | Whether the tracer is disabled or not. If true, the default `opentracing.NoopTracer` is used.
34
+
JAEGER_RPC_METRICS | Whether to store RPC metrics
12
35
13
36
## Command line arguments
14
37
15
-
```bash
38
+
```
16
39
Please specify one command of: server or version
17
40
Usage:
18
41
gitbase [OPTIONS] <server | version>
@@ -27,7 +50,7 @@ Available commands:
27
50
28
51
`server` command contains the following options:
29
52
30
-
```bash
53
+
```
31
54
Usage:
32
55
gitbase [OPTIONS] server [server-OPTIONS]
33
56
@@ -38,17 +61,22 @@ stops the query. With GITBASE_SKIP_GIT_ERRORS variable it won't
38
61
complain and just skip those rows or repositories.
39
62
40
63
Help Options:
41
-
-h, --help Show this help message
64
+
-h, --help Show this help message
42
65
43
66
[server command options]
44
-
-v Activates the verbose mode
45
-
-g, --git= Path where the git repositories are located, multiple directories can be defined. Accepts globs.
46
-
--siva= Path where the siva repositories are located, multiple directories can be defined. Accepts globs.
47
-
-h, --host= Host where the server is going to listen (default: localhost)
48
-
-p, --port= Port where the server is going to listen (default: 3306)
49
-
-u, --user= User name used for connection (default: root)
50
-
-P, --password= Password used for connection
51
-
--pilosa= URL to your pilosa server (default: http://localhost:10101)
52
-
-i, --index= Directory where the gitbase indexes information will be persisted. (default: /var/lib/gitbase/index)
53
-
--no-squash Disables the table squashing.
67
+
-v Activates the verbose mode
68
+
-g, --git= Path where the git repositories are located, multiple directories can
69
+
be defined. Accepts globs.
70
+
--siva= Path where the siva repositories are located, multiple directories can
71
+
be defined. Accepts globs.
72
+
-h, --host= Host where the server is going to listen (default: localhost)
73
+
-p, --port= Port where the server is going to listen (default: 3306)
74
+
-u, --user= User name used for connection (default: root)
75
+
-P, --password= Password used for connection
76
+
--pilosa= URL to your pilosa server (default: http://localhost:10101)
77
+
[$PILOSA_ENDPOINT]
78
+
-i, --index= Directory where the gitbase indexes information will be persisted.
0 commit comments