The Difference Using Java and Hadoop Types in Hive UDF -


when writing simple hive udf, possible use both standard java , hadoop types in evaluate() method. example, following methods should return same results.

using string input , output types:

public string evaluate(string input) {   if(input == null) return null;   return input.touppercase(); } 

using text input , output types:

public text evaluate(text input) {   if(input == null) return null;   return new text(input.tostring().touppercase()); } 

my question benefits of using 1 vs other? if use standard java input , output types (like string) hadoop converting these objects hadoop types me?


Comments

Popular posts from this blog

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

jsf - "PropertyNotWritableException: Illegal Syntax for Set Operation" error when setting value in bean -

laravel - Undefined property: Illuminate\Pagination\LengthAwarePaginator::$id (View: F:\project\resources\views\admin\carousels\index.blade.php) -