Skip to content

Commit

Permalink
fix: update DSM id in workspace (#6650) (#6652)
Browse files Browse the repository at this point in the history
(cherry picked from commit 857f8cb)

Signed-off-by: tygao <tygao@amazon.com>
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
1 parent fcd2d72 commit fcc06de
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/plugins/data_source_management/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export interface DataSourceManagementPluginStart {
getAuthenticationMethodRegistry: () => IAuthenticationMethodRegistry;
}

// src/plugins/workspace/public/plugin.ts Workspace depends on this ID and hard code to avoid adding dependency on DSM bundle.
export const DSM_APP_ID = 'dataSources';

export class DataSourceManagementPlugin
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/workspace/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export class WorkspacePlugin implements Plugin<{}, {}, WorkspacePluginSetupDeps>
this.managementCurrentWorkspaceIdSubscription = currentWorkspaceId$.subscribe(
(currentWorkspaceId) => {
if (currentWorkspaceId) {
['settings', 'dataSourceManagement'].forEach((appId) =>
['settings', 'dataSources'].forEach((appId) =>
management.sections.section.opensearchDashboards.getApp(appId)?.disable()
);
}
Expand Down

0 comments on commit fcc06de

Please sign in to comment.