Skip to content

[Connectors] Fixes Bedrock connector not using the action proxy configuration#224130

Merged
spong merged 13 commits intoelastic:mainfrom
spong:bedrock-proxy
Jun 17, 2025
Merged

[Connectors] Fixes Bedrock connector not using the action proxy configuration#224130
spong merged 13 commits intoelastic:mainfrom
spong:bedrock-proxy

Conversation

@spong
Copy link
Member

@spong spong commented Jun 16, 2025

Summary

Similar to #219617, this PR fixes an issue with the BedrockConnector not using the configured xpack.actions.proxyUrl.

To test, add the following xpack.actions.proxyUrl to your kibana.dev.yml, then create a Bedrock connector and confirm in the Kibana server logs that the configured proxy is being used and a successful response is returned. Sample debug logs look something along the lines of:

[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock] executing action .bedrock:sonnet-3-7: Sonnet 3.7 (Bedrock)
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Request to external service. Connector Id: sonnet-3-7. Connector type: .bedrock Method: post. URL: https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Creating proxy agents for proxy: https://PROXY_URL/

Be sure to enable debug logging for the actions plugin ala:

logging:
  loggers:
    - name: plugins.actions
      level: debug

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

@spong spong self-assigned this Jun 16, 2025
@spong spong requested review from a team as code owners June 16, 2025 19:15
@spong spong added the bug Fixes for quality problems that affect the customer experience label Jun 16, 2025
@spong spong requested a review from a team as a code owner June 16, 2025 19:15
@spong spong added release_note:fix :ml backport:version Backport to applied version labels Team:AI Infra Platform AppEx AI Infrastructure Team t// v9.1.0 v8.19.0 v9.0.3 v8.18.3 labels Jun 16, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@elasticmachine
Copy link
Contributor

Pinging @elastic/appex-ai-infra (Team:AI Infra)

@spong spong requested review from qn895 and stephmilovic June 16, 2025 19:15
@kibanamachine kibanamachine requested a review from a team June 16, 2025 20:49
accessKeyId: this.secrets.accessKey,
secretAccessKey: this.secrets.secret,
},
requestHandler: new NodeHttpHandler(isHttps ? { httpsAgent } : { httpAgent }),
Copy link
Member Author

Choose a reason for hiding this comment

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

Even though the latest docs say you can specify httpAgent via httpOptions, it turns out in these other docs that this was deprecated in the upgrade from v2->v3 and you must now do it via requestHandler, which must be specified via a NodeHttpHandler, hence the new explicit dependency.

Copy link
Member Author

Choose a reason for hiding this comment

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

@elastic/kibana-security, this was previously a transitive dependency of @aws-sdk/client-bedrock-runtime, but since I have to import NodeHttpHandler I needed to explicitly declare it in our package.json:

https://github.com/aws/aws-sdk-js-v3/blob/main/clients/client-bedrock-runtime/package.json#L50

Copy link
Contributor

@stephmilovic stephmilovic left a comment

Choose a reason for hiding this comment

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

Thanks for the fix Garrett!

@spong spong requested a review from a team as a code owner June 17, 2025 02:58
Copy link
Contributor

@elena-shostak elena-shostak left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Contributor

@pmuellr pmuellr left a comment

Choose a reason for hiding this comment

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

I think you need to remove the test for the proxy URL when determining which agent to use.

};
} else if (connectorTypeId === '.bedrock') {
connectorConfig = {
apiUrl: 'https://_face_api_.com',
Copy link
Contributor

Choose a reason for hiding this comment

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

hahahaha ... was wondering what face was here, looking at the original code, thinking this was a copy/pasta of fake that was made previously, and now copied. DO NOT CHANGE, I love it!

Copy link
Member Author

Choose a reason for hiding this comment

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

I debated, haha! 😅

this.url
);
const isHttps = (
this.configurationUtilities.getProxySettings()?.proxyUrl ?? this.url
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think you want the this.configurationUtilities.getProxySettings()?.proxyUrl part, just the this.url part.

You can configure an https proxy to an http server, but as far as the actual connection goes, from the standpoint of the client you are interacting with, it's all http. The https bits are all under the covers ...

And if you try to use an https agent with an http connection, I suspect that will cause problems.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks for the feedback @pmuellr, I hadn't realized! This is resolved in 4b2c64e.

Also cc @e40pud as this is what he did over in https://github.com/elastic/kibana/pull/224129/files#diff-c3049a99b1502b0141a372106e3d0061db506862cbaf77c05657c7d77e794658R90-R93 as well.

Copy link
Contributor

@pmuellr pmuellr left a comment

Choose a reason for hiding this comment

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

LGTM!

@spong spong enabled auto-merge (squash) June 17, 2025 19:35
@spong spong merged commit 321f9a1 into elastic:main Jun 17, 2025
12 checks passed
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.18, 8.19, 9.0

https://github.com/elastic/kibana/actions/runs/15716948876

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

History

cc @spong

@spong spong deleted the bedrock-proxy branch June 17, 2025 20:10
@kibanamachine
Copy link
Contributor

💔 All backports failed

Status Branch Result
8.18 Backport failed because of merge conflicts
8.19 Backport failed because of merge conflicts

You might need to backport the following PRs to 8.19:
- Update dependency diff to v8 (main) (#220898)
9.0 Backport failed because of merge conflicts

Manual backport

To create the backport manually run:

node scripts/backport --pr 224130

Questions ?

Please refer to the Backport tool documentation

spong added a commit to spong/kibana that referenced this pull request Jun 17, 2025
…ration (elastic#224130)

## Summary

Similar to elastic#219617, this PR fixes
an issue with the `BedrockConnector` not using the configured
`xpack.actions.proxyUrl`.

To test, add the following
[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)
to your `kibana.dev.yml`, then create a Bedrock connector and confirm in
the Kibana server logs that the configured proxy is being used and a
successful response is returned. Sample `debug` logs look something
along the lines of:

```
[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock] executing action .bedrock:sonnet-3-7: Sonnet 3.7 (Bedrock)
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Request to external service. Connector Id: sonnet-3-7. Connector type: .bedrock Method: post. URL: https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Creating proxy agents for proxy: https://PROXY_URL/
```

Be sure to enable debug logging for the actions plugin ala:

```
logging:
  loggers:
    - name: plugins.actions
      level: debug
```

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
(cherry picked from commit 321f9a1)

# Conflicts:
#	x-pack/platform/plugins/shared/stack_connectors/server/connector_types/bedrock/bedrock.ts
spong added a commit to spong/kibana that referenced this pull request Jun 17, 2025
…ration (elastic#224130)

## Summary

Similar to elastic#219617, this PR fixes
an issue with the `BedrockConnector` not using the configured
`xpack.actions.proxyUrl`.

To test, add the following
[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)
to your `kibana.dev.yml`, then create a Bedrock connector and confirm in
the Kibana server logs that the configured proxy is being used and a
successful response is returned. Sample `debug` logs look something
along the lines of:

```
[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock] executing action .bedrock:sonnet-3-7: Sonnet 3.7 (Bedrock)
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Request to external service. Connector Id: sonnet-3-7. Connector type: .bedrock Method: post. URL: https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Creating proxy agents for proxy: https://PROXY_URL/
```

Be sure to enable debug logging for the actions plugin ala:

```
logging:
  loggers:
    - name: plugins.actions
      level: debug
```

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
(cherry picked from commit 321f9a1)

# Conflicts:
#	renovate.json
@spong
Copy link
Member Author

spong commented Jun 17, 2025

💚 All backports created successfully

Status Branch Result
9.0
8.19
8.18

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

spong added a commit to spong/kibana that referenced this pull request Jun 17, 2025
…ration (elastic#224130)

## Summary

Similar to elastic#219617, this PR fixes
an issue with the `BedrockConnector` not using the configured
`xpack.actions.proxyUrl`.

To test, add the following
[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)
to your `kibana.dev.yml`, then create a Bedrock connector and confirm in
the Kibana server logs that the configured proxy is being used and a
successful response is returned. Sample `debug` logs look something
along the lines of:

```
[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock] executing action .bedrock:sonnet-3-7: Sonnet 3.7 (Bedrock)
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Request to external service. Connector Id: sonnet-3-7. Connector type: .bedrock Method: post. URL: https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke
[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions] Creating proxy agents for proxy: https://PROXY_URL/
```

Be sure to enable debug logging for the actions plugin ala:

```
logging:
  loggers:
    - name: plugins.actions
      level: debug
```

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
(cherry picked from commit 321f9a1)

# Conflicts:
#	renovate.json
#	x-pack/platform/plugins/shared/stack_connectors/server/connector_types/bedrock/bedrock.ts
spong added a commit that referenced this pull request Jun 17, 2025
…onfiguration (#224130) (#224326)

# Backport

This will backport the following commits from `main` to `9.0`:
- [[Connectors] Fix Bedrock connector not using the action proxy
configuration (#224130)](#224130)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Garrett
Spong","email":"spong@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T20:07:24Z","message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix",":ml","backport:version","Team:AI
Infra","v9.1.0","v8.19.0","v9.0.3","v8.18.3"],"title":"[Connectors] Fix
Bedrock connector not using the action proxy
configuration","number":224130,"url":"https://github.com/elastic/kibana/pull/224130","mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},"sourceBranch":"main","suggestedTargetBranches":["8.19","9.0","8.18"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/224130","number":224130,"mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->
spong added a commit that referenced this pull request Jun 17, 2025
…configuration (#224130) (#224327)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[Connectors] Fix Bedrock connector not using the action proxy
configuration (#224130)](#224130)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Garrett
Spong","email":"spong@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T20:07:24Z","message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix",":ml","backport:version","Team:AI
Infra","v9.1.0","v8.19.0","v9.0.3","v8.18.3"],"title":"[Connectors] Fix
Bedrock connector not using the action proxy
configuration","number":224130,"url":"https://github.com/elastic/kibana/pull/224130","mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},"sourceBranch":"main","suggestedTargetBranches":["8.19","9.0","8.18"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/224130","number":224130,"mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->
spong added a commit that referenced this pull request Jun 17, 2025
…configuration (#224130) (#224328)

# Backport

This will backport the following commits from `main` to `8.18`:
- [[Connectors] Fix Bedrock connector not using the action proxy
configuration (#224130)](#224130)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Garrett
Spong","email":"spong@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T20:07:24Z","message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix",":ml","backport:version","Team:AI
Infra","v9.1.0","v8.19.0","v9.0.3","v8.18.3"],"title":"[Connectors] Fix
Bedrock connector not using the action proxy
configuration","number":224130,"url":"https://github.com/elastic/kibana/pull/224130","mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},"sourceBranch":"main","suggestedTargetBranches":["8.19","9.0","8.18"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/224130","number":224130,"mergeCommit":{"message":"[Connectors]
Fix Bedrock connector not using the action proxy configuration
(#224130)\n\n## Summary\n\nSimilar to
#219617, this PR fixes\nan issue
with the `BedrockConnector` not using the
configured\n`xpack.actions.proxyUrl`.\n\nTo test, add the
following\n[`xpack.actions.proxyUrl`](https://p.elstc.co/paste/DaM71BUP#iHki8gmY4-LZcfQD0ja6HeMHknuvpEvQtSbapcAEOXb)\nto
your `kibana.dev.yml`, then create a Bedrock connector and confirm
in\nthe Kibana server logs that the configured proxy is being used and
a\nsuccessful response is returned. Sample `debug` logs look
something\nalong the lines
of:\n\n\n```\n[2025-06-16T11:59:36.282-06:00][DEBUG][plugins.actions.bedrock]
executing action .bedrock:sonnet-3-7: Sonnet 3.7
(Bedrock)\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Request to external service. Connector Id: sonnet-3-7. Connector type:
.bedrock Method: post. URL:
https://bedrock-runtime.us-east-1.amazonaws.com/model/us.anthropic.claude-3-7-sonnet-20250219-v1%3A0/invoke\n[2025-06-16T11:59:36.286-06:00][DEBUG][plugins.actions]
Creating proxy agents for proxy: https://PROXY_URL/\n```\n\n\nBe sure to
enable debug logging for the actions plugin ala:\n\n```\nlogging:\n
loggers:\n - name: plugins.actions\n level: debug\n```\n\n###
Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers
should verify this PR satisfies this list as well.\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios\n\n---------\n\nCo-authored-by: kibanamachine
<42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Steph
Milovic
<stephanie.milovic@elastic.co>","sha":"321f9a18d4d93bf87ef2b1612edbd571bf0fcb48"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->
@nastasha-solomon nastasha-solomon changed the title [Connectors] Fix Bedrock connector not using the action proxy configuration Jun 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels bug Fixes for quality problems that affect the customer experience :ml release_note:fix Team:AI Infra Platform AppEx AI Infrastructure Team t// v8.18.3 v8.19.0 v9.0.3 v9.1.0

7 participants