-
1. Re: options for jpa-generate-entities-from-tables
gastaldi Sep 25, 2016 6:09 PM (in response to gerry.matte)Hi Gerry,
1) In Forge 3, the option names were changed to a unix-like case: (eg. --targetPackage is now --target-package), maybe that's why it is prompting you again?
2) No idea on that, that should happen only if you run scaffold-generate or scaffold-setup afaik.
3) This could be related to #1?
I'll try to reproduce it nevertheless. Let me know how it goes. Forge 2.x has been superceeded by Forge 3.x, so I'd suggest you to try it with 3.3.1.Final
Best Regards,
George Gastaldi
-
2. Re: options for jpa-generate-entities-from-tables
gerry.matte Sep 25, 2016 6:52 PM (in response to gastaldi)Thanks for the quick response George.
I'd like to use the current release - what are the option names now ?
Gerry
-
3. Re: options for jpa-generate-entities-from-tables
gastaldi Sep 25, 2016 7:18 PM (in response to gerry.matte)If you type jpa-generate-entities-from-tables and press <TAB> you'll see the available options. I don't recall from the top of my head but they are the same except following the new nomenclature (eg. --database-tables instead of --databaseTables, etc)
-
4. Re: options for jpa-generate-entities-from-tables
gerry.matte Sep 25, 2016 9:56 PM (in response to gastaldi)Using Forge 3,3,1,Final not all required options appear using the <tab> key :
--connection-profile --driver-location --jdbc-url --target-package --user-password --driver-class --hibernate-dialect --save-user-password --user-name --verify-connection The most important option missing is
--database-tables *
The correct results were obtained using:
jpa-generate-entities-from-tables --database-tables * --target-package ca.gerrymatte.health.model --hibernate-dialect org.hibernate.dialect.MySQL5InnoDBDialect --driver-class com.mysql.jdbc.Driver --driver-location D:/s/jclasses/drivers/mysql.jar --user-name root --user-password secret --jdbc-url jdbc:mysql://127.0.0.1/health?autoReconnect=true&zeroDateTimeBehavior=convertToNull&useSSL=false ;
Sun Sep 25 18:42:21 PDT 2016 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
Sun Sep 25 18:42:23 PDT 2016 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
***SUCCESS*** 6 entities were generated in ca.gerrymatte.health.model
-
5. Re: options for jpa-generate-entities-from-tables
gastaldi Sep 26, 2016 9:39 AM (in response to gerry.matte)Hi Gerry,
--database-tables will only be shown after the JDBC connection info is set (--jdbc-url or --connection-profile). If you invoke it in a GUI environment, you'll see that the Database tables will be shown after you press Next (which is disabled until you set the JDBC URL or choose a Connection profile)
Best Regards
-
6. Re: options for jpa-generate-entities-from-tables
gerry.matte Sep 26, 2016 10:31 AM (in response to gastaldi)The statement which succeeded for me in a command line window begins with jpa-generate-entities-from-tables --database-tables *
I don't understand your comment ..... if I did not specify database-tables interactive mode kicks in and the option database-tables is not prompted for.
So, it's not possible to succeed if interactive mode is triggered.
I suspect this is a bug.
Gerry
-
7. Re: options for jpa-generate-entities-from-tables
gastaldi Sep 26, 2016 10:57 AM (in response to gerry.matte)What I meant is that --database-tables needs to be provided, but it will only be available when you type <TAB> after you specify the connection parameters