-
1. Re: Programmatically Creating VDB
rareddy Mar 18, 2013 12:02 PM (in response to pinkstondevin)1 of 1 people found this helpfulDevin,
Yes, as of 8.3. See TestVDBMetaData for mashelling/unmarshell as JAXB annotations are not present on the VDBMetadata. Also note VDBMetadata is not part public API can change in future releases without notification.
Ramesh..
-
2. Re: Programmatically Creating VDB
pinkstondevin Mar 19, 2013 8:52 AM (in response to rareddy)Ramesh,
If i plan to deploy the vdb using the admin console, do i need to create an admin programmatically as well? Can i create and set the metadata of a VDB without the creation of an admin?
Thanks.
-
3. Re: Programmatically Creating VDB
rareddy Mar 19, 2013 9:20 AM (in response to pinkstondevin)1 of 1 people found this helpfulDevin,
You can programatically deploy the VDB too, so that you can automate the whole process. Teiid supports creating a "admin" connection, once the connection is created then you have access to variety of calls available on this interface. You can get "admin" connection using AdminFactory. You can some test examples here.
HTH
Ramesh..
-
4. Re: Programmatically Creating VDB
pinkstondevin Mar 19, 2013 10:05 AM (in response to rareddy)Ramesh,
Thanks! I didn't see those tests, they are very helpful, I appreciate it.
I've been reading through them for about 30 minutes, good stuff in here. Are there any tests defining a VDB and its metadata?
The admin tests are great.
Thanks
-
5. Re: Programmatically Creating VDB
rareddy Mar 19, 2013 10:15 AM (in response to pinkstondevin)Devin,
You seen the test to create the -vdb.xml already. The only remaining question is how you can define the metadata for your VDB and sources. This should give you a better example on how to define metadata for your view model in VDB https://docs.jboss.org/author/display/TEIID/DDL+Metadata
My suggestion is go through a quick example, as to how Teiid works. Then go about building the VDB programmatically.
Ramesh..
-
6. Re: Programmatically Creating VDB
pinkstondevin Mar 20, 2013 1:20 PM (in response to rareddy)Thank you Ramesh.
I went through the documentation online and worked through the quickstart as well.
I decided it would be a good first test to try and programmatically do the federation quick start ,using the same datasources. However when I try to create a new admin in my standalone application, i keep receiving this:
Mar 20, 2013 1:13:22 PM org.xnio.Xnio <clinit>
INFO: XNIO Version 3.0.7.GA
Mar 20, 2013 1:13:22 PM org.teiid.adminapi.AdminFactory createAdmin
INFO: TEIID70051 The controller is not available at localhost:9,999
There was another person on here who had the same problem, but their work didnt seem to help.
Any insight?
Thanks
-
7. Re: Programmatically Creating VDB
rareddy Mar 20, 2013 2:54 PM (in response to pinkstondevin)It depends on how you started your server. Or it can be that your Admin application and server are not on the same machine. Provide the correct host, port to the Admin connection then it will work.