[
https://issues.jboss.org/browse/TEIIDDES-2120?page=com.atlassian.jira.plu...
]
Barry LaFond edited comment on TEIIDDES-2120 at 6/13/14 9:36 AM:
-----------------------------------------------------------------
The final fix for TEIIDDES-2120 and TEIIDDES-1945 involved re-arranging the contents of a
VDB and underlying *vdb.xml* that was allowing *XSD* files to be treated as *models*.
Teiid runtime engine has ignored *XSD* files and their corresponding *INDEX* files, so
they aren't used as runtime metadata.
These XSD files are still needed for complete VDB validation (*EMF requires it*), so per
the attached screencap, any dependent schema (*XSD*) files are still added to a VDB but
placed in their own *Schemas* tab and treated as a special user-file.
To test this issue
1) Create and preview any source table
2) Select source model and right-click select *Modeling > Create Web Service*
3) Select and preview a newly created web service model *operation*
-- The SQL Results *Status* tab should contain the auto-generated SQL query you can
use in step 7 below
-- Note the XML output result
4) Select the Web Service model and create a VDB
5) You'll either have 1 or 2 *XSD* files (input and output) that should be added to
the *Schemas* tab in the VDB Editor
6) Save VDB, select VDB in explorer and right-click *Execute VDB*
7) Select the SQL query generated in step 3 above, paste in SQL Scrapbook, select the text
and right-click select "Execute Selected Text"
8) XML Output should be the same as the preview date from step 3 above
The attached Books_WS_and_XML.zip model project set also contains a VDB containing a
Books.xsd schema file as well as a Books.xmi source model file. Opening this VDB verifies
that the duplicate name issue with differing extensions is fixed.
was (Author: blafond):
The final fix for TEIIDDES-2120 and TEIIDDES-1945 involved re-arranging the contents of a
VDB and underlying *vdb.xml* that was allowing *XSD* files to be treated as *models*.
Teiid runtime engine has ignored *XSD* files and their corresponding *INDEX* files, so
they aren't used as runtime metadata.
These XSD files are still needed for complete VDB validation (*EMF requires it*), so per
the attached screencap, any dependent schema (*XSD*) files are still added to a VDB but
placed in their own *Schemas* tab and treated as a special user-file.
To test this issue
1) Create and preview any source table
2) Select source model and right-click select *Modeling > Create Web Service*
3) Select and preview a newly created web service model *operation*
-- The SQL Results *Status* tab should contain the auto-generated SQL query you can
use in step 7 below
-- Note the XML output result
4) Select the Web Service model and create a VDB
5) You'll either have 1 or 2 *XSD* files (input and output) that should be added to
the *Schemas* tab in the VDB Editor
6) Save VDB, select VDB in explorer and right-click *Execute VDB*
7) Select the SQL query generated in step 3 above, paste in SQL Scrapbook, select the text
and right-click select "Execute Selected Text"
8) XML Output should be the same as the preview date from step 3 above
unable to reference same name .xsd when saving .vdb
---------------------------------------------------
Key: TEIIDDES-2120
URL:
https://issues.jboss.org/browse/TEIIDDES-2120
Project: Teiid Designer
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: VDB & Execution
Affects Versions: 8.3
Reporter: Johnathon Lee
Assignee: Paul Richardson
Priority: Blocker
Fix For: 8.5, 8.3.3
Attachments: Books_2120.vdb, Books_TEIIDDES_2120.zip, Books_WS_and_XML.zip,
excute-ws-text-in-scrapbook.png, Test_2120.zip, vdb-schemas-tab.png,
ws-preview-sql-results-status.png
User can no longer add same name .xsd to a vdb (name same, location(s) different).
Results in:
java.lang.RuntimeException: javax.xml.bind.UnmarshalException
- with linked exception:
[org.xml.sax.SAXParseException; lineNumber: 61; columnNumber: 168; Duplicate unique value
[<name>] declared for identity constraint of element "vdb".]
at
org.teiid.core.designer.CoreModelerPlugin.toRuntimeException(CoreModelerPlugin.java:76)
at org.teiid.core.designer.util.OperationUtil.perform(OperationUtil.java:50)
at org.teiid.designer.vdb.VdbUtil.getVdbManifest(VdbUtil.java:178)
at org.teiid.designer.vdb.VdbUtil.isPreviewVdb(VdbUtil.java:120)
at
org.teiid.designer.runtime.preview.PreviewManager.isPreviewVdb(PreviewManager.java:267)
at
org.teiid.designer.runtime.preview.PreviewManager.findPvdbs(PreviewManager.java:656)
at
org.teiid.designer.runtime.preview.PreviewManager.handleModelProjectOpened(PreviewManager.java:895)
at org.teiid.designer.runtime.preview.PreviewManager.done(PreviewManager.java:466)
at org.eclipse.core.internal.jobs.JobListeners$3.notify(JobListeners.java:39)
at org.eclipse.core.internal.jobs.JobListeners.doNotify(JobListeners.java:112)
at org.eclipse.core.internal.jobs.JobListeners.done(JobListeners.java:152)
at org.eclipse.core.internal.jobs.JobManager.endJob(JobManager.java:647)
at org.eclipse.core.internal.jobs.WorkerPool.endJob(WorkerPool.java:105)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:70)
Caused by: javax.xml.bind.UnmarshalException
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)