Skip to content

feat(server): add support to ignore unknown tools at startup#3353

Merged
drstrangelooker merged 7 commits into
googleapis:mainfrom
pushkar0108:feat/sources-looker-optional-tools
Jun 4, 2026
Merged

feat(server): add support to ignore unknown tools at startup#3353
drstrangelooker merged 7 commits into
googleapis:mainfrom
pushkar0108:feat/sources-looker-optional-tools

Conversation

@pushkar0108

Copy link
Copy Markdown
Contributor

Introduce a new --ignore-unknown-tools command line flag. When enabled, Toolbox will log warnings and skip unknown/unsupported tool types instead of failing to start. It also filters skipped tools out of configured toolsets.

Description

  • Add IgnoreUnknownTools to ServerConfig
  • Register --ignore-unknown-tools command line flag
  • Update tools.DecodeConfig to return ErrUnknownToolType on unknown types
  • Skip nil tool configs in UnmarshalResourceConfig
  • Filter out unknown tools from toolset configurations in InitializeConfigs
  • Add unit test coverage in cmd/root_test.go

🛠️ Fixes #3352

Introduce a new --ignore-unknown-tools command line flag. When enabled,
Toolbox will log warnings and skip unknown/unsupported tool types instead
of failing to start. It also filters skipped tools out of configured toolsets.

- Add IgnoreUnknownTools to ServerConfig
- Register --ignore-unknown-tools command line flag
- Update tools.DecodeConfig to return ErrUnknownToolType on unknown types
- Skip nil tool configs in UnmarshalResourceConfig
- Filter out unknown tools from toolset configurations in InitializeConfigs
- Add unit test coverage in cmd/root_test.go
@pushkar0108 pushkar0108 requested a review from a team as a code owner June 4, 2026 10:20

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new CLI flag --ignore-unknown-tools to allow the MCP Toolbox to log warnings and skip unknown or unsupported tool types instead of failing to start. It also updates toolset initialization to filter out missing tools when this flag is enabled, adds documentation, and includes integration tests. Feedback on the changes suggests pre-allocating the filteredToolNames slice in internal/server/server.go to optimize performance, and improving the new integration test in cmd/root_test.go by using a random port (--port 0) to prevent flakiness and asserting that the expected warning log is emitted.

Comment thread internal/server/server.go
Comment thread cmd/root_test.go
@pushkar0108 pushkar0108 force-pushed the feat/sources-looker-optional-tools branch from 2a61b1e to bb15a88 Compare June 4, 2026 11:42
@drstrangelooker

Copy link
Copy Markdown
Contributor

/gcbrun

@averikitsch averikitsch assigned Yuan325 and unassigned duwenxin99 Jun 4, 2026
@drstrangelooker

Copy link
Copy Markdown
Contributor

/gcbrun

@drstrangelooker drstrangelooker enabled auto-merge (squash) June 4, 2026 17:46
@Yuan325 Yuan325 added the release candidate Use label to signal PR should be included in the next release. label Jun 4, 2026
@drstrangelooker

Copy link
Copy Markdown
Contributor

/gcbrun

@drstrangelooker

Copy link
Copy Markdown
Contributor

/gcbrun

@drstrangelooker drstrangelooker merged commit 5f0304f into googleapis:main Jun 4, 2026
27 checks passed
github-actions Bot pushed a commit that referenced this pull request Jun 4, 2026
…3353)

Introduce a new --ignore-unknown-tools command line flag. When enabled,
Toolbox will log warnings and skip unknown/unsupported tool types
instead of failing to start. It also filters skipped tools out of
configured toolsets.

## Description

- Add IgnoreUnknownTools to ServerConfig
- Register --ignore-unknown-tools command line flag
- Update tools.DecodeConfig to return ErrUnknownToolType on unknown
types
- Skip nil tool configs in UnmarshalResourceConfig
- Filter out unknown tools from toolset configurations in
InitializeConfigs
- Add unit test coverage in cmd/root_test.go

🛠️ Fixes #3352

---------

Co-authored-by: Mike DeAngelo <drstrangelove@google.com> 5f0304f
github-actions Bot pushed a commit to renovate-bot/googleapis-_-genai-toolbox that referenced this pull request Jun 4, 2026
…oogleapis#3353)

Introduce a new --ignore-unknown-tools command line flag. When enabled,
Toolbox will log warnings and skip unknown/unsupported tool types
instead of failing to start. It also filters skipped tools out of
configured toolsets.

## Description

- Add IgnoreUnknownTools to ServerConfig
- Register --ignore-unknown-tools command line flag
- Update tools.DecodeConfig to return ErrUnknownToolType on unknown
types
- Skip nil tool configs in UnmarshalResourceConfig
- Filter out unknown tools from toolset configurations in
InitializeConfigs
- Add unit test coverage in cmd/root_test.go

🛠️ Fixes googleapis#3352

---------

Co-authored-by: Mike DeAngelo <drstrangelove@google.com> 5f0304f
Yuan325 added a commit that referenced this pull request Jun 4, 2026
🤖 I have created a release *beep* *boop*
---


##
[1.4.0](v1.3.0...v1.4.0)
(2026-06-04)


### Features

* **ci:** Add support for windows/arm64 binary distribution
([#3231](#3231))
([10abf3b](10abf3b))
* **datalineage:** Add Data Lineage integration
([#3285](#3285))
([19353c3](19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([#3353](#3353))
([5f0304f](5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([#3203](#3203))
([b514cbd](b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([#3140](#3140))
([defc086](defc086))


### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([#3360](#3360))
([1d8df0d](1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([#3341](#3341))
([dfd66ee](dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([#3300](#3300))
([9a88c72](9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([#3215](#3215))
([fcad02d](fcad02d))
* **server/auth:** Centralize tool scopes validation
([#3335](#3335))
([adce4ab](adce4ab))
* **server:** Return null id for batch request rejection
([#3333](#3333))
([0b18d58](0b18d58))
* **source/dataplex:** Limit search results to pageSize
([#3323](#3323))
([905c1f6](905c1f6)),
closes [#3308](#3308)
* **telemetry:** Allow GCP project override
([#2960](#2960))
([3c83ba5](3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([#3324](#3324))
([45df461](45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([#3340](#3340))
([ddfd887](ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([#3219](#3219))
([2f45f75](2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([#3289](#3289))
([1711156](1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com>
github-actions Bot pushed a commit that referenced this pull request Jun 4, 2026
🤖 I have created a release *beep* *boop*
---

##
[1.4.0](v1.3.0...v1.4.0)
(2026-06-04)

### Features

* **ci:** Add support for windows/arm64 binary distribution
([#3231](#3231))
([10abf3b](10abf3b))
* **datalineage:** Add Data Lineage integration
([#3285](#3285))
([19353c3](19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([#3353](#3353))
([5f0304f](5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([#3203](#3203))
([b514cbd](b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([#3140](#3140))
([defc086](defc086))

### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([#3360](#3360))
([1d8df0d](1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([#3341](#3341))
([dfd66ee](dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([#3300](#3300))
([9a88c72](9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([#3215](#3215))
([fcad02d](fcad02d))
* **server/auth:** Centralize tool scopes validation
([#3335](#3335))
([adce4ab](adce4ab))
* **server:** Return null id for batch request rejection
([#3333](#3333))
([0b18d58](0b18d58))
* **source/dataplex:** Limit search results to pageSize
([#3323](#3323))
([905c1f6](905c1f6)),
closes [#3308](#3308)
* **telemetry:** Allow GCP project override
([#2960](#2960))
([3c83ba5](3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([#3324](#3324))
([45df461](45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([#3340](#3340))
([ddfd887](ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([#3219](#3219))
([2f45f75](2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([#3289](#3289))
([1711156](1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com> d67cfbe
github-actions Bot pushed a commit to renovate-bot/googleapis-_-genai-toolbox that referenced this pull request Jun 4, 2026
🤖 I have created a release *beep* *boop*
---

##
[1.4.0](googleapis/mcp-toolbox@v1.3.0...v1.4.0)
(2026-06-04)

### Features

* **ci:** Add support for windows/arm64 binary distribution
([googleapis#3231](googleapis#3231))
([10abf3b](googleapis@10abf3b))
* **datalineage:** Add Data Lineage integration
([googleapis#3285](googleapis#3285))
([19353c3](googleapis@19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([googleapis#3353](googleapis#3353))
([5f0304f](googleapis@5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([googleapis#3203](googleapis#3203))
([b514cbd](googleapis@b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([googleapis#3140](googleapis#3140))
([defc086](googleapis@defc086))

### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([googleapis#3360](googleapis#3360))
([1d8df0d](googleapis@1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([googleapis#3341](googleapis#3341))
([dfd66ee](googleapis@dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([googleapis#3300](googleapis#3300))
([9a88c72](googleapis@9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([googleapis#3215](googleapis#3215))
([fcad02d](googleapis@fcad02d))
* **server/auth:** Centralize tool scopes validation
([googleapis#3335](googleapis#3335))
([adce4ab](googleapis@adce4ab))
* **server:** Return null id for batch request rejection
([googleapis#3333](googleapis#3333))
([0b18d58](googleapis@0b18d58))
* **source/dataplex:** Limit search results to pageSize
([googleapis#3323](googleapis#3323))
([905c1f6](googleapis@905c1f6)),
closes [googleapis#3308](googleapis#3308)
* **telemetry:** Allow GCP project override
([googleapis#2960](googleapis#2960))
([3c83ba5](googleapis@3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([googleapis#3324](googleapis#3324))
([45df461](googleapis@45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([googleapis#3340](googleapis#3340))
([ddfd887](googleapis@ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([googleapis#3219](googleapis#3219))
([2f45f75](googleapis@2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([googleapis#3289](googleapis#3289))
([1711156](googleapis@1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com> d67cfbe
github-actions Bot pushed a commit to rodineyw/mcp-toolbox that referenced this pull request Jun 4, 2026
🤖 I have created a release *beep* *boop*
---

##
[1.4.0](googleapis/mcp-toolbox@v1.3.0...v1.4.0)
(2026-06-04)

### Features

* **ci:** Add support for windows/arm64 binary distribution
([googleapis#3231](googleapis#3231))
([10abf3b](googleapis@10abf3b))
* **datalineage:** Add Data Lineage integration
([googleapis#3285](googleapis#3285))
([19353c3](googleapis@19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([googleapis#3353](googleapis#3353))
([5f0304f](googleapis@5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([googleapis#3203](googleapis#3203))
([b514cbd](googleapis@b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([googleapis#3140](googleapis#3140))
([defc086](googleapis@defc086))

### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([googleapis#3360](googleapis#3360))
([1d8df0d](googleapis@1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([googleapis#3341](googleapis#3341))
([dfd66ee](googleapis@dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([googleapis#3300](googleapis#3300))
([9a88c72](googleapis@9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([googleapis#3215](googleapis#3215))
([fcad02d](googleapis@fcad02d))
* **server/auth:** Centralize tool scopes validation
([googleapis#3335](googleapis#3335))
([adce4ab](googleapis@adce4ab))
* **server:** Return null id for batch request rejection
([googleapis#3333](googleapis#3333))
([0b18d58](googleapis@0b18d58))
* **source/dataplex:** Limit search results to pageSize
([googleapis#3323](googleapis#3323))
([905c1f6](googleapis@905c1f6)),
closes [googleapis#3308](googleapis#3308)
* **telemetry:** Allow GCP project override
([googleapis#2960](googleapis#2960))
([3c83ba5](googleapis@3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([googleapis#3324](googleapis#3324))
([45df461](googleapis@45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([googleapis#3340](googleapis#3340))
([ddfd887](googleapis@ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([googleapis#3219](googleapis#3219))
([2f45f75](googleapis@2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([googleapis#3289](googleapis#3289))
([1711156](googleapis@1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com> d67cfbe
github-actions Bot pushed a commit to Jaleel-zhu/genai-toolbox that referenced this pull request Jun 4, 2026
🤖 I have created a release *beep* *boop*
---

##
[1.4.0](googleapis/mcp-toolbox@v1.3.0...v1.4.0)
(2026-06-04)

### Features

* **ci:** Add support for windows/arm64 binary distribution
([googleapis#3231](googleapis#3231))
([10abf3b](googleapis@10abf3b))
* **datalineage:** Add Data Lineage integration
([googleapis#3285](googleapis#3285))
([19353c3](googleapis@19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([googleapis#3353](googleapis#3353))
([5f0304f](googleapis@5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([googleapis#3203](googleapis#3203))
([b514cbd](googleapis@b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([googleapis#3140](googleapis#3140))
([defc086](googleapis@defc086))

### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([googleapis#3360](googleapis#3360))
([1d8df0d](googleapis@1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([googleapis#3341](googleapis#3341))
([dfd66ee](googleapis@dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([googleapis#3300](googleapis#3300))
([9a88c72](googleapis@9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([googleapis#3215](googleapis#3215))
([fcad02d](googleapis@fcad02d))
* **server/auth:** Centralize tool scopes validation
([googleapis#3335](googleapis#3335))
([adce4ab](googleapis@adce4ab))
* **server:** Return null id for batch request rejection
([googleapis#3333](googleapis#3333))
([0b18d58](googleapis@0b18d58))
* **source/dataplex:** Limit search results to pageSize
([googleapis#3323](googleapis#3323))
([905c1f6](googleapis@905c1f6)),
closes [googleapis#3308](googleapis#3308)
* **telemetry:** Allow GCP project override
([googleapis#2960](googleapis#2960))
([3c83ba5](googleapis@3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([googleapis#3324](googleapis#3324))
([45df461](googleapis@45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([googleapis#3340](googleapis#3340))
([ddfd887](googleapis@ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([googleapis#3219](googleapis#3219))
([2f45f75](googleapis@2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([googleapis#3289](googleapis#3289))
([1711156](googleapis@1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com> d67cfbe
github-actions Bot pushed a commit to pepe57/genai-toolbox that referenced this pull request Jun 5, 2026
🤖 I have created a release *beep* *boop*
---

##
[1.4.0](googleapis/mcp-toolbox@v1.3.0...v1.4.0)
(2026-06-04)

### Features

* **ci:** Add support for windows/arm64 binary distribution
([googleapis#3231](googleapis#3231))
([10abf3b](googleapis@10abf3b))
* **datalineage:** Add Data Lineage integration
([googleapis#3285](googleapis#3285))
([19353c3](googleapis@19353c3))
* **server:** Ignore unknown tools at startup with
`--ignore-unknown-tools` flag
([googleapis#3353](googleapis#3353))
([5f0304f](googleapis@5f0304f))
* **tools/cloudsqlpg:** Add remaining vector assist tools for Cloud SQL
Postgres
([googleapis#3203](googleapis#3203))
([b514cbd](googleapis@b514cbd))
* **tools/spanner-search-catalog:** Implement search_catalog tool
([googleapis#3140](googleapis#3140))
([defc086](googleapis@defc086))

### Bug Fixes

* **auth/generic:** Enforce issuer presence in opaque token validation
([googleapis#3360](googleapis#3360))
([1d8df0d](googleapis@1d8df0d))
* **auth:** Separate Google and Generic MCP OAuth verification
([googleapis#3341](googleapis#3341))
([dfd66ee](googleapis@dfd66ee))
* **mcp:** Support annotations and metadata within Tools to earlier MCP
schemas ([googleapis#3300](googleapis#3300))
([9a88c72](googleapis@9a88c72))
* **oracle:** Remove trailing semicolons from prebuilt tools
([googleapis#3215](googleapis#3215))
([fcad02d](googleapis@fcad02d))
* **server/auth:** Centralize tool scopes validation
([googleapis#3335](googleapis#3335))
([adce4ab](googleapis@adce4ab))
* **server:** Return null id for batch request rejection
([googleapis#3333](googleapis#3333))
([0b18d58](googleapis@0b18d58))
* **source/dataplex:** Limit search results to pageSize
([googleapis#3323](googleapis#3323))
([905c1f6](googleapis@905c1f6)),
closes [googleapis#3308](googleapis#3308)
* **telemetry:** Allow GCP project override
([googleapis#2960](googleapis#2960))
([3c83ba5](googleapis@3c83ba5))
* **tool/bigquery:** Prevent `allowedDatasets` bypass in forecast query
([googleapis#3324](googleapis#3324))
([45df461](googleapis@45df461))
* **tool/clickhouse:** Handle ignored ProcessParameters error
([googleapis#3340](googleapis#3340))
([ddfd887](googleapis@ddfd887))
* **tools/clickhouse,tools/bigquery:** Validate identifier parameters to
prevent injection
([googleapis#3219](googleapis#3219))
([2f45f75](googleapis@2f45f75))
* **tools/looker:** Escape filter values for unquoted parameters
([googleapis#3289](googleapis#3289))
([1711156](googleapis@1711156))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Yuan Teoh <45984206+Yuan325@users.noreply.github.com> d67cfbe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release candidate Use label to signal PR should be included in the next release.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support to ignore unknown tools at startup

4 participants