<div dir="ltr"><br><div>[pulp-dev] modularity upload<br><br>I was happy to see new unified way of upload already merged, but I think I got special use case for modularity. <br><br>Expected by upload from core is one file for one content unit. My case is the user will upload one file with many content units yet two content types can appear. I would like to discuss here some ideas hot to proceed in this case. <br><br>- Possibly this could be different endpoint as more than one content unit will by upload<br> - and possibly two content types<br> - I discuss this with Brian B. and to use original endpoint (../content/rpm/modulemd/) for upload can have advantage of less endpoints to maintain and still same logic but different behaviour <br>  - user should (not must be true) be aware of modularity types when storing them<br>  - still will be documented<br> - disadvantage is any other endpoint with upload use only one content unit (inconsistence)<br>  - because uploaded file is connected for both endpoints (modulemd - mddefaults)<br>  - and will need some discussion about name <br><br>- Still I would like to keep upload with chunks <br> - even official modules.yaml to parse from fedora 30 modular repo has ~500K<br><br>Summary:<br><br>In my opinion I would use same endpoint but override 'create' method to '../rpm/modulemd' will parse whole file and create many modulemd and even modulemd-deafult content types.<br>And highlight it in documentation.<br><br>For second content type and endpoint 'modulemd-defaults' I would not allow upload a file but allow user to create modulemd-defaults with arguments (as they are three) so user just call http:.../rpm/modulemd-defaults/ module=foo stream="1" profiles="1:default". As if there will be file with more defaults he can use previous endpoint for both. </div><div><br></div><div>What do you think or what would you like to see there?<br><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Pavel Picka</div><div>Red Hat<br></div></div></div></div>