It's all about the answers!

Ask a question

Howto upload and download a picture of a user by a script over Rest API?


Guido Schneider (3.4k1486115) | asked Jan 05 '13, 11:14 a.m.
Unfortunatly Jazz is storing the pictures of a user in the same format and size than the user has uploaded it. Many user are not able or to lazy to read that the picture should be croped to 100x100 pixel so the image is not larger than 4kByte. I saw pictures up to 10MByte!!

If you now have e.g. a sprint plan with pictures of the team members and this pictures are several 100kBytes or megabytes the load of the plan is slowing down dramatically over remote lines. If they are not cached locally or in a proxy server, they will be loaded at each browser refresh.

Of course it would be very elegant, if the upload function of the picture would store a thumbnail of the picture with 100x100 pixels and in JPG format, but this is not the case yet. (Maybe I will write an enhancement request if thjere is not already one)

I would like to write a scripts (perl if possible) to download all pictures of the users where the size is larger than e.g. 10kB, crop them to 100x100pixels, store it as JPG and upload it back to JTS.
This job I like to run regularly on the windows scheduler.

Is there a documented or undocumented REST interface where I can do this?
If not possible over a script, can you provide me the entry point for the Jazz API? It must not be an official interface.


Comments
Geoffrey Clemm commented Jan 06 '13, 6:06 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Guido Schneider commented Jan 07 '13, 10:38 a.m.

Thanks for the link. I gave my comments.

I would still like to get information about an REST-API or JAVA-API function for down and upload the picture of a user, because we have hunderts of pictures already in the system. And it looks like the new functionality will work on upload of a new picture, so all pictures already in the DB will remain at current size.


Ralph Schoon commented Jan 07 '13, 12:34 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Hi Guido,

I looked into it today. I had the piece for downloading already. I managed to upload images today. I will try to blog about it tomorrow and attach a link here.

Accepted answer


permanent link
Ralph Schoon (63.1k33646) | answered Jan 08 '13, 9:51 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Guido, please see this post for API code that worked for me: http://rsjazz.wordpress.com/2013/01/08/maintaing-user-photos-with-the-plain-java-client-libraries/
Guido Schneider selected this answer as the correct answer

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.