This is an automated email from the ASF dual-hosted git repository.

oleewere pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ambari.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 0f73761  AMBARI-23421. ADDENDUM: fix spaces before content type header
0f73761 is described below

commit 0f73761e28a51d84bc84f6f6a6451fdc3df06c19
Author: Oliver Szabo <[email protected]>
AuthorDate: Thu Apr 5 15:38:23 2018 +0200

    AMBARI-23421. ADDENDUM: fix spaces before content type header
---
 .../ambari-infra-solr-client/src/main/python/solrDataManager.py       | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/ambari-infra/ambari-infra-solr-client/src/main/python/solrDataManager.py 
b/ambari-infra/ambari-infra-solr-client/src/main/python/solrDataManager.py
index 5dfbdf6..33146c1 100755
--- a/ambari-infra/ambari-infra-solr-client/src/main/python/solrDataManager.py
+++ b/ambari-infra/ambari-infra-solr-client/src/main/python/solrDataManager.py
@@ -688,14 +688,14 @@ def upload_file_local(upload_command, upload_file_path, 
local_path):
 
 def upload_file_to_solr(solr_kinit_command, curl_prefix, upload_command, 
upload_file_path, collection):
   if os.path.isfile(upload_file_path):
-    query_solr(solr_kinit_command, upload_command, "{0}-H 
Content-type:application/json {1}".format(curl_prefix, upload_command), 
"Saving")
+    query_solr(solr_kinit_command, upload_command, "{0} -H 
Content-type:application/json {1}".format(curl_prefix, upload_command), 
"Saving")
     logger.info("Save data to collection: %s", collection)
 
 def delete_data(solr_kinit_command, curl_prefix, delete_command, collection, 
filter_field, id_field, prev_lot_end_value,
                 prev_lot_end_id):
   delete_cmd = delete_command.split(" --data-binary")[0]
   delete_query_data = delete_command.split("--data-binary ")[1].replace("+", " 
")
-  query_solr(solr_kinit_command, delete_cmd, "{0}-H Content-Type:text/xml 
{1}".format(curl_prefix, delete_cmd), "Deleting", delete_query_data)
+  query_solr(solr_kinit_command, delete_cmd, "{0} -H Content-Type:text/xml 
{1}".format(curl_prefix, delete_cmd), "Deleting", delete_query_data)
   logger.info("Deleted data from collection %s where %s,%s < %s,%s", 
collection, filter_field, id_field, prev_lot_end_value,
               prev_lot_end_id)
 

-- 
To stop receiving notification emails like this one, please contact
[email protected].

Reply via email to