@openshift-migration-advisor/agent-sdk 0.16.0 → 0.17.0-a72771aca4b0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/.openapi-generator/FILES +10 -0
  2. package/README.md +14 -9
  3. package/dist/apis/DefaultApi.d.ts +74 -85
  4. package/dist/apis/DefaultApi.js +80 -86
  5. package/dist/esm/apis/DefaultApi.d.ts +74 -85
  6. package/dist/esm/apis/DefaultApi.js +80 -86
  7. package/dist/esm/models/BatchUpdateExclusionRequest.d.ts +38 -0
  8. package/dist/esm/models/BatchUpdateExclusionRequest.js +47 -0
  9. package/dist/esm/models/CollectorStartRequest.d.ts +12 -12
  10. package/dist/esm/models/CollectorStartRequest.js +5 -11
  11. package/dist/esm/models/Datastore.js +1 -1
  12. package/dist/esm/models/ExportInventory400Response.d.ts +32 -0
  13. package/dist/esm/models/ExportInventory400Response.js +41 -0
  14. package/dist/esm/models/ExportInventory500Response.d.ts +32 -0
  15. package/dist/esm/models/ExportInventory500Response.js +41 -0
  16. package/dist/esm/models/Host.js +3 -3
  17. package/dist/esm/models/IssuesBreakdown.d.ts +56 -0
  18. package/dist/esm/models/IssuesBreakdown.js +59 -0
  19. package/dist/esm/models/OsInfo.d.ts +16 -0
  20. package/dist/esm/models/OsInfo.js +11 -0
  21. package/dist/esm/models/Process.d.ts +38 -0
  22. package/dist/esm/models/Process.js +45 -0
  23. package/dist/esm/models/VMs.d.ts +7 -0
  24. package/dist/esm/models/VMs.js +3 -0
  25. package/dist/esm/models/VirtualMachineDetail.d.ts +7 -0
  26. package/dist/esm/models/VirtualMachineDetail.js +3 -0
  27. package/dist/esm/models/index.d.ts +5 -0
  28. package/dist/esm/models/index.js +5 -0
  29. package/dist/esm/runtime.d.ts +1 -0
  30. package/dist/esm/runtime.js +4 -0
  31. package/dist/models/BatchUpdateExclusionRequest.d.ts +38 -0
  32. package/dist/models/BatchUpdateExclusionRequest.js +54 -0
  33. package/dist/models/CollectorStartRequest.d.ts +12 -12
  34. package/dist/models/CollectorStartRequest.js +5 -11
  35. package/dist/models/Datastore.js +1 -1
  36. package/dist/models/ExportInventory400Response.d.ts +32 -0
  37. package/dist/models/ExportInventory400Response.js +48 -0
  38. package/dist/models/ExportInventory500Response.d.ts +32 -0
  39. package/dist/models/ExportInventory500Response.js +48 -0
  40. package/dist/models/Host.js +3 -3
  41. package/dist/models/IssuesBreakdown.d.ts +56 -0
  42. package/dist/models/IssuesBreakdown.js +66 -0
  43. package/dist/models/OsInfo.d.ts +16 -0
  44. package/dist/models/OsInfo.js +12 -0
  45. package/dist/models/Process.d.ts +38 -0
  46. package/dist/models/Process.js +52 -0
  47. package/dist/models/VMs.d.ts +7 -0
  48. package/dist/models/VMs.js +3 -0
  49. package/dist/models/VirtualMachineDetail.d.ts +7 -0
  50. package/dist/models/VirtualMachineDetail.js +3 -0
  51. package/dist/models/index.d.ts +5 -0
  52. package/dist/models/index.js +5 -0
  53. package/dist/runtime.d.ts +1 -0
  54. package/dist/runtime.js +5 -0
  55. package/docs/BatchUpdateExclusionRequest.md +36 -0
  56. package/docs/CollectorStartRequest.md +3 -2
  57. package/docs/DefaultApi.md +139 -139
  58. package/docs/ExportInventory400Response.md +34 -0
  59. package/docs/ExportInventory500Response.md +34 -0
  60. package/docs/IssuesBreakdown.md +42 -0
  61. package/docs/OsInfo.md +2 -0
  62. package/docs/Process.md +36 -0
  63. package/docs/VMs.md +2 -0
  64. package/docs/VirtualMachineDetail.md +2 -0
  65. package/package.json +1 -1
  66. package/src/apis/DefaultApi.ts +159 -159
  67. package/src/models/BatchUpdateExclusionRequest.ts +75 -0
  68. package/src/models/CollectorStartRequest.ts +17 -20
  69. package/src/models/Datastore.ts +1 -1
  70. package/src/models/ExportInventory400Response.ts +65 -0
  71. package/src/models/ExportInventory500Response.ts +65 -0
  72. package/src/models/Host.ts +3 -3
  73. package/src/models/IssuesBreakdown.ts +102 -0
  74. package/src/models/OsInfo.ts +21 -0
  75. package/src/models/Process.ts +74 -0
  76. package/src/models/VMs.ts +15 -0
  77. package/src/models/VirtualMachineDetail.ts +15 -0
  78. package/src/models/index.ts +5 -0
  79. package/src/runtime.ts +5 -0
  80. package/tsconfig.json +1 -1
@@ -0,0 +1,65 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Assisted Migration Agent API
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: v1
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime.js';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface ExportInventory500Response
20
+ */
21
+ export interface ExportInventory500Response {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof ExportInventory500Response
26
+ */
27
+ error?: string;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the ExportInventory500Response interface.
32
+ */
33
+ export function instanceOfExportInventory500Response(value: object): value is ExportInventory500Response {
34
+ return true;
35
+ }
36
+
37
+ export function ExportInventory500ResponseFromJSON(json: any): ExportInventory500Response {
38
+ return ExportInventory500ResponseFromJSONTyped(json, false);
39
+ }
40
+
41
+ export function ExportInventory500ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExportInventory500Response {
42
+ if (json == null) {
43
+ return json;
44
+ }
45
+ return {
46
+
47
+ 'error': json['error'] == null ? undefined : json['error'],
48
+ };
49
+ }
50
+
51
+ export function ExportInventory500ResponseToJSON(json: any): ExportInventory500Response {
52
+ return ExportInventory500ResponseToJSONTyped(json, false);
53
+ }
54
+
55
+ export function ExportInventory500ResponseToJSONTyped(value?: ExportInventory500Response | null, ignoreDiscriminator: boolean = false): any {
56
+ if (value == null) {
57
+ return value;
58
+ }
59
+
60
+ return {
61
+
62
+ 'error': value['error'],
63
+ };
64
+ }
65
+
@@ -79,9 +79,9 @@ export function HostFromJSONTyped(json: any, ignoreDiscriminator: boolean): Host
79
79
  'id': json['id'] == null ? undefined : json['id'],
80
80
  'vendor': json['vendor'],
81
81
  'model': json['model'],
82
- 'cpuCores': json['cpuCores'] == null ? undefined : json['cpuCores'],
83
- 'cpuSockets': json['cpuSockets'] == null ? undefined : json['cpuSockets'],
84
- 'memoryMB': json['memoryMB'] == null ? undefined : json['memoryMB'],
82
+ 'cpuCores': json['cpuCores'] === undefined ? undefined : json['cpuCores'] === null ? null : json['cpuCores'],
83
+ 'cpuSockets': json['cpuSockets'] === undefined ? undefined : json['cpuSockets'] === null ? null : json['cpuSockets'],
84
+ 'memoryMB': json['memoryMB'] === undefined ? undefined : json['memoryMB'] === null ? null : json['memoryMB'],
85
85
  };
86
86
  }
87
87
 
@@ -0,0 +1,102 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Assisted Migration Agent API
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: v1
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime.js';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface IssuesBreakdown
20
+ */
21
+ export interface IssuesBreakdown {
22
+ /**
23
+ * Number of VMs with at least one Critical issue
24
+ * @type {number}
25
+ * @memberof IssuesBreakdown
26
+ */
27
+ critical: number;
28
+ /**
29
+ * Number of VMs with at least one Warning issue
30
+ * @type {number}
31
+ * @memberof IssuesBreakdown
32
+ */
33
+ warning: number;
34
+ /**
35
+ * Number of VMs with at least one Information issue
36
+ * @type {number}
37
+ * @memberof IssuesBreakdown
38
+ */
39
+ information: number;
40
+ /**
41
+ * Number of VMs with at least one Advisory issue
42
+ * @type {number}
43
+ * @memberof IssuesBreakdown
44
+ */
45
+ advisory: number;
46
+ /**
47
+ * Number of VMs with at least one Error issue
48
+ * @type {number}
49
+ * @memberof IssuesBreakdown
50
+ */
51
+ error: number;
52
+ }
53
+
54
+ /**
55
+ * Check if a given object implements the IssuesBreakdown interface.
56
+ */
57
+ export function instanceOfIssuesBreakdown(value: object): value is IssuesBreakdown {
58
+ if (!('critical' in value) || value['critical'] === undefined) return false;
59
+ if (!('warning' in value) || value['warning'] === undefined) return false;
60
+ if (!('information' in value) || value['information'] === undefined) return false;
61
+ if (!('advisory' in value) || value['advisory'] === undefined) return false;
62
+ if (!('error' in value) || value['error'] === undefined) return false;
63
+ return true;
64
+ }
65
+
66
+ export function IssuesBreakdownFromJSON(json: any): IssuesBreakdown {
67
+ return IssuesBreakdownFromJSONTyped(json, false);
68
+ }
69
+
70
+ export function IssuesBreakdownFromJSONTyped(json: any, ignoreDiscriminator: boolean): IssuesBreakdown {
71
+ if (json == null) {
72
+ return json;
73
+ }
74
+ return {
75
+
76
+ 'critical': json['critical'],
77
+ 'warning': json['warning'],
78
+ 'information': json['information'],
79
+ 'advisory': json['advisory'],
80
+ 'error': json['error'],
81
+ };
82
+ }
83
+
84
+ export function IssuesBreakdownToJSON(json: any): IssuesBreakdown {
85
+ return IssuesBreakdownToJSONTyped(json, false);
86
+ }
87
+
88
+ export function IssuesBreakdownToJSONTyped(value?: IssuesBreakdown | null, ignoreDiscriminator: boolean = false): any {
89
+ if (value == null) {
90
+ return value;
91
+ }
92
+
93
+ return {
94
+
95
+ 'critical': value['critical'],
96
+ 'warning': value['warning'],
97
+ 'information': value['information'],
98
+ 'advisory': value['advisory'],
99
+ 'error': value['error'],
100
+ };
101
+ }
102
+
@@ -31,6 +31,12 @@ export interface OsInfo {
31
31
  * @memberof OsInfo
32
32
  */
33
33
  supported: boolean;
34
+ /**
35
+ * OS support tier per Red Hat KCS article 4234591
36
+ * @type {OsInfoSupportTierEnum}
37
+ * @memberof OsInfo
38
+ */
39
+ supportTier?: OsInfoSupportTierEnum;
34
40
  /**
35
41
  * Recommended OS upgrade for MTV unsupported OS that can be upgraded to a supported OS
36
42
  * @type {string}
@@ -39,6 +45,19 @@ export interface OsInfo {
39
45
  upgradeRecommendation?: string;
40
46
  }
41
47
 
48
+
49
+ /**
50
+ * @export
51
+ */
52
+ export const OsInfoSupportTierEnum = {
53
+ Certified: 'certified',
54
+ VendorSupported: 'vendor_supported',
55
+ CommunitySupported: 'community_supported',
56
+ SpecialHandling: 'special_handling'
57
+ } as const;
58
+ export type OsInfoSupportTierEnum = typeof OsInfoSupportTierEnum[keyof typeof OsInfoSupportTierEnum];
59
+
60
+
42
61
  /**
43
62
  * Check if a given object implements the OsInfo interface.
44
63
  */
@@ -60,6 +79,7 @@ export function OsInfoFromJSONTyped(json: any, ignoreDiscriminator: boolean): Os
60
79
 
61
80
  'count': json['count'],
62
81
  'supported': json['supported'],
82
+ 'supportTier': json['supportTier'] == null ? undefined : json['supportTier'],
63
83
  'upgradeRecommendation': json['upgradeRecommendation'] == null ? undefined : json['upgradeRecommendation'],
64
84
  };
65
85
  }
@@ -77,6 +97,7 @@ export function OsInfoToJSONTyped(value?: OsInfo | null, ignoreDiscriminator: bo
77
97
 
78
98
  'count': value['count'],
79
99
  'supported': value['supported'],
100
+ 'supportTier': value['supportTier'],
80
101
  'upgradeRecommendation': value['upgradeRecommendation'],
81
102
  };
82
103
  }
@@ -0,0 +1,74 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Assisted Migration Agent API
5
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ *
7
+ * The version of the OpenAPI document: v1
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime.js';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface Process
20
+ */
21
+ export interface Process {
22
+ /**
23
+ * Name of the process
24
+ * @type {string}
25
+ * @memberof Process
26
+ */
27
+ name: string;
28
+ /**
29
+ * Version of the process
30
+ * @type {string}
31
+ * @memberof Process
32
+ */
33
+ version?: string;
34
+ }
35
+
36
+ /**
37
+ * Check if a given object implements the Process interface.
38
+ */
39
+ export function instanceOfProcess(value: object): value is Process {
40
+ if (!('name' in value) || value['name'] === undefined) return false;
41
+ return true;
42
+ }
43
+
44
+ export function ProcessFromJSON(json: any): Process {
45
+ return ProcessFromJSONTyped(json, false);
46
+ }
47
+
48
+ export function ProcessFromJSONTyped(json: any, ignoreDiscriminator: boolean): Process {
49
+ if (json == null) {
50
+ return json;
51
+ }
52
+ return {
53
+
54
+ 'name': json['name'],
55
+ 'version': json['version'] == null ? undefined : json['version'],
56
+ };
57
+ }
58
+
59
+ export function ProcessToJSON(json: any): Process {
60
+ return ProcessToJSONTyped(json, false);
61
+ }
62
+
63
+ export function ProcessToJSONTyped(value?: Process | null, ignoreDiscriminator: boolean = false): any {
64
+ if (value == null) {
65
+ return value;
66
+ }
67
+
68
+ return {
69
+
70
+ 'name': value['name'],
71
+ 'version': value['version'],
72
+ };
73
+ }
74
+
package/src/models/VMs.ts CHANGED
@@ -27,6 +27,13 @@ import {
27
27
  OsInfoToJSON,
28
28
  OsInfoToJSONTyped,
29
29
  } from './OsInfo.js';
30
+ import type { IssuesBreakdown } from './IssuesBreakdown.js';
31
+ import {
32
+ IssuesBreakdownFromJSON,
33
+ IssuesBreakdownFromJSONTyped,
34
+ IssuesBreakdownToJSON,
35
+ IssuesBreakdownToJSONTyped,
36
+ } from './IssuesBreakdown.js';
30
37
  import type { DiskSizeTierSummary } from './DiskSizeTierSummary.js';
31
38
  import {
32
39
  DiskSizeTierSummaryFromJSON,
@@ -190,6 +197,12 @@ export interface VMs {
190
197
  * @memberof VMs
191
198
  */
192
199
  migrationWarnings: Array<MigrationIssue>;
200
+ /**
201
+ *
202
+ * @type {IssuesBreakdown}
203
+ * @memberof VMs
204
+ */
205
+ issuesBreakdown?: IssuesBreakdown;
193
206
  }
194
207
 
195
208
  /**
@@ -240,6 +253,7 @@ export function VMsFromJSONTyped(json: any, ignoreDiscriminator: boolean): VMs {
240
253
  'osInfo': json['osInfo'] == null ? undefined : (mapValues(json['osInfo'], OsInfoFromJSON)),
241
254
  'notMigratableReasons': ((json['notMigratableReasons'] as Array<any>).map(MigrationIssueFromJSON)),
242
255
  'migrationWarnings': ((json['migrationWarnings'] as Array<any>).map(MigrationIssueFromJSON)),
256
+ 'issuesBreakdown': json['issuesBreakdown'] == null ? undefined : IssuesBreakdownFromJSON(json['issuesBreakdown']),
243
257
  };
244
258
  }
245
259
 
@@ -276,6 +290,7 @@ export function VMsToJSONTyped(value?: VMs | null, ignoreDiscriminator: boolean
276
290
  'osInfo': value['osInfo'] == null ? undefined : (mapValues(value['osInfo'], OsInfoToJSON)),
277
291
  'notMigratableReasons': ((value['notMigratableReasons'] as Array<any>).map(MigrationIssueToJSON)),
278
292
  'migrationWarnings': ((value['migrationWarnings'] as Array<any>).map(MigrationIssueToJSON)),
293
+ 'issuesBreakdown': IssuesBreakdownToJSON(value['issuesBreakdown']),
279
294
  };
280
295
  }
281
296
 
@@ -48,6 +48,13 @@ import {
48
48
  VmUtilizationDetailsToJSON,
49
49
  VmUtilizationDetailsToJSONTyped,
50
50
  } from './VmUtilizationDetails.js';
51
+ import type { Process } from './Process.js';
52
+ import {
53
+ ProcessFromJSON,
54
+ ProcessFromJSONTyped,
55
+ ProcessToJSON,
56
+ ProcessToJSONTyped,
57
+ } from './Process.js';
51
58
  import type { VMDisk } from './VMDisk.js';
52
59
  import {
53
60
  VMDiskFromJSON,
@@ -273,6 +280,12 @@ export interface VirtualMachineDetail {
273
280
  * @memberof VirtualMachineDetail
274
281
  */
275
282
  utilization?: VmUtilizationDetails;
283
+ /**
284
+ * List of processes detected on this VM
285
+ * @type {Array<Process>}
286
+ * @memberof VirtualMachineDetail
287
+ */
288
+ processes?: Array<Process>;
276
289
  }
277
290
 
278
291
  /**
@@ -335,6 +348,7 @@ export function VirtualMachineDetailFromJSONTyped(json: any, ignoreDiscriminator
335
348
  'issues': json['issues'] == null ? undefined : ((json['issues'] as Array<any>).map(VMIssueFromJSON)),
336
349
  'inspection': json['inspection'] == null ? undefined : VmInspectionResultsFromJSON(json['inspection']),
337
350
  'utilization': json['utilization'] == null ? undefined : VmUtilizationDetailsFromJSON(json['utilization']),
351
+ 'processes': json['processes'] == null ? undefined : ((json['processes'] as Array<any>).map(ProcessFromJSON)),
338
352
  };
339
353
  }
340
354
 
@@ -383,6 +397,7 @@ export function VirtualMachineDetailToJSONTyped(value?: VirtualMachineDetail | n
383
397
  'issues': value['issues'] == null ? undefined : ((value['issues'] as Array<any>).map(VMIssueToJSON)),
384
398
  'inspection': VmInspectionResultsToJSON(value['inspection']),
385
399
  'utilization': VmUtilizationDetailsToJSON(value['utilization']),
400
+ 'processes': value['processes'] == null ? undefined : ((value['processes'] as Array<any>).map(ProcessToJSON)),
386
401
  };
387
402
  }
388
403
 
@@ -5,6 +5,7 @@ export * from './AgentStatus.js';
5
5
  export * from './ApplicationListResponse.js';
6
6
  export * from './ApplicationOverview.js';
7
7
  export * from './ApplicationVM.js';
8
+ export * from './BatchUpdateExclusionRequest.js';
8
9
  export * from './BenchmarkRun.js';
9
10
  export * from './CapabilityStatus.js';
10
11
  export * from './CapabilityStatusCapabilities.js';
@@ -21,6 +22,8 @@ export * from './DeleteLabelGloballyResponse.js';
21
22
  export * from './DiskSizeTierSummary.js';
22
23
  export * from './DiskTypeSummary.js';
23
24
  export * from './EstimateRange.js';
25
+ export * from './ExportInventory400Response.js';
26
+ export * from './ExportInventory500Response.js';
24
27
  export * from './ForecastStats.js';
25
28
  export * from './ForecasterDatastoresRequest.js';
26
29
  export * from './ForecasterPairStatus.js';
@@ -37,12 +40,14 @@ export * from './Infra.js';
37
40
  export * from './InspectorStatus.js';
38
41
  export * from './Inventory.js';
39
42
  export * from './InventoryData.js';
43
+ export * from './IssuesBreakdown.js';
40
44
  export * from './MigrationIssue.js';
41
45
  export * from './Network.js';
42
46
  export * from './OperationCapability.js';
43
47
  export * from './OsInfo.js';
44
48
  export * from './PairCapability.js';
45
49
  export * from './PairCapabilityRequest.js';
50
+ export * from './Process.js';
46
51
  export * from './PutForecasterCredentials403Response.js';
47
52
  export * from './RightsizingClusterListResponse.js';
48
53
  export * from './RightsizingClusterResponse.js';
package/src/runtime.ts CHANGED
@@ -367,6 +367,11 @@ export function mapValues(data: any, fn: (item: any) => any) {
367
367
  return result;
368
368
  }
369
369
 
370
+ // Pass-through serializer for `any`-typed properties in form data. See #1877.
371
+ export function anyToJSON(value: any): any {
372
+ return value;
373
+ }
374
+
370
375
  export function canConsumeForm(consumes: Consume[]): boolean {
371
376
  for (const consume of consumes) {
372
377
  if (consume.contentType?.startsWith('multipart/form-data') == true) {
package/tsconfig.json CHANGED
@@ -3,8 +3,8 @@
3
3
  "declaration": true,
4
4
  "target": "es6",
5
5
  "module": "commonjs",
6
- "moduleResolution": "node",
7
6
  "outDir": "dist",
7
+ "rootDir": "src",
8
8
  "typeRoots": [
9
9
  "node_modules/@types"
10
10
  ]