mertak-synnada commented on code in PR #15352:
URL: https://github.com/apache/datafusion/pull/15352#discussion_r2011755617


##########
datafusion-examples/examples/advanced_parquet_index.rs:
##########
@@ -498,13 +499,15 @@ impl TableProvider for IndexTableProvider {
                 // provide the factory to create parquet reader without 
re-reading metadata
                 .with_parquet_file_reader_factory(Arc::new(reader_factory)),
         );
-        let file_scan_config = FileScanConfig::new(object_store_url, schema, 
file_source)
-            .with_limit(limit)
-            .with_projection(projection.cloned())
-            .with_file(partitioned_file);
+        let file_scan_config =
+            FileScanConfigBuilder::new(object_store_url, schema, file_source)
+                .with_limit(limit)
+                .with_projection(projection.cloned())
+                .with_file(partitioned_file)
+                .build();
 
         // Finally, put it all together into a DataSourceExec
-        Ok(file_scan_config.build())
+        Ok(Arc::new(DataSourceExec::new(Arc::new(file_scan_config))))

Review Comment:
   Isn't it possible to have this return as a function? Is it because of import 
cycles?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to