From f6fc8d2e3aa1acd92e761f98ff6dcd21e6c661fd Mon Sep 17 00:00:00 2001 From: Buildkite Date: Tue, 19 May 2026 06:58:33 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=A4=96=20sync'ing=20generated=20docs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/admin/code-hosts/aws-codecommit.mdx | 2 +- docs/admin/code-hosts/azuredevops.mdx | 2 +- docs/admin/code-hosts/bitbucket-cloud.mdx | 2 +- docs/admin/code-hosts/bitbucket-server.mdx | 2 +- docs/admin/code-hosts/gerrit.mdx | 2 +- docs/admin/code-hosts/github.mdx | 2 +- docs/admin/code-hosts/gitlab.mdx | 2 +- docs/admin/code-hosts/gitolite.mdx | 2 +- docs/admin/code-hosts/other.mdx | 2 +- docs/admin/code-hosts/phabricator.mdx | 2 +- docs/admin/config/settings.mdx | 5 +- docs/admin/config/site-config.mdx | 9 +- docs/admin/repo/perforce.mdx | 2 +- docs/cli/references/abc/index.mdx | 15 + docs/cli/references/abc/variables/delete.mdx | 32 + docs/cli/references/abc/variables/index.mdx | 16 + docs/cli/references/abc/variables/set.mdx | 38 + docs/cli/references/api.mdx | 57 +- docs/cli/references/auth/index.mdx | 27 + docs/cli/references/auth/token.mdx | 36 + docs/cli/references/codeowners/create.mdx | 28 + docs/cli/references/codeowners/delete.mdx | 26 + docs/cli/references/codeowners/get.mdx | 26 + docs/cli/references/codeowners/index.mdx | 29 + docs/cli/references/codeowners/update.mdx | 28 + docs/cli/references/index.mdx | 18 +- docs/cli/references/login.mdx | 39 +- docs/cli/references/orgs/create.mdx | 50 +- docs/cli/references/orgs/delete.mdx | 50 +- docs/cli/references/orgs/get.mdx | 52 +- docs/cli/references/orgs/index.mdx | 28 +- docs/cli/references/orgs/list.mdx | 54 +- docs/cli/references/orgs/members/add.mdx | 50 +- docs/cli/references/orgs/members/index.mdx | 25 +- docs/cli/references/orgs/members/remove.mdx | 49 +- docs/cli/references/users/create.mdx | 54 +- docs/cli/references/users/delete.mdx | 50 +- docs/cli/references/users/get.mdx | 54 +- docs/cli/references/users/index.mdx | 29 +- docs/cli/references/users/list.mdx | 58 +- docs/cli/references/users/prune.mdx | 61 +- docs/cli/references/users/tag.mdx | 58 +- docs/cli/references/version.mdx | 45 +- docs/self-hosted/observability/alerts.mdx | 101 ++ docs/self-hosted/observability/dashboards.mdx | 911 ++++++++++++++++++ 45 files changed, 1665 insertions(+), 565 deletions(-) create mode 100644 docs/cli/references/abc/index.mdx create mode 100644 docs/cli/references/abc/variables/delete.mdx create mode 100644 docs/cli/references/abc/variables/index.mdx create mode 100644 docs/cli/references/abc/variables/set.mdx create mode 100644 docs/cli/references/auth/index.mdx create mode 100644 docs/cli/references/auth/token.mdx create mode 100644 docs/cli/references/codeowners/create.mdx create mode 100644 docs/cli/references/codeowners/delete.mdx create mode 100644 docs/cli/references/codeowners/get.mdx create mode 100644 docs/cli/references/codeowners/index.mdx create mode 100644 docs/cli/references/codeowners/update.mdx diff --git a/docs/admin/code-hosts/aws-codecommit.mdx b/docs/admin/code-hosts/aws-codecommit.mdx index 598252204..3a088684d 100644 --- a/docs/admin/code-hosts/aws-codecommit.mdx +++ b/docs/admin/code-hosts/aws-codecommit.mdx @@ -37,7 +37,7 @@ AWS CodeCommit connections support the following configuration options, which ar {/* SCHEMA_SYNC_START: admin/code_hosts/aws_codecommit.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // REQUIRED: diff --git a/docs/admin/code-hosts/azuredevops.mdx b/docs/admin/code-hosts/azuredevops.mdx index fba7332cf..76481a4ad 100644 --- a/docs/admin/code-hosts/azuredevops.mdx +++ b/docs/admin/code-hosts/azuredevops.mdx @@ -69,7 +69,7 @@ Azure DevOps connections support the following configuration options, which are {/* SCHEMA_SYNC_START: admin/code_hosts/azuredevops.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json // Authentication alternatives: token OR windowsPassword diff --git a/docs/admin/code-hosts/bitbucket-cloud.mdx b/docs/admin/code-hosts/bitbucket-cloud.mdx index cd611356b..4aa9d6249 100644 --- a/docs/admin/code-hosts/bitbucket-cloud.mdx +++ b/docs/admin/code-hosts/bitbucket-cloud.mdx @@ -116,7 +116,7 @@ Bitbucket Cloud connections support the following configuration options, which a {/* SCHEMA_SYNC_START: admin/code_hosts/bitbucket_cloud.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // The workspace access token to use when authenticating with Bitbucket Cloud. diff --git a/docs/admin/code-hosts/bitbucket-server.mdx b/docs/admin/code-hosts/bitbucket-server.mdx index ef1661138..0eb747549 100644 --- a/docs/admin/code-hosts/bitbucket-server.mdx +++ b/docs/admin/code-hosts/bitbucket-server.mdx @@ -202,7 +202,7 @@ Bitbucket Server / Bitbucket Data Center connections support the following confi {/* SCHEMA_SYNC_START: admin/code_hosts/bitbucket_server.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json // Authentication alternatives: token OR password diff --git a/docs/admin/code-hosts/gerrit.mdx b/docs/admin/code-hosts/gerrit.mdx index 0d66540c4..685605b7b 100644 --- a/docs/admin/code-hosts/gerrit.mdx +++ b/docs/admin/code-hosts/gerrit.mdx @@ -113,7 +113,7 @@ Gerrit connections support the following configuration options, which are specif {/* SCHEMA_SYNC_START: admin/code_hosts/gerrit.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // If non-null, enforces Gerrit repository permissions. This requires that there is an item in the [site configuration json](https://sourcegraph.com/docs/admin/config/site_config#auth-providers) `auth.providers` field, of type "gerrit" with the same `url` field as specified in this `GerritConnection`. diff --git a/docs/admin/code-hosts/github.mdx b/docs/admin/code-hosts/github.mdx index f29014ff8..e95bbc487 100644 --- a/docs/admin/code-hosts/github.mdx +++ b/docs/admin/code-hosts/github.mdx @@ -454,7 +454,7 @@ GitHub connections support the following configuration options, which are specif {/* SCHEMA_SYNC_START: admin/code_hosts/github.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json // Authentication alternatives: token OR gitHubAppDetails OR externalAccount OR useRandomExternalAccount diff --git a/docs/admin/code-hosts/gitlab.mdx b/docs/admin/code-hosts/gitlab.mdx index b9970b075..57a8a27d1 100644 --- a/docs/admin/code-hosts/gitlab.mdx +++ b/docs/admin/code-hosts/gitlab.mdx @@ -189,7 +189,7 @@ See [Internal rate limits](/admin/code-hosts/rate-limits#internal-rate-limits). {/* SCHEMA_SYNC_START: admin/code_hosts/gitlab.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // If non-null, enforces GitLab repository permissions. This requires that there be an item in the `auth.providers` field of type "gitlab" with the same `url` field as specified in this `GitLabConnection`. diff --git a/docs/admin/code-hosts/gitolite.mdx b/docs/admin/code-hosts/gitolite.mdx index 8fe847b72..b9da122b5 100644 --- a/docs/admin/code-hosts/gitolite.mdx +++ b/docs/admin/code-hosts/gitolite.mdx @@ -25,7 +25,7 @@ To connect Gitolite to Sourcegraph: {/* SCHEMA_SYNC_START: admin/code_hosts/gitolite.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // A list of repositories to never mirror from this Gitolite instance. Supports excluding by exact name ({"name": "foo"}). diff --git a/docs/admin/code-hosts/other.mdx b/docs/admin/code-hosts/other.mdx index 4da97689c..7d92aa454 100644 --- a/docs/admin/code-hosts/other.mdx +++ b/docs/admin/code-hosts/other.mdx @@ -68,7 +68,7 @@ Repositories must be listed individually: {/* SCHEMA_SYNC_START: admin/code_hosts/other_external_service.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // A list of repositories to never mirror by name after applying repositoryPathPattern. Supports excluding by exact name ({"name": "myrepo"}) or regular expression ({"pattern": ".*secret.*"}). diff --git a/docs/admin/code-hosts/phabricator.mdx b/docs/admin/code-hosts/phabricator.mdx index 6982ca5a7..f5156763f 100644 --- a/docs/admin/code-hosts/phabricator.mdx +++ b/docs/admin/code-hosts/phabricator.mdx @@ -76,7 +76,7 @@ The Sourcegraph instance's site admin must [update the `corsOrigin` site config {/* SCHEMA_SYNC_START: admin/code_hosts/phabricator.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // SSH cipher to use when cloning via SSH. Must be a valid choice from `ssh -Q cipher`. diff --git a/docs/admin/config/settings.mdx b/docs/admin/config/settings.mdx index 3922a2133..dbc46ba2e 100644 --- a/docs/admin/config/settings.mdx +++ b/docs/admin/config/settings.mdx @@ -27,7 +27,7 @@ Settings options and their default values are shown below. {/* SCHEMA_SYNC_START: admin/config/settings.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { @@ -81,6 +81,9 @@ Settings options and their default values are shown below. // Usually this setting is used in global and organization settings. If set in user settings, the message will only be displayed to that single user. "cody.notices": null, + // BETA: Enable the new compare experience. This feature is under active development and will eventually become the default (and the setting will be removed) + "compareV2.enabled": false, + // Disable the Slack community call-to-action banner on the Deep Search page. "deepSearch.slackCta.disabled": false, diff --git a/docs/admin/config/site-config.mdx b/docs/admin/config/site-config.mdx index 745236abe..6b5a93176 100644 --- a/docs/admin/config/site-config.mdx +++ b/docs/admin/config/site-config.mdx @@ -21,7 +21,7 @@ All site configuration options and their default values are shown below. {/* SCHEMA_SYNC_START: admin/config/site.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { @@ -311,7 +311,6 @@ All site configuration options and their default values are shown below. "requireUpperandLowerCase": true }, "perforceChangelistMapping": "enabled", - "preciseCodeNavFlow": "v2", "pythonPackages": "disabled", "ranking": { "flushWallTimeMS": 500, @@ -677,9 +676,11 @@ All site configuration options and their default values are shown below. // "enabled": true // } // - { + // "disabledMessage": "Need an account? [Open a ticket](https://tickets.example.com/new) to request access.", // "enabled": false // } "auth.accessRequest": { + "disabledMessage": null, "enabled": true }, @@ -901,7 +902,7 @@ All site configuration options and their default values are shown below. // The tag to use for the batcheshelper image in executors when using native execution. Use this value to use a custom tag. Sourcegraph by default uses the best match, so use this setting only if you really need to overwrite it and make sure to keep it updated. // Other example values: - // - "4.1.0" + // - "7.2.0" "executors.batcheshelperImageTag": null, // The URL where Sourcegraph executors can reach the Sourcegraph instance. If not set, defaults to externalURL. URLs with a path (other than `/`) are not allowed. For Docker executors, the special hostname `host.docker.internal` can be used to refer to the Docker container's host. @@ -937,7 +938,7 @@ All site configuration options and their default values are shown below. // The tag to use for the src-cli image in executors. Use this value to use a custom tag. Sourcegraph by default uses the best match, so use this setting only if you really need to overwrite it and make sure to keep it updated. // Other example values: - // - "4.1.0" + // - "7.2.0" "executors.srcCLIImageTag": null, diff --git a/docs/admin/repo/perforce.mdx b/docs/admin/repo/perforce.mdx index 25fc0a683..e8fc4b0b6 100644 --- a/docs/admin/repo/perforce.mdx +++ b/docs/admin/repo/perforce.mdx @@ -228,7 +228,7 @@ With this setting, Sourcegraph will ignore any rules with a host other than `*`, {/* SCHEMA_SYNC_START: admin/code_hosts/perforce.schema.json */} {/* WARNING: This section is auto-generated during releases. Do not edit manually. */} -{/* Last updated: 2026-04-27T11:17:39Z */} +{/* Last updated: 2026-05-19T06:58:31Z */} ```json { // If non-null, enforces Perforce depot permissions. diff --git a/docs/cli/references/abc/index.mdx b/docs/cli/references/abc/index.mdx new file mode 100644 index 000000000..b0b1ac794 --- /dev/null +++ b/docs/cli/references/abc/index.mdx @@ -0,0 +1,15 @@ +# `src abc` + +manages agentic batch changes. + + + +## Usage + +```sh +$ src abc [command options] +``` + +## Subcommands + +* [`variables`](abc/variables) \ No newline at end of file diff --git a/docs/cli/references/abc/variables/delete.mdx b/docs/cli/references/abc/variables/delete.mdx new file mode 100644 index 000000000..f62ab0543 --- /dev/null +++ b/docs/cli/references/abc/variables/delete.mdx @@ -0,0 +1,32 @@ +# `src abc variables delete` + +Delete variables on a workflow instance. + +Delete workflow instance variables + +Examples: + + Delete a variable from a workflow instance: + + $ src abc variables delete QWdlbnRpY1dvcmtmbG93SW5zdGFuY2U6MQ== approval + + Delete multiple variables in one request: + + $ src abc variables delete QWdlbnRpY1dvcmtmbG93SW5zdGFuY2U6MQ== --var approval --var checkpoints + +## Usage + +```sh +$ src abc variables delete [options] [ ...] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--var` | Variable name to delete. Repeat for multiple names. | ``| \ No newline at end of file diff --git a/docs/cli/references/abc/variables/index.mdx b/docs/cli/references/abc/variables/index.mdx new file mode 100644 index 000000000..d6390599c --- /dev/null +++ b/docs/cli/references/abc/variables/index.mdx @@ -0,0 +1,16 @@ +# `src abc variables` + +manage workflow instance variables. + + + +## Usage + +```sh +$ src abc variables [command options] +``` + +## Subcommands + +* [`delete`](variables/delete) +* [`set`](variables/set) \ No newline at end of file diff --git a/docs/cli/references/abc/variables/set.mdx b/docs/cli/references/abc/variables/set.mdx new file mode 100644 index 000000000..dced6781d --- /dev/null +++ b/docs/cli/references/abc/variables/set.mdx @@ -0,0 +1,38 @@ +# `src abc variables set` + +Set variables on a workflow instance. + +Set workflow instance variables + +Examples: + + Set a string variable on a workflow instance: + + $ src abc variables set QWdlbnRpY1dvcmtmbG93SW5zdGFuY2U6MQ== prompt="tighten the review criteria" + + Set multiple variables in one request: + + $ src abc variables set QWdlbnRpY1dvcmtmbG93SW5zdGFuY2U6MQ== --var prompt="tighten the review criteria" --var checkpoints='[1,2,3]' + + Set a structured JSON value: + + $ src abc variables set QWdlbnRpY1dvcmtmbG93SW5zdGFuY2U6MQ== checkpoints='[1,2,3]' + +NOTE: Values are interpreted as JSON literals when valid. Otherwise they are sent as plain strings. + +## Usage + +```sh +$ src abc variables set [options] [= ...] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--var` | Variable assignment in = form. Repeat to set multiple variables. | ``| \ No newline at end of file diff --git a/docs/cli/references/api.mdx b/docs/cli/references/api.mdx index 2204e1b1f..a8dafcd8f 100644 --- a/docs/cli/references/api.mdx +++ b/docs/cli/references/api.mdx @@ -1,37 +1,6 @@ # `src api` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-query` | GraphQL query to execute, e.g. 'query \{ currentUser \{ username \} \}' (stdin otherwise) | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-vars` | GraphQL query variables to include as JSON string, e.g. '\{"var": "val", "var2": "val2"\}' | | - - -## Usage - -``` -Usage of 'src api': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -query string - GraphQL query to execute, e.g. 'query { currentUser { username } }' (stdin otherwise) - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -vars string - GraphQL query variables to include as JSON string, e.g. '{"var": "val", "var2": "val2"}' +interacts with the Sourcegraph GraphQL API. Exit codes: @@ -43,8 +12,8 @@ Examples: Run queries (identical behavior): - $ echo 'query { currentUser { username } }' | src api - $ src api -query='query { currentUser { username } }' + $ echo 'query \{ currentUser \{ username \} \}' | src api + $ src api -query='query \{ currentUser \{ username \} \}' Specify query variables: @@ -52,12 +21,26 @@ Examples: Searching for "Router" and getting result count: - $ echo 'query($query: String!) { search(query: $query) { results { resultCount } } }' | src api 'query=Router' + $ echo 'query($query: String!) \{ search(query: $query) \{ results \{ resultCount \} \} \}' | src api 'query=Router' Get the curl command for a query (just add '-get-curl' in the flags section): - $ src api -get-curl -query='query { currentUser { username } }' + $ src api -get-curl -query='query \{ currentUser \{ username \} \}' +## Usage +```sh +$ src api [options] [variable=value ...] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--query` | GraphQL query to execute, e.g. 'query \{ currentUser \{ username \} \}' (stdin otherwise) | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--vars` | GraphQL query variables to include as JSON string, e.g. '\{"var": "val", "var2": "val2"\}' | ``| \ No newline at end of file diff --git a/docs/cli/references/auth/index.mdx b/docs/cli/references/auth/index.mdx new file mode 100644 index 000000000..9b08af382 --- /dev/null +++ b/docs/cli/references/auth/index.mdx @@ -0,0 +1,27 @@ +# `src auth` + +authentication helper commands. + +Authentication-related helper commands. + +Examples: + +Print the active auth token: + +$ src auth token +sgp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx + +Print the current Authorization header: + +$ src auth token --header +Authorization: token sgp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx + +## Usage + +```sh +$ src auth [command options] +``` + +## Subcommands + +* [`token`](auth/token) \ No newline at end of file diff --git a/docs/cli/references/auth/token.mdx b/docs/cli/references/auth/token.mdx new file mode 100644 index 000000000..e41e986ce --- /dev/null +++ b/docs/cli/references/auth/token.mdx @@ -0,0 +1,36 @@ +# `src auth token` + +prints the current authentication token or Authorization header. + +Print the current authentication token. + +Use --header to print a complete Authorization header instead. + +Examples: + +Raw token output: + +$ src auth token +sgp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx + +Authorization header output: + +$ src auth token --header +Authorization: token sgp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx + +If you are authenticated with OAuth instead of SRC_ACCESS_TOKEN, the header uses the Bearer scheme: + +$ src auth token --header +Authorization: Bearer eyJhbGciOi... + +## Usage + +```sh +$ src auth token [options] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--header` | print the token as an Authorization header | `false`| \ No newline at end of file diff --git a/docs/cli/references/codeowners/create.mdx b/docs/cli/references/codeowners/create.mdx new file mode 100644 index 000000000..134edb219 --- /dev/null +++ b/docs/cli/references/codeowners/create.mdx @@ -0,0 +1,28 @@ +# `src codeowners create` + +create a codeowners file. + +Create a codeowners file for a repository. + +Examples: + + $ src codeowners create -repo='github.com/sourcegraph/sourcegraph' -f CODEOWNERS + $ src codeowners create -repo='github.com/sourcegraph/sourcegraph' -f - + +## Usage + +```sh +$ src codeowners create [options] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--file, -f` | File path to read ownership information from (- for stdin) | ``| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--repo` | The repository to attach the data to | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/codeowners/delete.mdx b/docs/cli/references/codeowners/delete.mdx new file mode 100644 index 000000000..7450227b9 --- /dev/null +++ b/docs/cli/references/codeowners/delete.mdx @@ -0,0 +1,26 @@ +# `src codeowners delete` + +delete a codeowners file. + +Delete a codeowners file for a repository. + +Examples: + + $ src codeowners delete -repo='github.com/sourcegraph/sourcegraph' + +## Usage + +```sh +$ src codeowners delete [options] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--repo` | The repository to delete the data for | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/codeowners/get.mdx b/docs/cli/references/codeowners/get.mdx new file mode 100644 index 000000000..259443674 --- /dev/null +++ b/docs/cli/references/codeowners/get.mdx @@ -0,0 +1,26 @@ +# `src codeowners get` + +returns the codeowners file for a repository, if it exists. + +Read the current codeowners file for a repository. + +Examples: + + $ src codeowners get -repo='github.com/sourcegraph/sourcegraph' + +## Usage + +```sh +$ src codeowners get [options] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--repo` | The repository to attach the data to | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/codeowners/index.mdx b/docs/cli/references/codeowners/index.mdx new file mode 100644 index 000000000..f580d73d5 --- /dev/null +++ b/docs/cli/references/codeowners/index.mdx @@ -0,0 +1,29 @@ +# `src codeowners` + +manages ingested code ownership data. + +'src codeowners' manages ingested code ownership data in a Sourcegraph instance. + +Usage: + + src codeowners [command options] + +Examples: + + $ src codeowners get -repo='github.com/sourcegraph/sourcegraph' + $ src codeowners create -repo='github.com/sourcegraph/sourcegraph' -f CODEOWNERS + $ src codeowners update -repo='github.com/sourcegraph/sourcegraph' -f CODEOWNERS + $ src codeowners delete -repo='github.com/sourcegraph/sourcegraph' + +## Usage + +```sh +$ src codeowners [command options] +``` + +## Subcommands + +* [`create`](codeowners/create) +* [`delete`](codeowners/delete) +* [`get`](codeowners/get) +* [`update`](codeowners/update) \ No newline at end of file diff --git a/docs/cli/references/codeowners/update.mdx b/docs/cli/references/codeowners/update.mdx new file mode 100644 index 000000000..a7e2f7720 --- /dev/null +++ b/docs/cli/references/codeowners/update.mdx @@ -0,0 +1,28 @@ +# `src codeowners update` + +update a codeowners file. + +Update a codeowners file for a repository. + +Examples: + + $ src codeowners update -repo='github.com/sourcegraph/sourcegraph' -f CODEOWNERS + $ src codeowners update -repo='github.com/sourcegraph/sourcegraph' -f - + +## Usage + +```sh +$ src codeowners update [options] +``` + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--file, -f` | File path to read ownership information from (- for stdin) | ``| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--repo` | The repository to attach the data to | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/index.mdx b/docs/cli/references/index.mdx index ce8d4246f..fb7a86720 100644 --- a/docs/cli/references/index.mdx +++ b/docs/cli/references/index.mdx @@ -3,22 +3,12 @@ ## Subcommands -* [`admin`](references/admin) +* [`abc`](references/abc) * [`api`](references/api) -* [`batch`](references/batch) -* [`code-intel`](references/code-intel) +* [`auth`](references/auth) * [`codeowners`](references/codeowners) -* [`config`](references/config) -* [`debug`](references/debug) -* [`extsvc`](references/extsvc) -* [`lsp`](references/lsp) +* [`login`](references/login) * [`orgs`](references/orgs) -* [`repos`](references/repos) -* [`search`](references/search) -* [`search-jobs`](references/search-jobs) -* [`serve-git`](references/serve-git) -* [`snapshot`](references/snapshot) -* [`teams`](references/teams) * [`users`](references/users) -* [`validate`](references/validate) +* [`version`](references/version) \ No newline at end of file diff --git a/docs/cli/references/login.mdx b/docs/cli/references/login.mdx index 19a74edaf..5fd07ddd8 100644 --- a/docs/cli/references/login.mdx +++ b/docs/cli/references/login.mdx @@ -1,20 +1,7 @@ # `src login` +authenticate to a Sourcegraph instance with your user credentials. -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` 'src login' helps you authenticate 'src' to access a Sourcegraph instance with your user credentials. Usage: @@ -35,16 +22,18 @@ Examples: $ src login https://sourcegraph.com - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +## Usage +```sh +$ src login [command options] [SOURCEGRAPH_URL] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/orgs/create.mdx b/docs/cli/references/orgs/create.mdx index 2842349a3..54f11b857 100644 --- a/docs/cli/references/orgs/create.mdx +++ b/docs/cli/references/orgs/create.mdx @@ -1,37 +1,6 @@ # `src orgs create` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-display-name` | The new organization's display name. Defaults to organization name if unspecified. | | -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-name` | The new organization's name. (required) | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src orgs create': - -display-name string - The new organization's display name. Defaults to organization name if unspecified. - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -name string - The new organization's name. (required) - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +creates an organization. Examples: @@ -39,7 +8,20 @@ Examples: $ src orgs create -name=abc-org -display-name='ABC Organization' +## Usage - +```sh +$ src orgs create [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--display-name` | The new organization's display name. Defaults to organization name if unspecified. | ``| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--name` | The new organization's name. (required) | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/orgs/delete.mdx b/docs/cli/references/orgs/delete.mdx index 5175de533..586e806b7 100644 --- a/docs/cli/references/orgs/delete.mdx +++ b/docs/cli/references/orgs/delete.mdx @@ -1,34 +1,6 @@ # `src orgs delete` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-id` | The ID of the organization to delete. | | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src orgs delete': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -id string - The ID of the organization to delete. - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +deletes an organization. Examples: @@ -38,13 +10,25 @@ Examples: Delete an organization by name: - $ src orgs delete -id=$(src orgs get -f='{{.ID}}' -name=abc-org) + $ src orgs delete -id=$(src orgs get -f='\{\{.ID\}\}' -name=abc-org) Delete all organizations that match the query - $ src orgs list -f='{{.ID}}' -query=abc-org | xargs -n 1 -I ORGID src orgs delete -id=ORGID - + $ src orgs list -f='\{\{.ID\}\}' -query=abc-org | xargs -n 1 -I ORGID src orgs delete -id=ORGID +## Usage +```sh +$ src orgs delete [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--id` | The ID of the organization to delete. | ``| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/orgs/get.mdx b/docs/cli/references/orgs/get.mdx index 64e0c0295..443647055 100644 --- a/docs/cli/references/orgs/get.mdx +++ b/docs/cli/references/orgs/get.mdx @@ -1,37 +1,6 @@ # `src orgs get` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Name\}\} (\{\{.DisplayName\}\})") | `{{.\|json}}` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-name` | Look up organization by name. (e.g. "abc-org") | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src orgs get': - -dump-requests - Log GraphQL requests and responses to stdout - -f string - Format for the output, using the syntax of Go package text/template. (e.g. "{{.ID}}: {{.Name}} ({{.DisplayName}})") (default "{{.|json}}") - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -name string - Look up organization by name. (e.g. "abc-org") - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +gets an organization. Examples: @@ -41,9 +10,22 @@ Examples: List usernames of members of organization named abc-org (replace '.Username' with '.ID' to list user IDs): - $ src orgs get -f '{{range $i,$ := .Members.Nodes}}{{if ne $i 0}}{{"\n"}}{{end}}{{.Username}}{{end}}' -name=abc-org - + $ src orgs get -f '\{\{range $i,$ := .Members.Nodes\}\}\{\{if ne $i 0\}\}\{\{"\n"\}\}\{\{end\}\}\{\{.Username\}\}\{\{end\}\}' -name=abc-org +## Usage +```sh +$ src orgs get [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--name` | Look up organization by name. (e.g. "abc-org") | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Name\}\} (\{\{.DisplayName\}\})") \| `"\{\{.\\|json\}\}"`| \ No newline at end of file diff --git a/docs/cli/references/orgs/index.mdx b/docs/cli/references/orgs/index.mdx index a3b4977dc..e816a97fa 100644 --- a/docs/cli/references/orgs/index.mdx +++ b/docs/cli/references/orgs/index.mdx @@ -1,11 +1,33 @@ # `src orgs` -## Subcommands +manages organizations. + +'src orgs' is a tool that manages organizations on a Sourcegraph instance. + +Usage: + + src orgs command [command options] + +The commands are: + list lists organizations + get gets an organization + create creates an organization + delete deletes an organization + members manages organization members + +Use "src orgs [command] -h" for more information about a command. + +## Usage + +```sh +$ src orgs [command options] +``` + +## Subcommands * [`create`](orgs/create) * [`delete`](orgs/delete) * [`get`](orgs/get) * [`list`](orgs/list) -* [`members`](orgs/members) - \ No newline at end of file +* [`members`](orgs/members) \ No newline at end of file diff --git a/docs/cli/references/orgs/list.mdx b/docs/cli/references/orgs/list.mdx index 06f4bacb9..9bb10b521 100644 --- a/docs/cli/references/orgs/list.mdx +++ b/docs/cli/references/orgs/list.mdx @@ -1,40 +1,6 @@ # `src orgs list` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Name\}\} (\{\{.DisplayName\}\})" or "\{\{.\|json\}\}") | `{{.Name}}` | -| `-first` | Returns the first n organizations from the list. | `1000` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-query` | Returns organizations whose names match the query. (e.g. "alice") | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src orgs list': - -dump-requests - Log GraphQL requests and responses to stdout - -f string - Format for the output, using the syntax of Go package text/template. (e.g. "{{.ID}}: {{.Name}} ({{.DisplayName}})" or "{{.|json}}") (default "{{.Name}}") - -first int - Returns the first n organizations from the list. (default 1000) - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -query string - Returns organizations whose names match the query. (e.g. "alice") - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +lists organizations. Examples: @@ -46,7 +12,21 @@ Examples: $ src orgs list -query='myquery' +## Usage - +```sh +$ src orgs list [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--first` | Returns the first n organizations from the list. | `1000`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--query` | Returns organizations whose names match the query. (e.g. "alice") | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Name\}\} (\{\{.DisplayName\}\})" or "\{\{.\|json\}\}") \| `"\{\{.Name\}\}"`| \ No newline at end of file diff --git a/docs/cli/references/orgs/members/add.mdx b/docs/cli/references/orgs/members/add.mdx index 3d87f9135..5e398363e 100644 --- a/docs/cli/references/orgs/members/add.mdx +++ b/docs/cli/references/orgs/members/add.mdx @@ -1,45 +1,27 @@ # `src orgs members add` +adds a user as a member to an organization. -## Flags +Examples: -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-org-id` | ID of organization to which to add member. (required) | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-username` | Username of user to add as member. (required) | | + Add a member (alice) to an organization (abc-org): + $ src orgs members add -org-id=$(src org get -f '\{\{.ID\}\}' -name=abc-org) -username=alice ## Usage +```sh +$ src orgs members add [options] ``` -Usage of 'src orgs members add': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -org-id string - ID of organization to which to add member. (required) - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -username string - Username of user to add as member. (required) - -Examples: - - Add a member (alice) to an organization (abc-org): - - $ src orgs members add -org-id=$(src org get -f '{{.ID}}' -name=abc-org) -username=alice - +## Flags -``` - \ No newline at end of file +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--org-id` | ID of organization to which to add member. (required) | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--username` | Username of user to add as member. (required) | ``| \ No newline at end of file diff --git a/docs/cli/references/orgs/members/index.mdx b/docs/cli/references/orgs/members/index.mdx index bfaf71b88..a63b687cb 100644 --- a/docs/cli/references/orgs/members/index.mdx +++ b/docs/cli/references/orgs/members/index.mdx @@ -1,8 +1,27 @@ # `src orgs members` -## Subcommands +manages organization members. + +'src orgs members' is a tool that manages organization members on a Sourcegraph instance. + +Usage: + + src orgs members command [command options] + +The commands are: + add adds a user as a member to an organization + remove removes a user as a member from an organization + +Use "src orgs members [command] -h" for more information about a command. + +## Usage + +```sh +$ src orgs members [command options] +``` + +## Subcommands * [`add`](members/add) -* [`remove`](members/remove) - \ No newline at end of file +* [`remove`](members/remove) \ No newline at end of file diff --git a/docs/cli/references/orgs/members/remove.mdx b/docs/cli/references/orgs/members/remove.mdx index e4f09aa23..d9b8062f4 100644 --- a/docs/cli/references/orgs/members/remove.mdx +++ b/docs/cli/references/orgs/members/remove.mdx @@ -1,44 +1,27 @@ # `src orgs members remove` +removes a user as a member from an organization. -## Flags +Examples: -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-org-id` | ID of organization from which to remove member. (required) | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-user-id` | ID of user to remove as member. (required) | | + Remove a member (alice) from an organization (abc-org): + $ src orgs members remove -org-id=$(src org get -f '\{\{.ID\}\}' -name=abc-org) -user-id=$(src users get -f '\{\{.ID\}\}' -username=alice) ## Usage +```sh +$ src orgs members remove [options] ``` -Usage of 'src orgs members remove': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -org-id string - ID of organization from which to remove member. (required) - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -user-id string - ID of user to remove as member. (required) - -Examples: - - Remove a member (alice) from an organization (abc-org): - - $ src orgs members remove -org-id=$(src org get -f '{{.ID}}' -name=abc-org) -user-id=$(src users get -f '{{.ID}}' -username=alice) +## Flags -``` - \ No newline at end of file +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--org-id` | ID of organization from which to remove member. (required) | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--user-id` | ID of user to remove as member. (required) | ``| \ No newline at end of file diff --git a/docs/cli/references/users/create.mdx b/docs/cli/references/users/create.mdx index 096cfb496..8c47135c2 100644 --- a/docs/cli/references/users/create.mdx +++ b/docs/cli/references/users/create.mdx @@ -1,40 +1,6 @@ # `src users create` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-email` | The new user's email address. (required) | | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-reset-password-url` | Print the reset password URL to manually send to the new user. | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-username` | The new user's username. (required) | | - - -## Usage - -``` -Usage of 'src users create': - -dump-requests - Log GraphQL requests and responses to stdout - -email string - The new user's email address. (required) - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -reset-password-url - Print the reset password URL to manually send to the new user. - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -username string - The new user's username. (required) +creates a user account. Examples: @@ -42,7 +8,21 @@ Examples: $ src users create -username=alice -email=alice@example.com +## Usage - +```sh +$ src users create [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--email` | The new user's email address | ``| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--reset-password-url` | Print the reset password URL to manually send to the new user. | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--username` | The new user's username. | ``| \ No newline at end of file diff --git a/docs/cli/references/users/delete.mdx b/docs/cli/references/users/delete.mdx index 72b0db301..a616295da 100644 --- a/docs/cli/references/users/delete.mdx +++ b/docs/cli/references/users/delete.mdx @@ -1,34 +1,6 @@ # `src users delete` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-id` | The ID of the user to delete. | | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src users delete': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -id string - The ID of the user to delete. - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +deletes a user account. Examples: @@ -38,13 +10,25 @@ Examples: Delete a user account by username: - $ src users delete -id=$(src users get -f='{{.ID}}' -username=alice) + $ src users delete -id=$(src users get -f='\{\{.ID\}\}' -username=alice) Delete all user accounts that match the query: - $ src users list -f='{{.ID}}' -query=alice | xargs -n 1 -I USERID src users delete -id=USERID - + $ src users list -f='\{\{.ID\}\}' -query=alice | xargs -n 1 -I USERID src users delete -id=USERID +## Usage +```sh +$ src users delete [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--id` | The ID of the user to delete. | ``| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/users/get.mdx b/docs/cli/references/users/get.mdx index 15054f468..d434569dd 100644 --- a/docs/cli/references/users/get.mdx +++ b/docs/cli/references/users/get.mdx @@ -1,40 +1,6 @@ # `src users get` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-email` | Look up user by email. (e.g. "alice@sourcegraph.com") | | -| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Username\}\} (\{\{.DisplayName\}\})") | `{{.\|json}}` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-username` | Look up user by username. (e.g. "alice") | | - - -## Usage - -``` -Usage of 'src users get': - -dump-requests - Log GraphQL requests and responses to stdout - -email string - Look up user by email. (e.g. "alice@sourcegraph.com") - -f string - Format for the output, using the syntax of Go package text/template. (e.g. "{{.ID}}: {{.Username}} ({{.DisplayName}})") (default "{{.|json}}") - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -username string - Look up user by username. (e.g. "alice") +gets a user. Examples: @@ -42,7 +8,21 @@ Examples: $ src users get -username=alice +## Usage - +```sh +$ src users get [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--email` | Look up user by email. (e.g. "alice@sourcegraph.com") | ``| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--username` | Look up user by username. (e.g. "alice") | ``| +| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Username\}\} (\{\{.DisplayName\}\})") \| `"\{\{.\\|json\}\}"`| \ No newline at end of file diff --git a/docs/cli/references/users/index.mdx b/docs/cli/references/users/index.mdx index 359e58f4e..99f7a9c57 100644 --- a/docs/cli/references/users/index.mdx +++ b/docs/cli/references/users/index.mdx @@ -1,12 +1,35 @@ # `src users` -## Subcommands +manages users. + +'src users' is a tool that manages users on a Sourcegraph instance. + +Usage: + + src users command [command options] + +The commands are: + list lists users + get gets a user + create creates a user account + delete deletes a user account + prune deletes inactive users + tag add/remove a tag on a user + +Use "src users [command] -h" for more information about a command. + +## Usage + +```sh +$ src users [command options] +``` + +## Subcommands * [`create`](users/create) * [`delete`](users/delete) * [`get`](users/get) * [`list`](users/list) * [`prune`](users/prune) -* [`tag`](users/tag) - \ No newline at end of file +* [`tag`](users/tag) \ No newline at end of file diff --git a/docs/cli/references/users/list.mdx b/docs/cli/references/users/list.mdx index bc4d8c97b..ba5336627 100644 --- a/docs/cli/references/users/list.mdx +++ b/docs/cli/references/users/list.mdx @@ -1,43 +1,6 @@ # `src users list` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Username\}\} (\{\{.DisplayName\}\})" or "\{\{.\|json\}\}") | `{{.Username}}` | -| `-first` | Returns the first n users from the list. | `1000` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-query` | Returns users whose names match the query. (e.g. "alice") | | -| `-tag` | Returns users with the given tag. | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src users list': - -dump-requests - Log GraphQL requests and responses to stdout - -f string - Format for the output, using the syntax of Go package text/template. (e.g. "{{.ID}}: {{.Username}} ({{.DisplayName}})" or "{{.|json}}") (default "{{.Username}}") - -first int - Returns the first n users from the list. (default 1000) - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -query string - Returns users whose names match the query. (e.g. "alice") - -tag string - Returns users with the given tag. - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +lists users. Examples: @@ -53,7 +16,22 @@ Examples: $ src users list -tag=foo +## Usage - +```sh +$ src users list [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--first` | Returns the first n users from the list. | `1000`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--query` | Returns users whose names match the query. (e.g. "alice") | ``| +| `--tag` | Returns users with the given tag. | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `-f` | Format for the output, using the syntax of Go package text/template. (e.g. "\{\{.ID\}\}: \{\{.Username\}\} (\{\{.DisplayName\}\})" or "\{\{.\|json\}\}") \| `"\{\{.Username\}\}"`| \ No newline at end of file diff --git a/docs/cli/references/users/prune.mdx b/docs/cli/references/users/prune.mdx index 471fb7b90..bc9072d66 100644 --- a/docs/cli/references/users/prune.mdx +++ b/docs/cli/references/users/prune.mdx @@ -1,46 +1,6 @@ # `src users prune` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-days` | Days threshold on which to remove users, must be 60 days or greater and defaults to this value | `60` | -| `-display-users` | display table of users to be deleted by prune | `false` | -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-force` | skips user confirmation step allowing programmatic use | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-remove-admin` | prune admin accounts | `false` | -| `-remove-null-users` | removes users with no last active value | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | - - -## Usage - -``` -Usage of 'src users prune': - -days int - Days threshold on which to remove users, must be 60 days or greater and defaults to this value (default 60) - -display-users - display table of users to be deleted by prune - -dump-requests - Log GraphQL requests and responses to stdout - -force - skips user confirmation step allowing programmatic use - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -remove-admin - prune admin accounts - -remove-null-users - removes users with no last active value - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) +deletes inactive users. This command removes users from a Sourcegraph instance who have been inactive for 60 or more days. Admin accounts are omitted by default. @@ -50,6 +10,23 @@ Examples: $ src users prune -remove-admin -remove-null-users +## Usage +```sh +$ src users prune [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--days` | Days threshold on which to remove users, must be 60 days or greater and defaults to this value | `60`| +| `--display-users` | display table of users to be deleted by prune | `false`| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--force` | skips user confirmation step allowing programmatic use | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--remove-admin` | prune admin accounts | `false`| +| `--remove-null-users` | removes users with no last active value | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/cli/references/users/tag.mdx b/docs/cli/references/users/tag.mdx index 5ec8cd5d2..e4fec504d 100644 --- a/docs/cli/references/users/tag.mdx +++ b/docs/cli/references/users/tag.mdx @@ -1,50 +1,16 @@ # `src users tag` - -## Flags - -| Name | Description | Default Value | -|------|-------------|---------------| -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-remove` | Remove the tag. (default: add the tag | `false` | -| `-tag` | The tag to set on the user. (required) | | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | -| `-user-id` | The ID of the user to tag. (required) | | - - -## Usage - -``` -Usage of 'src users tag': - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -remove - Remove the tag. (default: add the tag - -tag string - The tag to set on the user. (required) - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -user-id string - The ID of the user to tag. (required) +add/remove a tag on a user. Examples: Add a tag "foo" to a user: - $ src users tag -user-id=$(src users get -f '{{.ID}}' -username=alice) -tag=foo + $ src users tag -user-id=$(src users get -f '\{\{.ID\}\}' -username=alice) -tag=foo Remove a tag "foo" to a user: - $ src users tag -user-id=$(src users get -f '{{.ID}}' -username=alice) -remove -tag=foo + $ src users tag -user-id=$(src users get -f '\{\{.ID\}\}' -username=alice) -remove -tag=foo Related examples: @@ -52,7 +18,21 @@ Related examples: $ src users list -tag=foo +## Usage - +```sh +$ src users tag [options] ``` - \ No newline at end of file + +## Flags + +| Name | Description | Default Value | +|------|-------------|---------------| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--remove` | Remove the tag. (default: add the tag) | `false`| +| `--tag` | The tag to set on the user. | ``| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| +| `--user-id` | The ID of the user to tag. | ``| \ No newline at end of file diff --git a/docs/cli/references/version.mdx b/docs/cli/references/version.mdx index 8971177a3..e59c6ffe4 100644 --- a/docs/cli/references/version.mdx +++ b/docs/cli/references/version.mdx @@ -1,41 +1,26 @@ # `src version` +Display and compare the src-cli version against the recommended version for your instance -## Flags +Examples: -| Name | Description | Default Value | -|------|-------------|---------------| -| `-client-only` | If true, only the client version will be printed. | `false` | -| `-dump-requests` | Log GraphQL requests and responses to stdout | `false` | -| `-get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false` | -| `-insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false` | -| `-trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false` | -| `-user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true` | +Get the src-cli version and the Sourcegraph instance's recommended version: +$ src version ## Usage +```sh +$ src version [options] ``` -Usage of 'src version': - -client-only - If true, only the client version will be printed. - -dump-requests - Log GraphQL requests and responses to stdout - -get-curl - Print the curl command for executing this query and exit (WARNING: includes printing your access token!) - -insecure-skip-verify - Skip validation of TLS certificates against trusted chains - -trace - Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing - -user-agent-telemetry - Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph (default true) - -Examples: - - Get the src-cli version and the Sourcegraph instance's recommended version: - - $ src version +## Flags -``` - \ No newline at end of file +| Name | Description | Default Value | +|------|-------------|---------------| +| `--client-only` | If true, only the client version will be printed. | `false`| +| `--dump-requests` | Log GraphQL requests and responses to stdout | `false`| +| `--get-curl` | Print the curl command for executing this query and exit (WARNING: includes printing your access token!) | `false`| +| `--insecure-skip-verify` | Skip validation of TLS certificates against trusted chains | `false`| +| `--trace` | Log the trace ID for requests. See https://docs.sourcegraph.com/admin/observability/tracing | `false`| +| `--user-agent-telemetry` | Include the operating system and architecture in the User-Agent sent with requests to Sourcegraph | `true`| \ No newline at end of file diff --git a/docs/self-hosted/observability/alerts.mdx b/docs/self-hosted/observability/alerts.mdx index 6892d0f3e..49ba3d10c 100644 --- a/docs/self-hosted/observability/alerts.mdx +++ b/docs/self-hosted/observability/alerts.mdx @@ -4340,6 +4340,11 @@ Generated query for critical alert: `max((max(max_over_time(src_conf_client_time **Next steps** +- Treat sustained high searcher traffic as a sign that indexed search is not carrying enough of the search load. Searcher handles unindexed search, so high per-replica traffic usually means queries are not using Zoekt enough. +- Check Zoekt availability, indexing backlog, and indexing errors to make sure repositories are being indexed and served by indexed search. +- Inspect recent search traffic for broad or repeated unindexed queries, especially automated clients or queries against revisions that cannot use indexed search. +- If users often search non-default branches, consider indexing more branches by configuring `search.index.branches` or `search.index.revisions` in site configuration. +- If the traffic is expected and Zoekt indexing is healthy, consider scaling out searcher replicas to reduce per-replica load and search latency. - More help interpreting this metric is available in the [dashboards reference](dashboards#searcher-replica_traffic). - **Silence this alert:** If you are aware of this alert and want to silence notifications for it, add the following to your site configuration and set a reminder to re-evaluate the alert: @@ -6715,6 +6720,102 @@ Generated query for warning alert: `max((sum(increase(src_meteringexporter_queue
+## metering: licensing_credit_usage_notifications_errors_total + +

credit usage notification routine operation errors every 30m

+ +**Descriptions** + +- warning metering: 0+ credit usage notification routine operation errors every 30m + +**Next steps** + +- Failures indicate that site admin credit usage notifications are not being refreshed. +- Check worker logs for credit usage notification monitor failures and Enterprise Portal connectivity issues. +- Learn more about the related dashboard panel in the [dashboards reference](dashboards#metering-licensing_credit_usage_notifications_errors_total). +- **Silence this alert:** If you are aware of this alert and want to silence notifications for it, add the following to your site configuration and set a reminder to re-evaluate the alert: + +```json +"observability.silenceAlerts": [ + "warning_metering_licensing_credit_usage_notifications_errors_total" +] +``` + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Generated query for warning alert: `max((sum(increase(src_licensing_credit_usage_notifications_errors_total{job=~"^worker.*"}[30m]))) > 0)` + +
+ +
+ +## metering: licensing_fast_quota_check_routine_99th_percentile_duration + +

aggregate successful fast quota check probe operation duration distribution over 30m

+ +**Descriptions** + +- warning metering: 30+ aggregate successful fast quota check probe operation duration distribution over 30m for 5m0s + +**Next steps** + +- The 99th percentile probe duration has been above 30 seconds for at least 5 minutes; the probe should normally complete in well under its configured interval (default 1m). +- Check Enterprise Portal latency and worker logs for the `licensing.fast-quota-check` routine. +- Learn more about the related dashboard panel in the [dashboards reference](dashboards#metering-licensing_fast_quota_check_routine_99th_percentile_duration). +- **Silence this alert:** If you are aware of this alert and want to silence notifications for it, add the following to your site configuration and set a reminder to re-evaluate the alert: + +```json +"observability.silenceAlerts": [ + "warning_metering_licensing_fast_quota_check_routine_99th_percentile_duration" +] +``` + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Custom query for warning alert: `max((histogram_quantile(0.99, sum by (le) (rate(src_licensing_fast_quota_check_routine_duration_seconds_bucket{job=~"^worker.*"}[30m])))) > 30)` + +
+ +
+ +## metering: licensing_fast_quota_check_routine_error_rate + +

fast quota check probe operation error rate over 30m

+ +**Descriptions** + +- warning metering: 15%+ fast quota check probe operation error rate over 30m for 5m0s + +**Next steps** + +- The probe failure rate has been at or above 15% over the last 30 minutes for at least 5 consecutive minutes; FastCheckQuota is consistently failing open and quota enforcement is degraded. +- Check worker logs for the `licensing.fast-quota-check` routine and Enterprise Portal connectivity. +- Learn more about the related dashboard panel in the [dashboards reference](dashboards#metering-licensing_fast_quota_check_routine_error_rate). +- **Silence this alert:** If you are aware of this alert and want to silence notifications for it, add the following to your site configuration and set a reminder to re-evaluate the alert: + +```json +"observability.silenceAlerts": [ + "warning_metering_licensing_fast_quota_check_routine_error_rate" +] +``` + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Generated query for warning alert: `max((sum(increase(src_licensing_fast_quota_check_routine_errors_total{job=~"^worker.*"\}[30m])) / (sum(increase(src_licensing_fast_quota_check_routine_total\{job=~"^worker.*"\}[30m])) + sum(increase(src_licensing_fast_quota_check_routine_errors_total\{job=~"^worker.*"}[30m]))) * 100) >= 15)` + +
+ +
+ ## otel-collector: otel_span_refused

spans refused per receiver

diff --git a/docs/self-hosted/observability/dashboards.mdx b/docs/self-hosted/observability/dashboards.mdx index 3be352e0a..956fa91f9 100644 --- a/docs/self-hosted/observability/dashboards.mdx +++ b/docs/self-hosted/observability/dashboards.mdx @@ -18257,6 +18257,11 @@ sum by (code) (rate(searcher_service_request_total{instance=~`${instance:regex}` This graph is the average number of requests per second searcher is experiencing over the last 10 minutes broken down per replica. +Sustained high traffic here is undesirable because it indicates Sourcegraph is +using unindexed searcher requests instead of Zoekt indexed search for a good amount +of the search load. That can increase searcher and gitserver load and cause +broader search reliability or latency problems downstream. + The code is the HTTP Status code. 200 is success. We have a special code "canceled" which is common when doing a large search request and we find enough results before searching all possible repos. @@ -33332,6 +33337,912 @@ sum(increase(src_meteringexporter_queue_metrics_reporter_errors_total{job=~"^wor
+### Metering: Metering: Credit usage notification routine operations + +#### metering: licensing_credit_usage_notifications_total + +

Credit usage notification routine operations every 30m

+ +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100400` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_credit_usage_notifications_total{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_credit_usage_notifications_99th_percentile_duration + +

Aggregate successful credit usage notification routine operation duration distribution over 30m

+ +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100401` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum by (le)(rate(src_licensing_credit_usage_notifications_duration_seconds_bucket{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_credit_usage_notifications_errors_total + +

Credit usage notification routine operation errors every 30m

+ +Refer to the [alerts reference](alerts#metering-licensing_credit_usage_notifications_errors_total) for 1 alert related to this panel. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100402` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_credit_usage_notifications_errors_total{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_credit_usage_notifications_error_rate + +

Credit usage notification routine operation error rate over 30m

+ +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100403` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_credit_usage_notifications_errors_total{job=~"^worker.*"}[30m])) / (sum(increase(src_licensing_credit_usage_notifications_total{job=~"^worker.*"}[30m])) + sum(increase(src_licensing_credit_usage_notifications_errors_total{job=~"^worker.*"}[30m]))) * 100 +``` +
+ +
+ +### Metering: Fast quota check routine (cached, latency-sensitive) + +#### metering: licensing_fast_quota_check_routine_total + +

Fast quota check probe operations every 30m

+ +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100500` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_fast_quota_check_routine_total{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_fast_quota_check_routine_99th_percentile_duration + +

Aggregate successful fast quota check probe operation duration distribution over 30m

+ +Refer to the [alerts reference](alerts#metering-licensing_fast_quota_check_routine_99th_percentile_duration) for 1 alert related to this panel. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100501` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum by (le)(rate(src_licensing_fast_quota_check_routine_duration_seconds_bucket{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_fast_quota_check_routine_errors_total + +

Fast quota check probe operation errors every 30m

+ +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100502` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_fast_quota_check_routine_errors_total{job=~"^worker.*"}[30m])) +``` +
+ +
+ +#### metering: licensing_fast_quota_check_routine_error_rate + +

Fast quota check probe operation error rate over 30m

+ +Refer to the [alerts reference](alerts#metering-licensing_fast_quota_check_routine_error_rate) for 1 alert related to this panel. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100503` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum(increase(src_licensing_fast_quota_check_routine_errors_total{job=~"^worker.*"}[30m])) / (sum(increase(src_licensing_fast_quota_check_routine_total{job=~"^worker.*"}[30m])) + sum(increase(src_licensing_fast_quota_check_routine_errors_total{job=~"^worker.*"}[30m]))) * 100 +``` +
+ +
+ +### Metering: Metering V2 Connect client metrics + +#### metering: metering_v2_success_p99_duration_per_method + +

99th percentile success connect client duration per method over 2m

+ +99th percentile duration of success outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100600` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_success_p95_duration_per_method + +

95th percentile success connect client duration per method over 2m

+ +95th percentile duration of success outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100601` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_success_p90_duration_per_method + +

90th percentile success connect client duration per method over 2m

+ +90th percentile duration of success outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100602` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_failure_p99_duration_per_method + +

99th percentile failure connect client duration per method over 2m

+ +99th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100610` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_failure_p95_duration_per_method + +

95th percentile failure connect client duration per method over 2m

+ +95th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100611` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_failure_p90_duration_per_method + +

90th percentile failure connect client duration per method over 2m

+ +90th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100612` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v2_connect_request_rate_per_method + +

Connect request rate per method over 5m

+ +Rate of outbound Connect calls to enterpriseportal.metering.v2.MeteringService, per method, over a 5 minute window. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100620` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}"}[5m])) +``` +
+ +
+ +#### metering: metering_v2_connect_error_rate_per_method + +

Connect error percentage per method over 2m

+ +Percentage of outbound Connect calls to enterpriseportal.metering.v2.MeteringService that returned a non-OK code, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100630` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +(100 * sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) / sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}"}[2m])) +``` +
+ +
+ +#### metering: metering_v2_connect_error_rate_per_method_by_code + +

Connect error request rate per method and code over 2m

+ +Rate of failing outbound Connect calls to enterpriseportal.metering.v2.MeteringService, broken down by method and connect error code. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100631` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ +#### metering: metering_v2_connect_response_code_distribution + +

Connect response code distribution per method over 2m

+ +Rate of outbound Connect calls to enterpriseportal.metering.v2.MeteringService per method, broken down by rpc_connect_rpc_error_code. Successful calls (which carry no error-code attribute) are normalized to "ok". + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100640` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v2.MeteringService",rpc_method=~"${metering_v2_method:regex}",job=~"${caller:regex}"}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ +### Metering: Metering V1 Connect client metrics + +#### metering: metering_v1_success_p99_duration_per_method + +

99th percentile success connect client duration per method over 2m

+ +99th percentile duration of success outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100700` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_success_p95_duration_per_method + +

95th percentile success connect client duration per method over 2m

+ +95th percentile duration of success outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100701` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_success_p90_duration_per_method + +

90th percentile success connect client duration per method over 2m

+ +90th percentile duration of success outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100702` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_failure_p99_duration_per_method + +

99th percentile failure connect client duration per method over 2m

+ +99th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100710` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_failure_p95_duration_per_method + +

95th percentile failure connect client duration per method over 2m

+ +95th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100711` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_failure_p90_duration_per_method + +

90th percentile failure connect client duration per method over 2m

+ +90th percentile duration of failure outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100712` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: metering_v1_connect_request_rate_per_method + +

Connect request rate per method over 5m

+ +Rate of outbound Connect calls to enterpriseportal.metering.v1.MeteringService, per method, over a 5 minute window. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100720` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}"}[5m])) +``` +
+ +
+ +#### metering: metering_v1_connect_error_rate_per_method + +

Connect error percentage per method over 2m

+ +Percentage of outbound Connect calls to enterpriseportal.metering.v1.MeteringService that returned a non-OK code, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100730` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +(100 * sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) / sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}"}[2m])) +``` +
+ +
+ +#### metering: metering_v1_connect_error_rate_per_method_by_code + +

Connect error request rate per method and code over 2m

+ +Rate of failing outbound Connect calls to enterpriseportal.metering.v1.MeteringService, broken down by method and connect error code. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100731` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ +#### metering: metering_v1_connect_response_code_distribution + +

Connect response code distribution per method over 2m

+ +Rate of outbound Connect calls to enterpriseportal.metering.v1.MeteringService per method, broken down by rpc_connect_rpc_error_code. Successful calls (which carry no error-code attribute) are normalized to "ok". + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100740` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.metering.v1.MeteringService",rpc_method=~"${metering_v1_method:regex}",job=~"${caller:regex}"}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ +### Metering: Broadcast Messages V1 Connect client metrics + +#### metering: broadcast_messages_v1_success_p99_duration_per_method + +

99th percentile success connect client duration per method over 2m

+ +99th percentile duration of success outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100800` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_success_p95_duration_per_method + +

95th percentile success connect client duration per method over 2m

+ +95th percentile duration of success outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100801` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_success_p90_duration_per_method + +

90th percentile success connect client duration per method over 2m

+ +90th percentile duration of success outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100802` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_failure_p99_duration_per_method + +

99th percentile failure connect client duration per method over 2m

+ +99th percentile duration of failure outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100810` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.99, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_failure_p95_duration_per_method + +

95th percentile failure connect client duration per method over 2m

+ +95th percentile duration of failure outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100811` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.95, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_failure_p90_duration_per_method + +

90th percentile failure connect client duration per method over 2m

+ +90th percentile duration of failure outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100812` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +histogram_quantile(0.90, sum by (le, rpc_method) (rate(rpc_client_duration_milliseconds_bucket{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) +``` +
+ +
+ +#### metering: broadcast_messages_v1_connect_request_rate_per_method + +

Connect request rate per method over 5m

+ +Rate of outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, per method, over a 5 minute window. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100820` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}"}[5m])) +``` +
+ +
+ +#### metering: broadcast_messages_v1_connect_error_rate_per_method + +

Connect error percentage per method over 2m

+ +Percentage of outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService that returned a non-OK code, per method. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100830` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +(100 * sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m]))) / sum by (rpc_method) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}"}[2m])) +``` +
+ +
+ +#### metering: broadcast_messages_v1_connect_error_rate_per_method_by_code + +

Connect error request rate per method and code over 2m

+ +Rate of failing outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService, broken down by method and connect error code. + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100831` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}",rpc_connect_rpc_error_code!=""}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ +#### metering: broadcast_messages_v1_connect_response_code_distribution + +

Connect response code distribution per method over 2m

+ +Rate of outbound Connect calls to enterpriseportal.broadcastmessages.v1.BroadcastMessagesService per method, broken down by rpc_connect_rpc_error_code. Successful calls (which carry no error-code attribute) are normalized to "ok". + +This panel has no related alerts. + +To see this panel, visit `/-/debug/grafana/d/metering/metering?viewPanel=100840` on your Sourcegraph instance. + +*Managed by the Sourcegraph Services team.* + +
+Technical details + +Query: + +``` +label_replace(sum by (rpc_method, rpc_connect_rpc_error_code) (rate(rpc_client_duration_milliseconds_count{rpc_service="enterpriseportal.broadcastmessages.v1.BroadcastMessagesService",rpc_method=~"${broadcast_messages_v1_method:regex}",job=~"${caller:regex}"}[2m])), "rpc_connect_rpc_error_code", "ok", "rpc_connect_rpc_error_code", "") +``` +
+ +
+ ## OpenTelemetry Collector

The OpenTelemetry collector ingests OpenTelemetry data from Sourcegraph and exports it to the configured backends.