[
https://issues.jboss.org/browse/TEIID-4321?page=com.atlassian.jira.plugin...
]
Van Halbert commented on TEIID-4321:
------------------------------------
how's this:
{code}
List<Column> matViewColumns = matTable.getColumns();
List<Column> tableColumns = table.getColumns();
// the table must have at least the same number of columns as the matview
if(matViewColumns.size() > tableColumns.size()) {
metadataValidator.log(report, model,
QueryPlugin.Util.gs(QueryPlugin.Event.TEIID31193, table.getName(), matTable.getName()));
}
for (Column mc : matViewColumns) {
Column tc = table.getColumnByName(mc.getName());
if (tc == null) {
metadataValidator.log(report, model,
QueryPlugin.Util.gs(QueryPlugin.Event.TEIID31203, mc.getName(), matTable.getName(),
table.getName()));
}
if(!mc.getDatatypeUUID().equals(tc.getDatatypeUUID())){
metadataValidator.log(report, model,
QueryPlugin.Util.gs(QueryPlugin.Event.TEIID31194, tc.getName(), table.getName(),
mc.getName(), matTable.getName()));
}
}
}
TEIID31193=Table {0}'s columns size is smaller than the Materialized View {1}'s
columns size
TEIID31203=Column {0} in Materialized View {1} was not found in table {2}
{code}
VDB Validation is showing warnings, but failing deployment
----------------------------------------------------------
Key: TEIID-4321
URL:
https://issues.jboss.org/browse/TEIID-4321
Project: Teiid
Issue Type: Bug
Components: Query Engine
Affects Versions: 9.x
Reporter: Van Halbert
Assignee: Steven Hawkins
The deployment of a vdb is failing due to 2 warnings:
13:29:01,076 WARN [org.teiid.PLANNER.RESOLVER] (Worker2_async-teiid-threads4)
TEIID31193 Table Persons columns size not same as Materialized View {1}s columns size
13:29:01,077 WARN [org.teiid.PLANNER.RESOLVER] (Worker2_async-teiid-threads4)
TEIID31194 Column PersonObject in Table Person and Column name in Materialized View
PersonMatView should have same type
13:29:01,080 INFO [org.teiid.RUNTIME] (Worker2_async-teiid-threads4) TEIID40073 The
metadata for the VDB PeopleMat.1 is loaded, however it is not valid. Check models for
errors. Correct the metadata and re-deploy.
13:29:01,080 INFO [org.teiid.RUNTIME.VDBLifeCycleListener]
(Worker2_async-teiid-threads4) TEIID40003 VDB PeopleMat.1 is set to FAILED
I changed the MetadataValidator class to remove the warnings and the VDB deployed ok.
If an issue is going to fail deployment, shouldn't it be on an ERROR?
Regarding the warnings:
1. regarding column size, is it required that all columns in the materialized table to
be writable?
2. the 2nd warning was due to the 1st warning.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)