Uploaded image for project: 'CloudStack'
  1. CloudStack
  2. CLOUDSTACK-7153

addNicToVirtualMachine not BaseAsyncCreate but creates an entity

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 4.4.0
    • 4.5.0
    • Management Server
    • Security Level: Public (Anyone can view this level - this is the default.)
    • None

    Description

      addNicToVirtualMachine not BaseAsyncCreate but creates an entity.
      We need them to be BaseAsyncCreate so that Eventbus while publishing the completed events can put in the entity id. Right now there is a generic logic where after create function when the id is created its pushed into the context so that Eventbus can use it to publish the created UUID. If its not baseAsyncCreate you will have to go into each api and put the id in the context.
      Currently following is the generic code had put in ApiServer.java. We will have to do specifically into your api. Do this only if there is a hard reason not to make it baseasyncCreate
      Class entityClass = EventTypes.getEntityClassForEvent(createCmd.getEventType());
      if (entityClass != null)
      ctx.putContextParameter(entityClass.getName(), objectId);

      Attachments

        Activity

          People

            damoder.reddy Damodar Reddy T
            damoder.reddy Damodar Reddy T
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: