[Pulp-list] pulp-admin unit upload synchronous in version 2.4?

Michael Hrivnak mhrivnak at redhat.com
Tue Jun 3 13:28:20 UTC 2014


Marco,

In pulp 2.4, the upload command will now block by default until the upload has completed. To be clear though, the server-side behavior has not changed. The task is still put in a queue and will run when other operations on the repository have completed. In 2.4, pulp-admin polls the server to read the task status and reports the task's result once it runs.

Michael

----- Original Message -----
From: "Marco Tirado" <Marco.Tirado.ext at netent.com>
To: pulp-list at redhat.com
Sent: Tuesday, June 3, 2014 7:31:31 AM
Subject: [Pulp-list] pulp-admin unit upload synchronous in version 2.4?



Hello pulp users: 



We are having some problems when uploading content to pulp using the pulp-admin CLI on pulp 2.3. The problem is that the upload command works asynchronously whenever the pulp is busy with the repository we are trying to upload to. 

Here is an example of the problem: 



Command Line is: /usr/bin/pulp-admin --username admin --password **** puppet repo uploads upload --repo-id my-test-repo -d /tmp/pkgmgr_modules_6788470441478233886 

13:24:13 [INFO] [0m+----------------------------------------------------------------------+ 

13:24:13 [INFO] Unit Upload 

13:24:13 [INFO] +----------------------------------------------------------------------+ 

13:24:13 [INFO] 

13:24:13 [INFO] Extracting necessary metadata for each request... 

13:24:13 [INFO] [93m[========================= ] 50%[0m 

13:24:13 [INFO] Analyzing: test.tar.gz 

13:24:13 [INFO] [2A[J[92m[==================================================] 100%[0m 

13:24:13 [INFO] Analyzing: test2.tar.gz 

13:24:13 [INFO] ... completed 

13:24:13 [INFO] 

13:24:13 [INFO] Creating upload requests on the server... 

13:24:13 [INFO] [93m[========================= ] 50%[0m 

13:24:13 [INFO] Initializing: test.tar.gz 

13:24:13 [INFO] [2A[J[92m[==================================================] 100%[0m 

13:24:13 [INFO] Initializing: test2.tar.gz 

13:24:13 [INFO] ... completed 

13:24:13 [INFO] 

13:24:13 [INFO] Starting upload of selected units. If this process is stopped through ctrl+c, 

13:24:13 [INFO] the uploads will be paused and may be resumed later using the resume command or 

13:24:13 [INFO] cancelled entirely using the cancel command. 

13:24:13 [INFO] 

13:24:13 [INFO] Uploading: test.tar.gz 

13:24:13 [INFO] [92m[==================================================] 100%[0m 

13:24:13 [INFO] 3790/3790 bytes 

13:24:13 [INFO] ... completed 

13:24:13 [INFO] 

13:24:13 [INFO] Importing into the repository... 

13:24:13 [INFO] Import postponed due to queued operations against the repository. The progress 

13:24:13 [INFO] of this import can be viewed in the repository tasks list. 

13:24:13 [INFO] 

13:24:13 [INFO] Uploading: test2.tar.gz 

13:24:13 [INFO] [92m[==================================================] 100%[0m 

13:24:13 [INFO] 3792/3792 bytes 

13:24:13 [INFO] ... completed 

13:24:13 [INFO] 

13:24:13 [INFO] Importing into the repository... 

13:24:13 [INFO] Import postponed due to queued operations against the repository. The progress 

13:24:13 [INFO] of this import can be viewed in the repository tasks list. 



We would like to have pulp-admin wait for the upload to be complete instead of just printing a warning when the import has been postponed. 

When looking at the code it seems like this has been fixed in the master branch: 



Pulp 2.3 => https://github.com/pulp/pulp/blob/pulp-2.3/client_lib/pulp/client/commands/repo/upload.py 

Master => https://github.com/pulp/pulp/blob/master/client_lib/pulp/client/commands/repo/upload.py 



We would like to know if this is fixed in pulp 2.4 beta to be able to decide if we have to implement this ourselves through the API or just roll out pulp 2.4 beta and check. 



BR 



Marco Tirado 





Marco Tirado 


Tools Engineer 

Net Entertainment NE AB, Luntmakargatan 18, SE-111 37, Stockholm, SE 
T: , M: , F: +46 8 578 545 10 
Marco.Tirado.ext at netent.com www.netent.com 

Better Games 



This email and the information it contains are confidential and may be legally privileged and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify me immediately. Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. You should not copy it for any purpose, or disclose its contents to any other person. Internet communications are not secure and, therefore, Net Entertainment does not accept legal responsibility for the contents of this message as it has been transmitted over a public network. If you suspect the message may have been intercepted or amended please call me. Finally, the recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email. Thank you. 

_______________________________________________
Pulp-list mailing list
Pulp-list at redhat.com
https://www.redhat.com/mailman/listinfo/pulp-list




More information about the Pulp-list mailing list