Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions packages/core/src/codewhisperer/models/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -330,17 +330,15 @@ export class ZipManifest {
hilCapabilities: string[] = ['HIL_1pDependency_VersionUpgrade']
transformCapabilities: string[] = ['EXPLAINABILITY_V1'] // TO-DO: for SQL conversions, maybe make this = []
customBuildCommand: string = 'clean test'
requestedConversions: {
sqlConversion:
| {
source: string | undefined
target: string | undefined
schema: string | undefined
host: string | undefined
sctFileName: string | undefined
}
| undefined
} = { sqlConversion: undefined }
requestedConversions?: {
sqlConversion?: {
source?: string
target?: string
schema?: string
host?: string
sctFileName?: string
}
}
}

export interface IHilZipManifestParams {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -327,12 +327,15 @@ export async function zipCode(
) {
// note that zipManifest must be a ZipManifest since only other option is HilZipManifest which is not used for SQL conversions
const metadataZip = new AdmZip(transformByQState.getMetadataPathSQL())
zipManifest.requestedConversions.sqlConversion = {
source: transformByQState.getSourceDB(),
target: transformByQState.getTargetDB(),
schema: transformByQState.getSchema(),
host: transformByQState.getSourceServerName(),
sctFileName: metadataZip.getEntries().filter((entry) => entry.entryName.endsWith('.sct'))[0].entryName,
zipManifest.requestedConversions = {
sqlConversion: {
source: transformByQState.getSourceDB(),
target: transformByQState.getTargetDB(),
schema: transformByQState.getSchema(),
host: transformByQState.getSourceServerName(),
sctFileName: metadataZip.getEntries().filter((entry) => entry.entryName.endsWith('.sct'))[0]
.entryName,
},
}
// TO-DO: later consider making this add to path.join(zipManifest.dependenciesRoot, 'qct-sct-metadata', entry.entryName) so that it's more organized
metadataZip
Expand Down
Loading