AppFuse 3.5 and Database Profiles

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

AppFuse 3.5 and Database Profiles

bdepaola
I recently downloaded AppFuse 3.5 and noticed the pom.xml is a lot shorter than pervious versions.  One of the first things I noticed was the database profiles are no longer available.  I have a new machine and was hoping to run the application without installing MySQL, so figured I'd use derby or some other Java based database.  I've looked and looked and can't figure out, or understand, how I can get AppFuse to work with other database profiles.  And even more confusing is it seems like the MySQL database properties show up in the "target" directory automatically after running the "mvn" command.  I think the pom.xml is throwing me for a big loop...  So, I guess my questions would be:

1. Where are the default MySQL properties specified/configured?
2. How do I use AppFuse 3.5 with a different database profile (derby, H2, HSQLDB, etc)?
3. Is there documentation on the appfuse.org website that I've overlooked?

Thank you very much in advance and I really appreciate all the work that's been put into this framework.  I've never seen anything like it and it's a really cool learning tool for amateur folks such as myself.

Regards,
Bryan    
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: AppFuse 3.5 and Database Profiles

mraible
Administrator
The QuickStart Guide has a section on changing your database settings. 


All the profiles should still be there, they're just inherited from the parent pom. I've copied and pasted the relevant section for changing your db settings below.

Changing database settings

Icon

To change your MySQL database settings, simply override the <jdbc.*> properties at the bottom of your pom.xml. There are a number of default profiles available as well. Run "mvn help:all-profiles" to see the built-in profiles. Below is a list of the default jdbc properties that you can override.

<jdbc.groupId>mysql</jdbc.groupId>
<jdbc.artifactId>mysql-connector-java</jdbc.artifactId>
<jdbc.version>5.1.27</jdbc.version>
<jdbc.driverClassName>com.mysql.jdbc.Driver</jdbc.driverClassName>
<jdbc.url>
    <![CDATA[jdbc:mysql://localhost/${db.name}?createDatabaseIfNotExist=true&amp;useUnicode=true&amp;characterEncoding=utf-8&amp;autoReconnect=true]]>
</jdbc.url>
<jdbc.username>root</jdbc.username>
<jdbc.password/>
<jdbc.validationQuery><![CDATA[SELECT 1 + 1]]></jdbc.validationQuery>

On Mon, Mar 2, 2015 at 9:58 PM, bdepaola <[hidden email]> wrote:
I recently downloaded AppFuse 3.5 and noticed the pom.xml is a lot shorter
than pervious versions.  One of the first things I noticed was the database
profiles are no longer available.  I have a new machine and was hoping to
run the application without installing MySQL, so figured I'd use derby or
some other Java based database.  I've looked and looked and can't figure
out, or understand, how I can get AppFuse to work with other database
profiles.  And even more confusing is it seems like the MySQL database
properties show up in the "target" directory automatically after running the
"mvn" command.  I think the pom.xml is throwing me for a big loop...  So, I
guess my questions would be:

1. Where are the default MySQL properties specified/configured?
2. How do I use AppFuse 3.5 with a different database profile (derby, H2,
HSQLDB, etc)?
3. Is there documentation on the appfuse.org website that I've overlooked?

Thank you very much in advance and I really appreciate all the work that's
been put into this framework.  I've never seen anything like it and it's a
really cool learning tool for amateur folks such as myself.

Regards,
Bryan



--
View this message in context: http://appfuse.547863.n4.nabble.com/AppFuse-3-5-and-Database-Profiles-tp4657733.html
Sent from the AppFuse - User mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: AppFuse 3.5 and Database Profiles

bdepaola
Thank you very much for the reply.  You got me moving in the right direction and I was able to override the database properties per your instructions.

Thanks again,
Bryan  
Loading...