Skip to content

Commit

Permalink
Add print (apache#4)
Browse files Browse the repository at this point in the history
* 添加更多的日志打印
  • Loading branch information
EricJoy2048 authored Mar 2, 2022
1 parent 32e5505 commit edffe28
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion datafusion/src/plugin/plugin_manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ impl GlobalPluginManager {
let plugin_files = self.get_all_plugin_files(plugin_path)?;

for plugin_file in plugin_files {
println!("load library :{}", plugin_file.path().to_str().unwrap());
let library = Library::new(plugin_file.path()).map_err(|e| {
DataFusionError::IoError(io::Error::new(
io::ErrorKind::Other,
Expand All @@ -90,9 +91,10 @@ impl GlobalPluginManager {
// ersion checks to prevent accidental ABI incompatibilities

if dec.rustc_version != RUSTC_VERSION || dec.core_version != CORE_VERSION {
println!("Version mismatch rustc_version:{}, core_version:{}", RUSTC_VERSION, CORE_VERSION);
return Err(DataFusionError::IoError(io::Error::new(
io::ErrorKind::Other,
"Version mismatch",
format!("Version mismatch rustc_version:{}, core_version:{}", RUSTC_VERSION, CORE_VERSION),
)));
}

Expand Down
3 changes: 2 additions & 1 deletion datafusion/src/plugin/udf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ impl PluginRegistrar for UDFPluginManager {
format!("not found fn registrar_udf_plugin in the library: {}", e),
))
})?;

println!("1111111111111111111111");
let udf_plugin: Box<dyn UDFPlugin> = register_fun();
udf_plugin
.udf_names()
Expand Down Expand Up @@ -128,6 +128,7 @@ macro_rules! declare_udf_plugin {
// make sure the constructor is the correct type.
let constructor: fn() -> $curr_plugin_type = $constructor;
let object = constructor();
println!("I be called");
Box::new(object)
}

Expand Down

0 comments on commit edffe28

Please sign in to comment.