Hi Deng,

On 22/10/2007, at 3:30 AM, [EMAIL PROTECTED] wrote:

@@ -89,13 +105,12 @@
         try
         {
Configuration configuration = archivaConfiguration.getConfiguration();
+            cleanupRepositoryData( existingRepository );
             removeRepository( repoid, configuration );
             result = saveConfiguration( configuration );

             if ( result.equals( SUCCESS ) )
             {
-                cleanupRepositoryData( existingRepository );
-

Can you just clarify why this was moved?

private void cleanupRepositoryData ( ManagedRepositoryConfiguration cleanupRepository )
-        throws RoleManagerException
+        throws RoleManagerException, ArchivaDatabaseException
     {
         removeRepositoryRoles( cleanupRepository );

// TODO: [MRM-382] Remove index from artifacts of deleted managed repositories.

- // TODO: [MRM-265] After removing a managed repository - Browse/Search still see it
-
+ // [MRM-265] After removing a managed repository - Browse/ Search still see it
+        cleanupDatabase( cleanupRepository.getId() );
+        cleanupScanStats( cleanupRepository.getId() );
+
// [MRM-520] Proxy Connectors are not deleted with the deletion of a Repository. List<ProxyConnectorConfiguration> proxyConnectors = getProxyConnectors(); for ( ProxyConnectorConfiguration proxyConnector : proxyConnectors )

Just a general note (not specific to this commit) - we need to start thinking about the accumulation of logic in the web actions and shuffle it over to the business layer.

Thanks!

Cheers,
Brett

--
Brett Porter - [EMAIL PROTECTED]
Blog: http://www.devzuz.org/blogs/bporter/

Reply via email to