Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit e810618

Browse files
committed
Merge branch 'jrfopssfile' into 'main'
Modify ItFmwDomainInPvUserCreateRcu to use "/share" as hostpath of PV See merge request weblogic-cloud/weblogic-kubernetes-operator!4246
2 parents 61c1a63 + 47e234c commit e810618

File tree

2 files changed

+9
-30
lines changed

2 files changed

+9
-30
lines changed

‎integration-tests/src/test/java/oracle/weblogic/kubernetes/ItFmwDomainInPvUserCreateRcu.java‎

Lines changed: 7 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import java.io.FileOutputStream;
88
import java.io.IOException;
99
import java.nio.file.Path;
10+
import java.nio.file.Paths;
1011
import java.util.ArrayList;
1112
import java.util.Collections;
1213
import java.util.List;
@@ -51,7 +52,6 @@
5152
import static oracle.weblogic.kubernetes.utils.ImageUtils.createBaseRepoSecret;
5253
import static oracle.weblogic.kubernetes.utils.ImageUtils.createTestRepoSecret;
5354
import static oracle.weblogic.kubernetes.utils.OperatorUtils.installAndVerifyOperator;
54-
import static oracle.weblogic.kubernetes.utils.PersistentVolumeUtils.createPVHostPathDir;
5555
import static oracle.weblogic.kubernetes.utils.SecretUtils.createOpsswalletpasswordSecret;
5656
import static oracle.weblogic.kubernetes.utils.SecretUtils.createSecretWithUsernamePassword;
5757
import static oracle.weblogic.kubernetes.utils.ThreadSafeLogger.getLogger;
@@ -75,21 +75,12 @@ public class ItFmwDomainInPvUserCreateRcu {
7575
private static final String RCUSCHEMAPREFIX = "jrfdomainpv";
7676
private static final String ORACLEDBURLPREFIX = "oracledb.";
7777
private static String ORACLEDBSUFFIX = null;
78-
private static final String RCUSYSUSERNAME = "sys";
79-
private static final String RCUSYSPASSWORD = "Oradoc_db1";
80-
private static final String RCUSCHEMAUSERNAME = "myrcuuser";
8178
private static final String RCUSCHEMAPASSWORD = "Oradoc_db1";
8279

8380
private static String dbUrl = null;
8481
private static LoggingFacade logger = null;
8582
private static String DOMAINHOMEPREFIX = null;
8683
private static final String domainUid = "domainonpv-userrcu";
87-
private static final String clusterName = "cluster-1";
88-
private static final String adminServerName = "admin-server";
89-
private static final String managedServerNameBase = "managed-server";
90-
private static final String adminServerPodName = domainUid + "-" + adminServerName;
91-
private static final String managedServerPodNamePrefix = domainUid + "-" + managedServerNameBase;
92-
private static final int managedServerPort = 8001;
9384
private static final String miiAuxiliaryImage1Tag = "jrf1" + MII_BASIC_IMAGE_TAG;
9485
private final String adminSecretName = domainUid + "-weblogic-credentials";
9586
private final String rcuaccessSecretName = domainUid + "-rcu-credentials";
@@ -170,7 +161,6 @@ RCUSCHEMAPREFIX, dbNamespace, getNextFreePort(), dbUrl, dbListenerPort),
170161
@DisplayName("Create a FMW domain on PV when user per-creates RCU")
171162
void testFmwDomainOnPvUserCreatesRCU() {
172163

173-
final int t3ChannelPort = getNextFreePort();
174164
// create a model property file
175165
File fmwModelPropFile = createWdtPropertyFile();
176166

@@ -228,15 +218,12 @@ void testFmwDomainOnPvUserCreatesRCU() {
228218
domainCreationImage =
229219
new DomainCreationImage().image(MII_AUXILIARY_IMAGE_NAME + ":" + miiAuxiliaryImage1Tag);
230220

231-
String clusterName = "cluster-1";
232-
pvHostPath = getHostPath(pvName, this.getClass().getSimpleName());
233-
234221
// create a domain custom resource configuration object
235222
logger.info("Creating domain custom resource with pvName: {0}, hostPath: {1}", pvName, pvHostPath);
236223
DomainResource domain = createDomainResourceSimplifyJrfPv(
237224
domainUid, domainNamespace, adminSecretName,
238-
TEST_IMAGES_REPO_SECRET_NAME,encryptionSecretName,
239-
pvHostPath, rcuaccessSecretName,
225+
TEST_IMAGES_REPO_SECRET_NAME,
226+
rcuaccessSecretName,
240227
opsswalletpassSecretName, null,
241228
pvName, pvcName, Collections.singletonList(domainCreationImage));
242229

@@ -261,15 +248,15 @@ void testFmwDomainOnPvUserProvideOpss() {
261248
logger.info("Deleting domain custom resource with namespace: {0}, domainUid {1}", domainNamespace, domainUid);
262249
deleteDomainResource(domainNamespace, domainUid);
263250
try {
264-
deleteDirectory(hostPVPath.toFile());
251+
deleteDirectory(Paths.get("/share").toFile());
265252
} catch (IOException ioe) {
266253
logger.severe("Failed to cleanup the pv directory " + pvHostPath, ioe);
267254
}
268255
logger.info("Creating domain custom resource with pvName: {0}, hostPath: {1}", pvName, pvHostPath);
269256
DomainResource domain = createDomainResourceSimplifyJrfPv(
270257
domainUid, domainNamespace, adminSecretName,
271-
TEST_IMAGES_REPO_SECRET_NAME,encryptionSecretName,
272-
pvHostPath, rcuaccessSecretName,
258+
TEST_IMAGES_REPO_SECRET_NAME,
259+
rcuaccessSecretName,
273260
opsswalletpassSecretName, opsswalletfileSecretName,
274261
pvName, pvcName, Collections.singletonList(domainCreationImage));
275262
// create a domain custom resource and verify domain is created
@@ -301,10 +288,5 @@ private File createWdtPropertyFile() {
301288

302289
return domainPropertiesFile;
303290
}
304-
305-
private String getHostPath(String pvName, String className) {
306-
hostPVPath = createPVHostPathDir(pvName, className);
307-
return hostPVPath.toString();
308-
}
309-
291+
310292
}

‎integration-tests/src/test/java/oracle/weblogic/kubernetes/utils/FmwUtils.java‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -350,8 +350,6 @@ public static void verifyEMconsoleAccess(String domainNamespace, String domainUi
350350
* @param domainNamespace namespace where the domain exists
351351
* @param adminSecretName name of admin secret
352352
* @param repoSecretName name of repository secret
353-
* @param encryptionSecretName name of encryption secret
354-
* @param hostPath persistent volume mount path
355353
* @param rcuAccessSecretName name of RCU access secret
356354
* @param opssWalletPasswordSecretName name of opss wallet password secret
357355
* @param opssWalletFileSecretName name of opss wallet file secret
@@ -362,8 +360,7 @@ public static void verifyEMconsoleAccess(String domainNamespace, String domainUi
362360
*/
363361
public static DomainResource createDomainResourceSimplifyJrfPv(
364362
String domainUid, String domainNamespace, String adminSecretName,
365-
String repoSecretName, String encryptionSecretName, String hostPath,
366-
String rcuAccessSecretName, String opssWalletPasswordSecretName,
363+
String repoSecretName, String rcuAccessSecretName, String opssWalletPasswordSecretName,
367364
String opssWalletFileSecretName,
368365
String pvName, String pvcName,
369366
List<DomainCreationImage> domainCreationImages) {
@@ -433,7 +430,7 @@ public static DomainResource createDomainResourceSimplifyJrfPv(
433430
.spec(new PersistentVolumeSpec()
434431
.storageClassName("weblogic-domain-storage-class")
435432
.hostPath(new V1HostPathVolumeSource()
436-
.path(hostPath))
433+
.path("/share"))
437434
.capacity(capacity)))
438435
.persistentVolumeClaim(new PersistentVolumeClaim()
439436
.metadata(new V1ObjectMeta()

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /