@@ -384,14 +384,17 @@ def extract_database_wallet(self, wallet_name=WLSDeployArchive.DEFAULT_RCU_WALLE
384
384
:raises: BundleAwareException of the appropriate type: if an error occurs
385
385
"""
386
386
_method_name = 'extract_database_wallet'
387
- self .__logger .entering (class_name = self .__class_name , method_name = _method_name )
387
+ self .__logger .entering (wallet_name , class_name = self .__class_name , method_name = _method_name )
388
388
389
389
resulting_wallet_path = None
390
- for archive_file in self .__archive_files [:: - 1 ] :
390
+ for archive_file in self .__archive_files :
391
391
wallet_path = archive_file .extractDatabaseWallet (self .__domain_home , wallet_name )
392
392
# Allow iteration to continue through all archive files but
393
393
# make sure to store off the path for a wallet that was extracted.
394
394
#
395
+ self .__logger .finer ('extract wallet {0} from archive file {1} returned wallet path {2}' ,
396
+ wallet_name , archive_file .getArchiveFileName (), wallet_path ,
397
+ class_name = self .__class_name , method_name = _method_name )
395
398
if wallet_path is not None :
396
399
# If multiple archives contain the same named wallet, they
397
400
# will all have the same path.
@@ -402,19 +405,25 @@ def extract_database_wallet(self, wallet_name=WLSDeployArchive.DEFAULT_RCU_WALLE
402
405
return resulting_wallet_path
403
406
404
407
def extract_all_database_wallets (self ):
408
+ _method_name = 'extract_all_database_wallets'
409
+ self .__logger .entering (class_name = self .__class_name , method_name = _method_name )
410
+
411
+ # extract_database_wallet() loops through the archive files so just collect
412
+ # the list of wallet names from the archive files and then loop through that list.
405
413
414
+ wallet_names = sets .Set ()
406
415
for archive_file in self .__archive_files :
407
- archive_entries = archive_file .getArchiveEntries ()
408
- wallet_names = sets . Set ( )
409
- for entry in archive_entries :
410
- if entry . startswith ( WLSDeployArchive . ARCHIVE_DB_WALLETS_DIR ):
411
- if os . path . isdir ( entry ):
412
- wallet_names . add ( os . path . basename ( entry ))
413
- else :
414
- name = os . path . basename ( os . path . dirname ( entry ) )
415
- wallet_names . add ( name )
416
- for wallet_name in wallet_names :
417
- self .extract_database_wallet ( wallet_name )
416
+ self . __logger . finer ( 'processing archive_file {0}' , archive_file .getArchiveFileName (),
417
+ class_name = self . __class_name , method_name = _method_name )
418
+ archive_wallet_names = archive_file . getDatabaseWalletNames ()
419
+ wallet_names . update ( archive_wallet_names )
420
+
421
+ for wallet_name in wallet_names :
422
+ self . __logger . finer ( 'extracting database wallet {0}' , wallet_name ,
423
+ class_name = self . __class_name , method_name = _method_name )
424
+ self . extract_database_wallet ( wallet_name )
425
+
426
+ self .__logger . exiting ( class_name = self . __class_name , method_name = _method_name )
418
427
419
428
def extract_opss_wallet (self ):
420
429
"""
@@ -426,7 +435,7 @@ def extract_opss_wallet(self):
426
435
self .__logger .entering (class_name = self .__class_name , method_name = _method_name )
427
436
428
437
resulting_wallet_path = None
429
- for archive_file in self .__archive_files [:: - 1 ] :
438
+ for archive_file in self .__archive_files :
430
439
wallet_path = archive_file .extractOPSSWallet (self .__domain_home )
431
440
# Allow iteration to continue through all archive files but
432
441
# make sure to store off the path for a wallet that was extracted.
0 commit comments