----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/42021/#review113971 -----------------------------------------------------------
ambari-common/src/main/python/resource_management/libraries/providers/hdfs_resource.py (line 25) <https://reviews.apache.org/r/42021/#comment174768> You only implemented this behaviour for webhdfs resource, but will if webhdfs is turned of the hdfsResource will fail. ambari-common/src/main/python/resource_management/libraries/providers/hdfs_resource.py (line 297) <https://reviews.apache.org/r/42021/#comment174766> This time now efficient image having a lot of files there. curl can put multiple files at a connection. Can we put all at one connection by specifying multiple -T cstm-hdfs@test-ss-u14-dev-kerb-mit-3-2:~$ curl -sS -L -w '%{http_code}' -X PUT -T /usr/hdp/2.4.0.0-57/hadoop/mapreduce.tar.gz -T /tmp/1 --negotiate -u : 'http://test-ss-u14-dev-kerb-mit-3-5.novalocal:50070/webhdfs/v1/hdp/apps/2.4.0.0-57/mapreduce/mapreduce?op=CREATE&user.name=cstm-hdfs&overwrite=True&permission=444' ambari-common/src/main/python/resource_management/libraries/providers/hdfs_resource.py (line 298) <https://reviews.apache.org/r/42021/#comment174767> This is conter intuitive to ignore directories, I don't the person which uses this resource later would be happy with this behaviour. - Andrew Onischuk On Jan. 12, 2016, 8:26 a.m., yao lei wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/42021/ > ----------------------------------------------------------- > > (Updated Jan. 12, 2016, 8:26 a.m.) > > > Review request for Ambari and Andrew Onischuk. > > > Bugs: AMBARI-14536 > https://issues.apache.org/jira/browse/AMBARI-14536 > > > Repository: ambari > > > Description > ------- > > In some cases,we need to copy local matching wildcard files to hdfs. > eg. we'd like to copy /usr/lib/spark*.jar to hdfs by following codes in > Python: > params.HdfsResource(hdfs_path, > type="file", > action="create_on_execute", > source="/usr/lib/spark*.jar", > group=params.user_group, > owner=params.pdm_user, > mode=0755 > ) > params.HdfsResource(None, action="execute") > > > Diffs > ----- > > > ambari-common/src/main/python/resource_management/libraries/providers/hdfs_resource.py > 731bce7 > > Diff: https://reviews.apache.org/r/42021/diff/ > > > Testing > ------- > > Manually Tested. > > > Thanks, > > yao lei > >
