Fixed ColumnarToStarTreeConverter to correctly load the config file. (#1472)

Because loadConfigFiles() is deprecated, StarTreeIndexSpec is not loaded correctly and the converter would always use the default settings even if the config file for the StarTree index is given.
diff --git a/pinot-tools/src/main/java/com/linkedin/pinot/tools/segment/converter/ColumnarToStarTreeConverter.java b/pinot-tools/src/main/java/com/linkedin/pinot/tools/segment/converter/ColumnarToStarTreeConverter.java
index cfe99ca..cd5f1da 100644
--- a/pinot-tools/src/main/java/com/linkedin/pinot/tools/segment/converter/ColumnarToStarTreeConverter.java
+++ b/pinot-tools/src/main/java/com/linkedin/pinot/tools/segment/converter/ColumnarToStarTreeConverter.java
@@ -15,6 +15,7 @@
  */
 package com.linkedin.pinot.tools.segment.converter;
 
+import com.linkedin.pinot.common.data.StarTreeIndexSpec;
 import com.linkedin.pinot.common.segment.SegmentMetadata;
 import com.linkedin.pinot.common.utils.TarGzCompressionUtils;
 import com.linkedin.pinot.core.data.readers.FileFormat;
@@ -28,6 +29,7 @@
 import java.io.File;
 import java.lang.reflect.Field;
 import org.apache.commons.io.FileUtils;
+import org.codehaus.jackson.map.ObjectMapper;
 import org.kohsuke.args4j.CmdLineParser;
 import org.kohsuke.args4j.Option;
 
@@ -37,6 +39,7 @@
  */
 public class ColumnarToStarTreeConverter {
   private static final String TMP_DIR_PREFIX = "_tmp_";
+  private static final ObjectMapper objectMapper = new ObjectMapper();
 
   @Option(name = "-inputDir", required = true, usage = "Path to input directory containing Pinot segments")
   private String _inputDirName = null;
@@ -118,6 +121,10 @@
     config.setStarTreeIndexSpecFile(_starTreeConfigFileName);
     config.setOverwrite(_overwrite);
 
+    // Load the StarTreeSpec object from the config file.
+    StarTreeIndexSpec starTreeIndexSpec = objectMapper.readValue(new File(_starTreeConfigFileName), StarTreeIndexSpec.class);
+    config.setStarTreeIndexSpec(starTreeIndexSpec);
+
     // Read the segment and table name from the segment's metadata.
     SegmentMetadata metadata = new SegmentMetadataImpl(columnarSegment);
     SegmentNameGenerator nameGenerator = new DefaultSegmentNameGenerator(metadata.getName());