Are supplying metadata via the native (default) method and is the ExecutionFactory marked as requiring a connection for metadata load? Then an exception would be expected. Or are you specifying the metadata via ddl and have set the schema source type to "ddl" / using some other custom metadata repository?
I am adding a code snippet
server = newEmbeddedServer();.start(ec);
finalModelMetaData schemaModel = newModelMetaData();
What does the ResourceAccessExecutionFactory return for isSourceRequiredForMetadata and isSourceRequired? You should also use an null rather than an empty string for the source name. If a source is not required at all, then you should be calling setSourceRequired(false) in your constructor or start method.
We are calling in the start method
When we give null as the source name, we are getting the same result.
Ah that would explain it. When you pass an actual instance to addTranslator we assume that start will already have been called.
Thanks, the problem is solved with adding the methods in the constructor instead of the start method. However, I would like to know if there is a way
we can deploy vdb xml in a embedded server as we do in the server. The idea is to simulate the server in the embedded server as closely as possible.
Just to make sure, you'll want to call start() prior to registering the translator if there is anything that needs to happen via the start method.
We will likely add an xml based vdb deployment for Embedded in 8.4, we had wanted to keep the deployment as minimalistic as possible initially.