Devskiller / jpa2ddl

JPA Schema Generator Plugin
Apache License 2.0
110 stars 33 forks source link

Missing parameter for goals causes a build error in project... #22

Closed Daveo24 closed 6 years ago

Daveo24 commented 6 years ago

I have been using your plugin for a while and it all works well, accept for the following error whenever I try to clean or save my project in eclipse.

The following is the error I receive...

Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'com.devskiller.jpa2ddl'
artifactId = 'jpa2ddl-maven-plugin'
versionRange = '0.9.11'
goals = '[]'

Also please see attached what I currently have in my pom...

            <plugin>
                <groupId>com.devskiller.jpa2ddl</groupId>
                <artifactId>jpa2ddl-maven-plugin</artifactId>
                <version>0.9.11</version>
                <extensions>true</extensions> <!-- required to run automatically -->
                <goals></goals>
                <configuration>
                    <outputPath>${basedir}/src/test/resources/sql/schema_MariaDb.sql</outputPath>
                    <packages>
                        <package>generic.model</package>
                        <package>generic.model</package>
                    </packages>
                    <jpaProperties>
                        <property>
                            <name>hibernate.dialect</name>
                            <value>org.hibernate.dialect.MySQL5Dialect</value>
                        </property>
                        <property>
                            <name>hibernate.default_schema</name>
                            <value>databasename</value>
                        </property>
                    </jpaProperties>
                    <formatOutput>true</formatOutput>
                    <skipSequences>true</skipSequences>
                    <delimiter>;</delimiter>
                    <action>CREATE</action>

                    <ignoredDependencies>
                        <ignoredDependency>org.javassist:javassist</ignoredDependency>
                    </ignoredDependencies>
                    <ignoredUsedUndeclaredDependencies>
                        <ignoredUsedUndeclaredDependency>org.javassist:javassist</ignoredUsedUndeclaredDependency>
                    </ignoredUsedUndeclaredDependencies>
                    <ignoredUnusedDeclaredDependencies>
                        <ignoredUnusedDeclaredDependency>org.javassist:javassist</ignoredUnusedDeclaredDependency>
                    </ignoredUnusedDeclaredDependencies>

                </configuration>
            </plugin>

Any help would be greatly received, thanks.

jkubrynski commented 6 years ago

Why do you add <goals></goals> ? It's not needed as extensions set to true enables the goal inheritance from the plugin config. Maybe Eclipse doesn't support it? Then if this error is annoying for you please just add generate goal:

<goals>
    <goal>generate</goal>
</goals>