Skip to content

Commit

Permalink
adding tenantId for inline connector in model registration (#3531)
Browse files Browse the repository at this point in the history
Signed-off-by: Dhrubo Saha <[email protected]>
(cherry picked from commit d224d7a)
  • Loading branch information
dhrubo-os authored and github-actions[bot] committed Feb 12, 2025
1 parent f9a8a70 commit 2262f99
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ private void doRegister(MLRegisterModelInput registerModelInput, ActionListener<
log.error(e.getMessage(), e);
listener.onFailure(e);
});
MLCreateConnectorRequest mlCreateConnectorRequest = createDryRunConnectorRequest();
MLCreateConnectorRequest mlCreateConnectorRequest = createDryRunConnectorRequest(registerModelInput.getTenantId());
client.execute(MLCreateConnectorAction.INSTANCE, mlCreateConnectorRequest, dryRunResultListener);
}
} else {
Expand All @@ -339,8 +339,9 @@ private void createModelGroup(MLRegisterModelInput registerModelInput, ActionLis
}
}

private MLCreateConnectorRequest createDryRunConnectorRequest() {
private MLCreateConnectorRequest createDryRunConnectorRequest(final String tenantId) {
MLCreateConnectorInput createConnectorInput = MLCreateConnectorInput.builder().dryRun(true).build();
createConnectorInput.setTenantId(tenantId);
return new MLCreateConnectorRequest(createConnectorInput);
}

Expand Down

0 comments on commit 2262f99

Please sign in to comment.