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.

Bug 143382 - Tighten bundle integration
Summary: Tighten bundle integration
Status: RESOLVED INCOMPLETE
Alias: None
Product: installer
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@installer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-09 20:33 UTC by Vince Kraemer
Modified: 2008-09-12 18:27 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vince Kraemer 2008-08-09 20:33:26 UTC
In the 6.1/V2ur2/MySQL bundle, there are a couple things that would make the integration "better"

1. pre-install the MySQL driver in the GF distribution.
2. pre-configure the test DB as a connection pool and jdbc resource in the GF distribution.

Some of this could be addressed by using the V2ur2/MySQL bundle as the basis for triple bundle... (they solved item 1 in
that bundle).  I filed https://glassfish.dev.java.net/issues/show_bug.cgi?id=5454, so they may resolve item 2 in a
future release.
Comment 1 dlipin 2008-08-10 09:04:26 UTC
> 1. pre-install the MySQL driver in the GF distribution.
We do that, actually. We put the driver file (MySQL Connector/J 5.1.6) in the "lib" folder in glassfish dir.

> 2. pre-configure the test DB as a connection pool and jdbc resource in the GF distribution.
What should be done for that? I am interested in the command line that should be executed.

> Some of this could be addressed by using the V2ur2/MySQL bundle as the basis for triple bundle... (they solved item 1 
in that bundle).  
Sorry, we use another basis ;)
Comment 2 dlipin 2008-09-12 15:29:07 UTC
Vince, could you please update the issue with required information?

Thanks,
Dmitry
Comment 3 Vince Kraemer 2008-09-12 18:27:45 UTC
1. the glassfish-v2ur2wmysql/lib/mysql-connector-java-5.1.6-bin.jar should be placed in
glassfish-v2ur2wmysql/domains/domain1/lib.
   this will prevent a file copy and server restart as users start to do development.

2. a connection pool should be created in domain1/config/domain.xml

    <jdbc-connection-pool allow-non-component-callers="false" associate-with-thread="false"
connection-creation-retry-attempts="0" connection-creation-retry-interval-in-seconds="10"
connection-leak-reclaim="false" connection-leak-timeout-in-seconds="0" connection-validation-method="auto-commit"
datasource-classname="com.mysql.jdbc.jdbc2.optional.MysqlDataSource" fail-all-connections="false"
idle-timeout-in-seconds="300" is-connection-validation-required="false" is-isolation-level-guaranteed="true"
lazy-connection-association="false" lazy-connection-enlistment="false" match-connections="false"
max-connection-usage-count="0" max-pool-size="32" max-wait-time-in-millis="60000" name="MySQLPool"
non-transactional-connections="false" pool-resize-quantity="2" res-type="javax.sql.DataSource"
statement-timeout-in-seconds="-1" steady-pool-size="8" validate-atmost-once-period-in-seconds="0" wrap-jdbc-objects="false">
      <property name="Password" value=""/>
      <property name="URL" value="jdbc:mysql://localhost:3306/test"/>
      <property name="User" value="root"/>
    </jdbc-connection-pool>

The command to do this is:

    asadmin create-jdbc-connection-pool --datasourceclassname com.mysql.jdbc.jdbc2.optional.MysqlDataSource --property
URL="jdbc\:mysql\://localhost\:3306/test":User=root:Password="()" MySQLPool

3. a jdbc resource should be created in domain1/config/domain.xml

    <jdbc-resource enabled="true" jndi-name="jdbc/mysql" object-type="user" pool-name="MySQLPool"/>

The command to do this is:

   asadmin create-jdbc-resource --connectionpoolid MySQLPool jdbc/mysql