You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by GitBox <gi...@apache.org> on 2022/11/08 20:18:38 UTC

[GitHub] [cloudstack-go] mlsorensen opened a new issue, #43: Adding multiple details to registerTemplate, updateTemplate doesn't work

mlsorensen opened a new issue, #43:
URL: https://github.com/apache/cloudstack-go/issues/43

   When making a `registerTemplate` or `updateTemplate` API call, the accepted API format for the map is to always use `details[0]`.  Otherwise, the other fields don't work. Currently we increment an iterator in the client and it causes the API to ignore all but the first detail.
   
   e.g.
   
   ```
   (localhost) 🐱 > register template name=test displaytext=test hypervisor=Simulator url=http://foo.com/image.vhd format=vhd zoneid=-1 ostypeid=da13519b-5491-11ed-820c-0242ac120002 details[0].uefi=legacy details[1].other=foo
   {
     "count": 1,
     "template": [
       {
         "account": "admin",
         "bits": 0,
         "created": "2022-11-08T20:13:59+0000",
         "crossZones": true,
         "deployasis": false,
         "details": {
           "uefi": "legacy"
         },
   ```
         
    The above is missing the "other" detail.  Compare with:
    
    ```
    (localhost) 🐱 > register template name=test displaytext=test hypervisor=Simulator url=http://foo.com/image.vhd format=vhd zoneid=-1 ostypeid=da13519b-5491-11ed-820c-0242ac120002 details[0].uefi=legacy details[0].other=foo
   {
     "count": 1,
     "template": [
       {
         "account": "admin",
         "bits": 0,
         "created": "2022-11-08T20:14:27+0000",
         "crossZones": true,
         "deployasis": false,
         "details": {
           "other": "foo",
           "uefi": "legacy"
         },
    ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@cloudstack.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [cloudstack-go] rohityadavcloud closed issue #43: Adding multiple details to registerTemplate, updateTemplate doesn't work

Posted by GitBox <gi...@apache.org>.
rohityadavcloud closed issue #43: Adding multiple details to registerTemplate, updateTemplate doesn't work
URL: https://github.com/apache/cloudstack-go/issues/43


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [cloudstack-go] rohityadavcloud commented on issue #43: Adding multiple details to registerTemplate, updateTemplate doesn't work

Posted by GitBox <gi...@apache.org>.
rohityadavcloud commented on issue #43:
URL: https://github.com/apache/cloudstack-go/issues/43#issuecomment-1308303427

   That's a known historic limitation, all details use the zero key in the API call. Thanks for the PR @mlsorensen 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org