phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ethan Wang (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (PHOENIX-4150) Adding a policy filter to whitelist the properties that allow to be passed to Phoenix
Date Fri, 08 Sep 2017 00:41:00 GMT

    [ https://issues.apache.org/jira/browse/PHOENIX-4150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16157919#comment-16157919
] 

Ethan Wang edited comment on PHOENIX-4150 at 9/8/17 12:40 AM:
--------------------------------------------------------------

I see. Thanks [~tdsilva]
Actually this morning I saw HBaseFactoryProviderTest.java  It is basically testing provider
is providing the correct factory. 

Alternatively, as you suggested  [~tdsilva], I added file below and tested it fine. 
/test/resouce/META-INF/services/serviceloaderfile
CustomizedPropertyPolicy.java
CustomizedPropertyPolicyTest.java
But that will be testing CustomizedPropertyPolicy not the code in this patch(which is factory
provider). So I think may be it's good to follow the existing HBaseFactoryProviderTest.java.
Thoughts?


was (Author: aertoria):
I see. Thanks [~tdsilva]
Actually this morning I saw HBaseFactoryProviderTest.java  It is basically testing provider
is providing the correct factory. I think I'm going to follow that.

> Adding a policy filter to whitelist the properties that allow to be passed to Phoenix
> -------------------------------------------------------------------------------------
>
>                 Key: PHOENIX-4150
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-4150
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Ethan Wang
>            Assignee: Ethan Wang
>            Priority: Critical
>         Attachments: PHOENIX-4150-v1.patch, PHOENIX-4150-v2.patch
>
>
> Adding a policy filter to whitelist the properties that allow to be passed to Phoenix.
> Feature proposal:
> When user getting phoenix connection via
> Connection conn = DriverManager.getConnection(connectionString, properties);
> A properties whitelist policy will essentially check each properties that passed in (likely
happen at PhoenixDriver.java), so that the un-allowed property will result in an exception
been thrown.
> Similar to HBaseFactoryProvider, proposing have a interface for whitelist policy and
a default impl that will by default allow all properties. User can override the impl for this
interface to start using whitelist feature
> [~jamestaylor]   [~alexaraujo]



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message