This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
1. Create Visual Web Application. 2. Add 4 new pages. Now it is 5 pages in application. 3. Add one 'Table' component to the each page. 4. Bind table from first page with table from Derby. 5. Bind table from second page with table from MySQL. 6. Bind table from third page with table from Oracle. 7. Bind table from fourth page with table from PointBase. 8. Bind table from fifth page with table from MS SQLServer. Note: Tables in DB must be from similar schemas. 9. Deploy application to GlassFish. Result: Connection pools only for Derby, MS SQLServer and PointBase are created. The rest of data sources are connected to PointBase's connection pool. But everything works fine.
This is a combination of both Visual Web pack / IDE /Server plugin While I am aware of how the IDE interacts with the plugin, I have no idea of VWP related flow. I need info on the API's being called by VWP when a table is bound to a db. What are the calls being made, what is the input etc. Any documents from VWP on how these things are implemented. Also, where can I get the binary for VWP for NB 5.5.1, step by step instructions on how to create this app and bindings to db Need more info.
1) Step by step instructions on how to create this app You can find instructions in description. 2) Bindings to db Just expand DB, click on table from DB and then click on 'Table' component. About other information You should probably ask John Baker.
I think this is a duplicate of this task 90264
Not exactly. If I will deploy application with one page and table on it, which is bound to one DB, connection pool will be created. For every DB. But if deploy application with databinding with many DBs, connection pools not for all Dbs are created, for some other DB's connection pools are used.
Please attach the project. John, at what point are calls made by VWP to create the required datasources. What is the api being called. Again, any pointers to VWP docs covering api's/ usecases. I don't want to spend time on tutorials on VWP features to figure out what happens and when.
Created attachment 39882 [details] Application
The attached app doesn't have a CP definition for Oracle or MySQL. Are there any messages in the IDE's log file that might give us a clue about this.... Either the plugin code failed to create the CP definitions OR the plugin did not get called to create the CP's... Since you say that you can create 5 apps that access each of the DBs (see desc5), I think there may be a bug in VWP, which prevents the CP definition creation from happening. Have you verified that the plugin is getting called and failing?
in 5.5.x, visualweb will not add connection pools if they exist on the server. To workaround this, the pools can be added manually through New->File/Folder Hope to resolve this in 6.0
John, could you take a look at this? It's probably not worth trying in 5.5.1, since we're mainly concerned about 6.0. Not clear whether the problem lies on the datasource end, or in the server plugins.
I created a new application and added rowsets for Oracle, MySQL, MSSQL Server, Derby by dragging and dropping unique database tables from each of these databases. As a result, connection pools for all databases were generated in sun-resources.xml , except for MySQL Then, I created a 2nd application with only a rowset from MySQL. As a result a connection pool was successfully created for MySQL Attached are sun-resources.xml from each project
Created attachment 45480 [details] sun-resources for MySQL
Created attachment 45481 [details] generated sun-resources for multiple databases
visualweb update data sources using updateProjectDataSource(Project project, RequestedJdbcResource req) in org.netbeans.modules.visualweb.project.jsf.services.DesignTimeDataSourceServiceImpl.java J2eeModuleProvider jmp = (J2eeModuleProvider)project.getLookup().lookup(J2eeModuleProvider.class); jmp.getConfigSupport().createDatasource(req.getResourceName(), req.getUrl(), req.getUsername(), req.getPassword(), req.getDriverClassName()); Logic is the same for all databases. It's odd that a connection pool can be created for MySQL if it's the only database. Note, no MySQL connection pool had been created in the server. jmp.getConfigSupport().createDatasource(...) will create a data source regardless whether it had been created on the server Note, all projects created with Glassfish as the target server.
This seems to be a serverplugin issue. visualweb has no limitation for creating multiple data sources from multiple databases
I have made some fixes to the resource creation code in the plugin. I am not able to reproduce this issue. John, Could you test it and check whether this issue is still present?
Verified with build 070803.
*** Issue 94096 has been marked as a duplicate of this issue. ***