sentry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sravya Tirukkovalur (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (SENTRY-361) Sentry server should use sentry-site.xml in conf directory by default
Date Mon, 04 Aug 2014 18:08:15 GMT

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

Sravya Tirukkovalur edited comment on SENTRY-361 at 8/4/14 6:07 PM:
--------------------------------------------------------------------

Thanks [~dapengsun], now I am able to apply the patch cleanly with the latest patch! Coming
to testing it out: This script is used for many purposes: Sentry service, schematool and configtool.
Looks like schematool currently does not recongnize -c (short option). And hence this fails:
{noformat}
bin/sentry --command schema-tool  --dbType derby --initSchema
Using config file sentry-dist/target/apache-sentry-1.5.0-incubating-SNAPSHOT-bin/apache-sentry-1.5.0-incubating-SNAPSHOT-bin/conf/sentry-site.xml
SentrySchemaTool:Parsing failed.  Reason: Unrecognized option: -c
usage: schemaTool
 -conffile <confName>               Sentry Service configuration file
 -dbOpts <databaseOpts>             Backend DB specific options
 -dbType <databaseType>             Metastore database type
                                    [derby,mysql,oracle,postgres,db2]
 -dryRun                            list SQL scripts (no execute)
 -help                              print this message
 -info                              Show config and schema details
 -initSchema                        Schema initialization
 -initSchemaTo <initTo>             Schema initialization to a version
 -passWord <password>               Override config file password
 -upgradeSchema                     Schema upgrade
 -upgradeSchemaFrom <upgradeFrom>   Schema upgrade from a version
 -userName <user>                   Override config file user name
 -verbose                           only print SQL statements
{noformat}


We might have to change the conffile option in SentrySchemaTool to:
{noformat}
Option configOpt = OptionBuilder.withLongOpt(ServiceConstants.ServiceArgs.CONFIG_FILE_LONG)
        .withArgName("confName").hasArgs()
        .withDescription("Sentry Service configuration file").isRequired(true)
        .create(ServiceConstants.ServiceArgs.CONFIG_FILE_SHORT);
{noformat}


was (Author: sravya):
Thanks [~dapengsun], now I am able to apply the patch cleanly with the latest patch! Coming
to testing it out: This script is used for many purposes: Sentry service, schematool and configtool.
Looks like schematool currently does not recongnize -c (short option). And hence this fails:
{noformat}
bin/sentry --command schema-tool  --dbType derby --initSchema
SentrySchemaTool:Parsing failed.  Reason: Missing required option: conffile
usage: schemaTool
 -conffile <confName>               Sentry Service configuration file
 -dbOpts <databaseOpts>             Backend DB specific options
 -dbType <databaseType>             Metastore database type
                                    [derby,mysql,oracle,postgres,db2]
 -dryRun                            list SQL scripts (no execute)
 -help                              print this message
 -info                              Show config and schema details
 -initSchema                        Schema initialization
 -initSchemaTo <initTo>             Schema initialization to a version
 -passWord <password>               Override config file password
 -upgradeSchema                     Schema upgrade
 -upgradeSchemaFrom <upgradeFrom>   Schema upgrade from a version
 -userName <user>                   Override config file user name
 -verbose                           only print SQL statements
{noformat}


We might have to change the conffile option in SentrySchemaTool to:
{noformat}
Option configOpt = OptionBuilder.withLongOpt(ServiceConstants.ServiceArgs.CONFIG_FILE_LONG)
        .withArgName("confName").hasArgs()
        .withDescription("Sentry Service configuration file").isRequired(true)
        .create(ServiceConstants.ServiceArgs.CONFIG_FILE_SHORT);
{noformat}

> Sentry server should use sentry-site.xml in conf directory by default
> ---------------------------------------------------------------------
>
>                 Key: SENTRY-361
>                 URL: https://issues.apache.org/jira/browse/SENTRY-361
>             Project: Sentry
>          Issue Type: Improvement
>    Affects Versions: 1.4.0
>            Reporter: Dapeng Sun
>            Assignee: Dapeng Sun
>             Fix For: 1.4.0
>
>         Attachments: SENTRY-361.patch, SENTRY-361_002.patch, SENTRY-361_003.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message