Uploaded image for project: 'Teiid Designer'
  1. Teiid Designer
  2. TEIIDDES-1234

Generate WAR action processes with workspace models instead of model entries in the selected VDB



      GenerateWarAction.selectionChanged() appears to be mixing apples and oranges. (See below)

      I think the intent was to get the VdbModelEntry objects and cache up a list of WS Models for later use generating the proper procedure calls/URLs??

      The colde below, however, is finding the corresponding ModelResource in the workspace for each entry, which could easily be "out of sync". Users would be unaware that the WAR they are creating might not be what they expect.

      wsModelResources = new ArrayList<ModelResource>();

      for (VdbModelEntry vdbModelEntry : modelEntrySet) {
      final ModelResource modelResource = ModelerCore.getModelWorkspace().findModelResource(vdbModelEntry.getName());
      if (ModelIdentifier.isWebServicesViewModel(modelResource))

      { enable = true; // Add to our ArrayList of ModelResources. These // will be used to generate the war artifacts. wsModelResources.add(modelResource); }


      So I think we either not allow users to perform this action if the VDB was "out of sync" (probably not the best option)


      Find another way to pass the model info necessary for the generator to perform whats needed.

      Note that in VdbEditor class there is an example of creating a "Temporary" EMF model container in order to interrogate the models. So I believe it should be possible.

        Gliffy Diagrams




              • Assignee:
                blafond Barry LaFond
                blafond Barry LaFond
              • Votes:
                0 Vote for this issue
                0 Start watching this issue


                • Created: