protocol buffers - Error while adding protobuf dependency to maven -


i trying add protobuf dependency maven project. have installed protobuf jar file using mvn install:install-file -dpackaging=jar\ -dgeneratepom=true\
-dgroupid=com.google.protobuf\ -dartifactid=protobuf-java\ -dfile=protobuf-java-2.5.0.jar\ -dversion=2.5.0

mypom.xml file follows:

<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/maven-v4_0_0.xsd"> <modelversion>4.0.0</modelversion> <groupid>protobufexample</groupid> <artifactid>protobuftest</artifactid> <packaging>jar</packaging> <version>1.0-snapshot</version> <name>protobuftest</name> <url>http://maven.apache.org</url>  <properties>     <project.build.sourceencoding>utf-8</project.build.sourceencoding>     <skip.tests>false</skip.tests> </properties>   <dependencies>     <dependency>         <groupid>junit</groupid>         <artifactid>junit</artifactid>         <version>3.8.1</version>         <scope>test</scope>     </dependency>     <dependency>             <groupid>com.google.protobuf</groupid>             <artifactid>protobuf-java</artifactid>             <version>2.4.1</version>             <scope>compile</scope>         </dependency>  </dependencies> <build>     <finalname>protobuftest</finalname>     <plugins>         <plugin>             <groupid>org.apache.maven.plugins</groupid>             <artifactid>maven-compiler-plugin</artifactid>             <version>2.3.2</version>             <configuration>                 <source>1.6</source>                 <target>1.6</target>             </configuration>         </plugin>          <plugin>             <groupid>org.apache.maven.plugins</groupid>             <artifactid>maven-jar-plugin</artifactid>             <version>2.3.1</version>             <configuration>                 <finalname>${project.name}-${project.version}</finalname>             </configuration>         </plugin>          <plugin>             <artifactid>maven-assembly-plugin</artifactid>             <configuration>                 <appendassemblyid>false</appendassemblyid>                 <finalname>${project.name}-${project.version}</finalname>                 <descriptors>                     <descriptor>src/assembly/dist.xml</descriptor>                 </descriptors>             </configuration>         </plugin>          <plugin>             <groupid>com.google.protobuf</groupid>             <artifactid>protobuf-java</artifactid>             <version>2.5.0</version>             <executions>                 <execution>                     <id>generate-sources</id>                     <goals>                         <goal>test</goal>                     </goals>                     <phase>generate-sources</phase>                     <configuration>                         <protosourceroot>${basedir}/src/main/proto/</protosourceroot>                         <includes>                             <param>**/*.proto</param>                         </includes>                     </configuration>                 </execution>             </executions>             <configuration>                 <protocexecutable>/usr/local/bin/protoc</protocexecutable>             </configuration>         </plugin>      </plugins>  </build> 

when try test using "mvn test", following error: failed parse plugin descriptor com.google.protobuf:protobuf-java:2.5.0 no plugin descriptor found @ meta-inf/maven/plugin.xml

please me figure out going wrong.

the problem located based on following snippet of pom file:

  <plugin>     <groupid>com.google.protobuf</groupid>     <artifactid>protobuf-java</artifactid>     <version>2.5.0</version>     <executions>         <execution>             <id>generate-sources</id>             <goals>                 <goal>test</goal>             </goals>             <phase>generate-sources</phase>             <configuration>                 <protosourceroot>${basedir}/ 

the problem protobuf-java not plugin. couldn't workgin.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -