Skip to content

Commit 198d2c9

Browse files
refactor: Move aws services in to src/awsService/ (aws#5253)
* refactor: start moving services to `awsService` Problem: We have multiple aws services that each have their own folder in the root. This adds more folder to have to search through in the top level Solution: Create an `awsService` folder and start the move of the existing folders in to them. This commit moves CDK for now, and in future commits we will move the rest. Signed-off-by: Nikolas Komonen <[email protected]> * refactor: move cloudWatchLogs in to awsService Signed-off-by: Nikolas Komonen <[email protected]> * refactor: ec2 in to awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: ecr -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: apiGateway -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: ecs -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: iot -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: redshift -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: s3 -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: apprunner -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> * refactor: accessanalyzer -> awsService/ Signed-off-by: Nikolas Komonen <[email protected]> --------- Signed-off-by: Nikolas Komonen <[email protected]>
1 parent 9067548 commit 198d2c9

File tree

226 files changed

+1153
-1130
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

226 files changed

+1153
-1130
lines changed

packages/core/src/accessanalyzer/activation.ts renamed to packages/core/src/awsService/accessanalyzer/activation.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
import { ExtContext } from '../shared/extensions'
7-
import { Commands } from '../shared/vscode/commands2'
6+
import { ExtContext } from '../../shared/extensions'
7+
import { Commands } from '../../shared/vscode/commands2'
88
import { renderIamPolicyChecks } from './vue/iamPolicyChecks'
99

1010
/**

packages/core/src/accessanalyzer/vue/constants.ts renamed to packages/core/src/awsService/accessanalyzer/vue/constants.ts

File renamed without changes.

packages/core/src/accessanalyzer/vue/iamPolicyChecks.ts renamed to packages/core/src/awsService/accessanalyzer/vue/iamPolicyChecks.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,16 @@
66
import * as vscode from 'vscode'
77
import * as fs from 'fs'
88
import * as path from 'path'
9-
import { getLogger, Logger } from '../../shared/logger'
10-
import { localize } from '../../shared/utilities/vsCodeUtils'
11-
import { VueWebview } from '../../webviews/main'
12-
import { ExtContext } from '../../shared/extensions'
13-
import { telemetry } from '../../shared/telemetry/telemetry'
9+
import { getLogger, Logger } from '../../../shared/logger'
10+
import { localize } from '../../../shared/utilities/vsCodeUtils'
11+
import { VueWebview } from '../../../webviews/main'
12+
import { ExtContext } from '../../../shared/extensions'
13+
import { telemetry } from '../../../shared/telemetry/telemetry'
1414
import { AccessAnalyzer, SharedIniFileCredentials } from 'aws-sdk'
1515
import { execFileSync } from 'child_process'
16-
import { ToolkitError } from '../../shared/errors'
17-
import { makeTemporaryToolkitFolder, tryRemoveFolder } from '../../shared/filesystemUtilities'
18-
import { globals } from '../../shared'
16+
import { ToolkitError } from '../../../shared/errors'
17+
import { makeTemporaryToolkitFolder, tryRemoveFolder } from '../../../shared/filesystemUtilities'
18+
import { globals } from '../../../shared'
1919
import {
2020
IamPolicyChecksConstants,
2121
PolicyChecksCheckType,
@@ -26,7 +26,7 @@ import {
2626
PolicyChecksUiClick,
2727
ValidatePolicyFindingType,
2828
} from './constants'
29-
import { DefaultS3Client, parseS3Uri } from '../../shared/clients/s3Client'
29+
import { DefaultS3Client, parseS3Uri } from '../../../shared/clients/s3Client'
3030
import { ExpiredTokenException } from '@aws-sdk/client-sso-oidc'
3131

3232
const defaultTerraformConfigPath = 'resources/policychecks-tf-default.yaml'

packages/core/src/accessanalyzer/vue/iamPolicyChecks.vue renamed to packages/core/src/awsService/accessanalyzer/vue/iamPolicyChecks.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,8 +331,8 @@
331331

332332
<script lang="ts">
333333
import { defineComponent } from 'vue'
334-
import { WebviewClientFactory } from '../../webviews/client'
335-
import saveData from '../../webviews/mixins/saveData'
334+
import { WebviewClientFactory } from '../../../webviews/client'
335+
import saveData from '../../../webviews/mixins/saveData'
336336
import { IamPolicyChecksWebview } from './iamPolicyChecks'
337337
import { PolicyChecksDocumentType, PolicyChecksPolicyType } from './constants'
338338
import '@../../../resources/css/base.css'
File renamed without changes.

packages/core/src/apigateway/activation.ts renamed to packages/core/src/awsService/apigateway/activation.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import * as vscode from 'vscode'
77
import { RestApiNode } from './explorer/apiNodes'
88
import { invokeRemoteRestApi } from './vue/invokeRemoteRestApi'
99
import { copyUrlCommand } from './commands/copyUrl'
10-
import { ExtContext } from '../shared/extensions'
11-
import { Commands } from '../shared/vscode/commands2'
10+
import { ExtContext } from '../../shared/extensions'
11+
import { Commands } from '../../shared/vscode/commands2'
1212

1313
/**
1414
* Activate API Gateway functionality for the extension.

packages/core/src/apigateway/commands/copyUrl.ts renamed to packages/core/src/awsService/apigateway/commands/copyUrl.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
import { copyToClipboard } from '../../shared/utilities/messages'
6+
import { copyToClipboard } from '../../../shared/utilities/messages'
77
import * as nls from 'vscode-nls'
88
const localize = nls.loadMessageBundle()
99
import { RestApiNode } from '../explorer/apiNodes'
10-
import * as picker from '../../shared/ui/picker'
10+
import * as picker from '../../../shared/ui/picker'
1111
import * as vscode from 'vscode'
1212
import { ProgressLocation } from 'vscode'
1313

1414
import { Stage } from 'aws-sdk/clients/apigateway'
15-
import { DefaultApiGatewayClient } from '../../shared/clients/apiGatewayClient'
16-
import { defaultDnsSuffix, RegionProvider } from '../../shared/regions/regionProvider'
17-
import { getLogger } from '../../shared/logger'
18-
import { telemetry } from '../../shared/telemetry/telemetry'
15+
import { DefaultApiGatewayClient } from '../../../shared/clients/apiGatewayClient'
16+
import { defaultDnsSuffix, RegionProvider } from '../../../shared/regions/regionProvider'
17+
import { getLogger } from '../../../shared/logger'
18+
import { telemetry } from '../../../shared/telemetry/telemetry'
1919

2020
interface StageInvokeUrlQuickPick extends vscode.QuickPickItem {
2121
// override declaration so this can't be undefined

packages/core/src/apigateway/explorer/apiGatewayNodes.ts renamed to packages/core/src/awsService/apigateway/explorer/apiGatewayNodes.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ const localize = nls.loadMessageBundle()
88

99
import * as vscode from 'vscode'
1010

11-
import { AWSTreeNodeBase } from '../../shared/treeview/nodes/awsTreeNodeBase'
12-
import { PlaceholderNode } from '../../shared/treeview/nodes/placeholderNode'
13-
import { compareTreeItems, makeChildrenNodes } from '../../shared/treeview/utils'
14-
import { DefaultApiGatewayClient } from '../../shared/clients/apiGatewayClient'
11+
import { AWSTreeNodeBase } from '../../../shared/treeview/nodes/awsTreeNodeBase'
12+
import { PlaceholderNode } from '../../../shared/treeview/nodes/placeholderNode'
13+
import { compareTreeItems, makeChildrenNodes } from '../../../shared/treeview/utils'
14+
import { DefaultApiGatewayClient } from '../../../shared/clients/apiGatewayClient'
1515
import { RestApi } from 'aws-sdk/clients/apigateway'
16-
import { toArrayAsync, toMap, updateInPlace } from '../../shared/utilities/collectionUtils'
16+
import { toArrayAsync, toMap, updateInPlace } from '../../../shared/utilities/collectionUtils'
1717
import { RestApiNode } from './apiNodes'
1818

1919
/**

packages/core/src/apigateway/explorer/apiNodes.ts renamed to packages/core/src/awsService/apigateway/explorer/apiNodes.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
import { AWSResourceNode } from '../../shared/treeview/nodes/awsResourceNode'
7-
import { AWSTreeNodeBase } from '../../shared/treeview/nodes/awsTreeNodeBase'
6+
import { AWSResourceNode } from '../../../shared/treeview/nodes/awsResourceNode'
7+
import { AWSTreeNodeBase } from '../../../shared/treeview/nodes/awsTreeNodeBase'
88
import { RestApi } from 'aws-sdk/clients/apigateway'
99

1010
export class RestApiNode extends AWSTreeNodeBase implements AWSResourceNode {
File renamed without changes.

0 commit comments

Comments
 (0)