integration-tests/src/test/java/oracle/kubernetes/operator/MiiConfigUpdateBaseTest.java
protected Secret createSecretImageAndPatchDomain(Domain domain,
                                                    String jdbcUrl,
                                                    String mysqldbport,
                                                    String wdtModelFile,
                                                    String wdtModelPropFile) {
    // create a secret with jdbc url, username and password
    final String domainNS = domain.getDomainNs();
    Secret secret = createSecrets(domainNS, jdbcUrl);

    // patch domain to adding the secret name and verify domain restarted successfully
    modifyDomainYamlWithSecretName(domain, secret.getSecretName());

    // replace secret name token with real secret name
    Map<String, Object> domainMap = domain.getDomainMap();
    final String resultsDir = (String) domainMap.get("resultDir");
    final String destDir = resultsDir + "/samples/model-in-image";
    copyAndUpdateModelFileWSecret(destDir, wdtModelFile, secret.getSecretName());

    final String imageName = (String) domainMap.get("image") + "_secret";
    createImageAndPatchDomain(domain, imageName, wdtModelFile, wdtModelPropFile);

    return secret;
  }
/**
   * Create secret to update config and patch domain to change domain-level restart version.
   * @param domain the Domain object where to patch domain and update domain config values
   * @param destDir destination directory name to copy model files to
   * @param modelFiles names of model files to copy
   */
Create secret to update config and patch domain to change domain-level restart version.
@param domain the Domain object where to patch domain and update domain config values
@param destDir destination directory name to copy model files to
@param modelFiles names of model files to copy
Create secret to update config and patch domain to change domain - level restart version . @param domain the Domain object where to patch domain and update domain config values @param destDir destination directory name to copy model files to @param modelFiles names of model files to copy
protected Secret createSecretImageAndPatchDomain(Domain domain,
                                                    String jdbcUrl,
                                                    String mysqldbport,
                                                    String wdtModelFile,
                                                    String wdtModelPropFile) {
    final String domainNS = domain.getDomainNs();
    Secret secret = createSecrets(domainNS, jdbcUrl);
    modifyDomainYamlWithSecretName(domain, secret.getSecretName());
    Map<String, Object> domainMap = domain.getDomainMap();
    final String resultsDir = (String) domainMap.get("resultDir");
    final String destDir = resultsDir + "/samples/model-in-image";
    copyAndUpdateModelFileWSecret(destDir, wdtModelFile, secret.getSecretName());
    final String imageName = (String) domainMap.get("image") + "_secret";
    createImageAndPatchDomain(domain, imageName, wdtModelFile, wdtModelPropFile);
    return secret;
  }
protected Secret createSecretImageAndPatchDomain ( Domain domain , String jdbcUrl , String mysqldbport , String wdtModelFile , String wdtModelPropFile ) { final String domainNS = domain . getDomainNs ( ) ; Secret secret = createSecrets ( domainNS , jdbcUrl ) ; modifyDomainYamlWithSecretName ( domain , secret . getSecretName ( ) ) ; Map < String , Object > domainMap = domain . getDomainMap ( ) ; final String resultsDir = ( String ) domainMap . get ( "resultDir" ) ; final String destDir = resultsDir + "/samples/model-in-image" ; copyAndUpdateModelFileWSecret ( destDir , wdtModelFile , secret . getSecretName ( ) ) ; final String imageName = ( String ) domainMap . get ( "image" ) + "_secret" ; createImageAndPatchDomain ( domain , imageName , wdtModelFile , wdtModelPropFile ) ; return secret ; }
Create secret to update config and patch domain to change domain-level restart version.
Create secret to update config and patch domain to change domain - level restart version .
// create a secret with jdbc url, username and password // patch domain to adding the secret name and verify domain restarted successfully // replace secret name token with real secret name