Lukas Samuolis
Lukas Samuolis

Reputation: 31

Failed to execute goal com.google.appengine:appengine-maven-plugin:1.9.67:devserver

Hey i have a problem starting my maven project on devserver and update calls. I buils my maven project to run with google cloud engine, but im getting this issue and cant start my server. This is my pom.xml :

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

  <modelVersion>4.0.0</modelVersion>
  <packaging>war</packaging>
  <version>0.0.1-SNAPSHOT</version>

  <groupId>trainingBuddyServer</groupId>
  <artifactId>Training-Buddy-Server</artifactId>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <maven.compiler.showDeprecation>true</maven.compiler.showDeprecation>
    <archiveClasses>true</archiveClasses>
  </properties>

  <prerequisites>
    <maven>3.5</maven>
  </prerequisites>

  <dependencies>
    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-api-1.0-sdk</artifactId>
      <version>1.9.67</version>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>javax.servlet-api</artifactId>
      <version>3.1.0</version>
      <type>jar</type>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>jstl</groupId>
      <artifactId>jstl</artifactId>
      <version>1.2</version>
    </dependency>

    <dependency>
      <groupId>com.google.guava</groupId>
      <artifactId>guava</artifactId>
      <version>22.0</version>
    </dependency>
    <dependency>
      <groupId>com.googlecode.objectify</groupId>
      <artifactId>objectify</artifactId>
      <version>5.1.17</version>
    </dependency>

    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-api-1.0-sdk</artifactId>
      <version>1.9.67</version>
    </dependency>

    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-endpoints</artifactId>
      <version>1.9.67</version>
    </dependency>
    <dependency>
      <groupId>com.google.endpoints</groupId>
      <artifactId>endpoints-framework</artifactId>
      <version>2.0.7</version>
    </dependency>
    <dependency>
      <groupId>com.google.endpoints</groupId>
      <artifactId>endpoints-management-control-appengine</artifactId>
      <version>1.0.3</version>
    </dependency>
    <dependency>
      <groupId>com.google.endpoints</groupId>
      <artifactId>endpoints-framework-auth</artifactId>
      <version>1.0.3</version>
    </dependency>

    <!-- Test Dependencies -->
    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-testing</artifactId>
      <version>1.9.67</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-api-stubs</artifactId>
      <version>1.9.67</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>com.google.appengine</groupId>
      <artifactId>appengine-tools-sdk</artifactId>
      <version>1.9.67</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>com.google.truth</groupId>
      <artifactId>truth</artifactId>
      <version>0.33</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.12</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-all</artifactId>
      <version>1.10.19</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <!-- for hot reload of the web application-->
    <outputDirectory>${project.build.directory}/${project.build.finalName}/WEB-INF/classes</outputDirectory>
    <plugins>
      <plugin>
        <groupId>com.google.appengine</groupId>
        <artifactId>appengine-maven-plugin</artifactId>
        <version>1.9.67</version>
        <configuration>
          <appId>trainingbuddy-221215</appId> <!-- Override appengine-web.xml <project> -->
          <version>1</version>
          <fullScanSeconds>1</fullScanSeconds>
          <retainUploadDir>true</retainUploadDir>
        </configuration>
      </plugin>

      <plugin>
           <groupId>com.google.cloud.tools</groupId>
           <artifactId>appengine-maven-plugin</artifactId>
           <version>1.3.1</version>
           <configuration>
              <deploy.promote>true</deploy.promote>
              <deploy.stopPreviousVersion>true</deploy.stopPreviousVersion>
            </configuration>
        </plugin>

      <plugin>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>1.4.1</version>
        <executions>
          <execution>
            <id>enforce-maven</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireMavenVersion>
                  <version>3.5</version>
                </requireMavenVersion>
                <requirePluginVersions>
                   <message>Best Practice is to always define plugin versions!</message>
                   <banLatest>true</banLatest>
                   <banRelease>true</banRelease>
                   <phases>clean,deploy,verify,appengine:run,appengine:deploy,appengine:update,appengine:devappaserver,site</phases>
                </requirePluginVersions>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project>

I think its something wrong with pom file, because error says that it cant find this element "com.google.appengine:appengine-maven-plugin:1.9.67:devserver". So this is teh error if it will help :

[INFO] --- appengine-maven-plugin:1.9.67:devserver (default-cli) @ Training-Buddy-Server ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.212 s
[INFO] Finished at: 2018-11-01T23:37:27+02:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.google.appengine:appengine-maven-plugin:1.9.67:devserver (default-cli) on project Training-Buddy-Server: The parameters 'project' for goal com.google.appengine:appengine-maven-plugin:1.9.67:devserver are missing or invalid -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginParameterException

Maybe someone know how to fix this?

Upvotes: 3

Views: 3003

Answers (4)

Carl Emmoth
Carl Emmoth

Reputation: 19

This is a problem since 1.9.66:

The parameters 'project' for goal com.google.appengine:appengine-maven-plugin:1.9.66:... are missing or invalid

Upvotes: 1

user3929131
user3929131

Reputation: 91

Adding the

    <project>YOUR PROJECT ID</project>

Indeed solves it for me also, however I'm not using the newer gclod maven plugin but the older appengine one:

    <groupId>com.google.cloud.tools</groupId>
    <artifactId>appengine-maven-plugin</artifactId>

vs mine

    <groupId>com.google.appengine</groupId>
    <artifactId>appengine-maven-plugin</artifactId>

At some point I should probably move on to the gcloud plugin but right now I haven't got time.

The old appengine plugin also works with the (undocumented) "project" configuration tag. Really confusing and also poor work by google since their getting (started examples) doesn't work, from 1.9.67 and above. Also if it's required from now on we should have gotten some information about it.

For the record I'm posting my multi module/services parent pom snippet including the pluginmanagement with the old appengine plugin:

    <pluginManagement>
      <plugins>
          <plugin>
              <groupId>com.google.appengine</groupId>
              <artifactId>appengine-maven-plugin</artifactId>
              <version>${appengine.target.version}</version>
              <configuration>
                  <project>YOUR PROJECT ID</project> <!-- WHAT DO WE NEED THIS FOR-->
                  <jvmFlags>
                      <jvmFlag>-Ddatastore.backing_store=${project.basedir}/local_db.bin</jvmFlag>
                  </jvmFlags>
                  <fullScanSeconds>-1</fullScanSeconds>
              </configuration>
          </plugin>
      </plugins>
  </pluginManagement>

Upvotes: 3

steinein
steinein

Reputation: 25

I had the same issue with latest AppEngine. It worked fine with lower than 1.9.64, but it generated the same error with the later version. Today I solved that issue by adding filed on the pom.xml as

  <plugin>
       <groupId>com.google.cloud.tools</groupId>
       <artifactId>appengine-maven-plugin</artifactId>
       <version>1.3.1</version>
       <configuration>
          <project>your project ID on Google Cloud </project>
          <deploy.promote>true</deploy.promote>
          <deploy.stopPreviousVersion>true</deploy.stopPreviousVersion>
        </configuration>
    </plugin>

Upvotes: 1

user3929131
user3929131

Reputation: 91

Did you manage to solve this? I've been using my multi module project pom(s) for at least 3 years with no problems, however since 1.9.67 I'm no longer able to deploy or running devserver via appengine maven plugin, with the same error:

The parameters 'project' for goal com.google.appengine:appengine-maven-plugin:1.9.67:devserver are missing or invalid

Using 1.9.65 works for me, so as a short time solution you should be able to use that version instead, however I don't know how old versions your allowed to deploy.

Upvotes: 1

Related Questions