Checkpoint towards metadata synchronization: need to reclaim storage occupied by orphaned index artifacts in NCs.

git-svn-id: https://asterixdb.googlecode.com/svn/branches/asterix_lsm_stabilization@1389 eaa15691-b419-025a-1212-ee371bd00084
diff --git a/asterix-app/src/main/java/edu/uci/ics/asterix/hyracks/bootstrap/NCApplicationEntryPoint.java b/asterix-app/src/main/java/edu/uci/ics/asterix/hyracks/bootstrap/NCApplicationEntryPoint.java
index 59ae6f9..5e0cb1b 100644
--- a/asterix-app/src/main/java/edu/uci/ics/asterix/hyracks/bootstrap/NCApplicationEntryPoint.java
+++ b/asterix-app/src/main/java/edu/uci/ics/asterix/hyracks/bootstrap/NCApplicationEntryPoint.java
@@ -46,15 +46,6 @@
             recoveryMgr.startRecovery(true);
         }
         recoveryMgr.checkpoint(true);
-        
-        //TODO
-        //#. synchronize metadata and jobid
-        /*********************************************
-        if (isMetadataNode) {
-            //#. clean-up incomplete DDL operations, which is DDLRecovery
-            MetadataBootstrap.startDDLRecovery();
-        }
-        **********************************************/
     }
 
     @Override
@@ -89,7 +80,11 @@
             MetadataManager.INSTANCE = new MetadataManager(proxy);
             MetadataManager.INSTANCE.init();
             MetadataBootstrap.startUniverse(proxy.getAsterixProperties(), ncApplicationContext);
+            MetadataBootstrap.startDDLRecovery();
         }
+        
+        //TODO
+        //reclaim storage for orphaned index artifacts in NCs.
     }
 
     public void registerRemoteMetadataNode(IAsterixStateProxy proxy) throws RemoteException {
diff --git a/asterix-transactions/src/main/java/edu/uci/ics/asterix/transaction/management/service/recovery/RecoveryManager.java b/asterix-transactions/src/main/java/edu/uci/ics/asterix/transaction/management/service/recovery/RecoveryManager.java
index 8aae6b1..1da84df 100644
--- a/asterix-transactions/src/main/java/edu/uci/ics/asterix/transaction/management/service/recovery/RecoveryManager.java
+++ b/asterix-transactions/src/main/java/edu/uci/ics/asterix/transaction/management/service/recovery/RecoveryManager.java
@@ -357,8 +357,6 @@
         for (long r : resourceIdList) {
             indexLifecycleManager.close(r);
         }
-
-        JobIdFactory.initJobId(maxJobId);
     }
 
     //TODO