public ValidatorReport validate(VDBMetaData vdb, MetadataStore store) { ValidatorReport report = new ValidatorReport(); if (store != null && !store.getSchemaList().isEmpty()) { new SourceModelArtifacts().execute(vdb, store, report, this); new CrossSchemaResolver().execute(vdb, store, report, this); new ResolveQueryPlans().execute(vdb, store, report, this); new MinimalMetadata().execute(vdb, store, report, this); new MatViewPropertiesValidator().execute(vdb, store, report, this); } return report; }
public ValidatorReport validate(VDBMetaData vdb, MetadataStore store) { ValidatorReport report = new ValidatorReport(); if (store != null && !store.getSchemaList().isEmpty()) { new SourceModelArtifacts().execute(vdb, store, report, this); new CrossSchemaResolver().execute(vdb, store, report, this); new ResolveQueryPlans().execute(vdb, store, report, this); new MinimalMetadata().execute(vdb, store, report, this); new MatViewPropertiesValidator().execute(vdb, store, report, this); } return report; }
@Test public void testViewModelArtifacts() throws Exception { String ddl = "create foreign table g1(e1 integer, e2 varchar(12)); create view g2(e1 integer, e2 varchar(12)) AS select * from foo;"; buildModel("vm1", false, this.vdb, this.store, ddl); ValidatorReport report = new ValidatorReport(); new MetadataValidator.SourceModelArtifacts().execute(vdb, store, report, new MetadataValidator()); assertTrue(printError(report), report.hasItems()); }
@Test public void testSourceModelArtifacts() throws Exception { String ddl = "create foreign table g1(e1 integer, e2 varchar(12)); create view g2(e1 integer, e2 varchar(12)) AS select * from foo;"; buildModel("pm1", true, this.vdb, this.store, ddl); ValidatorReport report = new ValidatorReport(); new MetadataValidator.SourceModelArtifacts().execute(vdb, store, report, new MetadataValidator()); assertFalse(printError(report), report.hasItems()); }
public ValidatorReport validate(VDBMetaData vdb, MetadataStore store) { ValidatorReport report = new ValidatorReport(); if (store != null && !store.getSchemaList().isEmpty()) { new SourceModelArtifacts().execute(vdb, store, report, this); new CrossSchemaResolver().execute(vdb, store, report, this); new ResolveQueryPlans().execute(vdb, store, report, this); new MinimalMetadata().execute(vdb, store, report, this); new MatViewPropertiesValidator().execute(vdb, store, report, this); } return report; }
@Test public void testModelArtifactsSucess() throws Exception { buildModel("vm1", false, this.vdb, this.store, "create view g2(e1 integer, e2 varchar(12)) AS select * from foo;"); buildModel("pm1", true, this.vdb, this.store, "create foreign table g1(e1 integer, e2 varchar(12));"); ValidatorReport report = new ValidatorReport(); new MetadataValidator.SourceModelArtifacts().execute(vdb, store, report, new MetadataValidator()); assertFalse(printError(report), report.hasItems()); }