paul-rogers commented on issue #1807: DRILL-7293: Convert the regex ("log") 
plugin to use EVF
URL: https://github.com/apache/drill/pull/1807#issuecomment-506209593
 
 
   @arina-ielchiieva, added a unit test to show that the schema-only table 
function works.
   
   Tried to create a test that combined a "plugin" table function with the 
"schema" attribute. This failed due to the unfortunate use of "schema" as 
plugin property name. You've pointed out this issue all along, I finally 
understood why it was a problem. Still, I'm reluctant to change the config 
property name for fear of breaking compatibility.
   
   As it turns out, this limitation is only a minor nuisance since the only 
reason to combine the two kinds of table functions is to specify the regex 
property. A unit test shows that the regex can be specified as a table property 
instead.
   
   Also, went ahead and added support for the `columns` column. If no schema is 
provided (not in the plugin config, not in a table function, not in a provided 
schema), then rather than creating a set of dummy fields `field_0`, `field_1`, 
etc., the plugin how follows the text format plugin and puts the fields into 
the `columns` array. The dummy fields are still used if the user specifies at 
least one column schema, but the regex has more groups than specified columns.
   
   This means that, if the user uses a table function to specify just the 
regex, the user gets a reasonable result: the fields come back in the `columns` 
array.
   
   Unit tests show the new `columns` array support.  

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to