protobuf java runtime installation - windows

I'm trying to build the Java runtime library for Protocol Buffers on Windows. I have downloaded and installed the binary distribution of protoc: protoc-3.3.0-win32 . I have downloaded the protobuf-master from https://github.com/google/protobuf. and tried to build Java runtime library using Maven. I ran mvn test from D:\protobuf-master\java
These errors occured when I ran mvn test.
`[INFO] Results:
[INFO]
[ERROR] Errors:
[ERROR] MapTest.testPut:1248 ╗ IllegalArgument
[ERROR] MapTest.testPutForUnknownEnumValues:494 ╗ IllegalArgument
[INFO]
[ERROR] Tests run: 908, Failures: 0, Errors: 2, Skipped: 0
[INFO]
[INFO] --------------------------------------------------------------------
----
[INFO] Reactor Summary:
[INFO]
[INFO] Protocol Buffers [Parent] .......................... SUCCESS [
0.000 s]
[INFO] Protocol Buffers [Core] ............................ FAILURE [01:23
min]
[INFO] Protocol Buffers [Util] ............................ SKIPPED
[INFO] --------------------------------------------------------------------
----
[INFO] BUILD FAILURE
[INFO] --------------------------------------------------------------------
----
[INFO] Total time: 01:24 min
[INFO] Finished at: 2017-06-27T20:40:21+02:00
[INFO] Final Memory: 32M/720M
[INFO] --------------------------------------------------------------------
----
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-
plugin:2.20:test (default-test) on project protobuf-java: There are test
failures.
[ERROR]
[ERROR] Please refer to D:\protobuf-master\java\core\target\surefire-
reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump,
[date].dumpstream and [date]-jvmRun[N].dumpstream.
[ERROR] -> [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/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the
command
[ERROR] mvn <goals> -rf :protobuf-java`

The behavior was changed after 3.3.0 so either checkout v3.3.0 or compile newer version of protoc.
Commit

Related

CodeHaus Maven JAXB2 plugin error MojoExecutionException: NoSchemasException

I am trying to build my project ,in that i got error called [ERROR] Failed to execute goal org.codehaus.mojo:jaxb2-maven-plugin:2.4:xjc (One) on project tg-tg-tems-ota-common-service: : MojoExecutionException: NoSchemasException -> [Help 1]
we are using java8 ,apache maven 3.6.3 ,jaxb2 plugin 2.4
Please find below error
INFO] Building TravelGrid-Tems-Ota-Service 3.0.0-SNAPSHOT [2/3]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # tg-tg-tems-ota-common-service ---
[INFO]
[INFO] --- jaxb2-maven-plugin:2.4:xjc (One) # tg-tg-tems-ota-common-service ---
[INFO] Created EpisodePath [D:\Sushma_Project\TG_UPGRADATION\Project\branches\3.0.0-SNAPSHOT\tems\tg-tems-servicelayer\tg-tems-ota-common-service\target\generated-sources\jaxb\emt\hotelSearchRequest\META-INF\JAXB]: true
[INFO] Ignored given or default xjbSources [D:\Sushma_Project\TG_UPGRADATION\Project\branches\3.0.0-SNAPSHOT\tems\tg-tems-servicelayer\tg-tems-ota-common-service\src\main\xjb], since it is not an existent file or directory.
[INFO] Ignored given or default sources [D:\Sushma_Project\TG_UPGRADATION\Project\branches\3.0.0-SNAPSHOT\tems\tg-tems-servicelayer\tg-tems-ota-common-service\src\main\xsd], since it is not an existent file or directory.
[WARNING] No XSD files found. Please check your plugin configuration.
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for tg-servicelayer 3.0.0-SNAPSHOT:
[INFO]
[INFO] tg-servicelayer .................................... SUCCESS [ 0.697 s]
[INFO] TravelGrid-Tems-Ota-Service ........................ FAILURE [ 0.909 s]
[INFO] TravelGrid-Subsystems .............................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.941 s
[INFO] Finished at: 2020-06-30T15:50:30+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:jaxb2-maven-plugin:2.4:xjc (One) on project tg-tg-tems-ota-common-service: : MojoExecutionException: NoSchemasException -> [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/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <args> -rf :tg-tg-tems-ota-common-service
D:\Sushma_Project\TG_UPGRADATION\Project\branches\3.0.0-SNAPSHOT\tems\tg-tems-servicelayer>
I am new to jaxb plugin ,can anyone help me
Please user "mvn clean install" it will clean the target folder and regenerate everything from scratch.

How to prevent Unknown packaging "bundle" error when computing the effective POM

I am reading an effective POM from the command line (using the approach described here: How to specify an artifact in help:effective-pom?)
For the artifact:
<dependency>
<groupId>com.typesafe.scala-logging</groupId>
<artifactId>scala-logging_2.12</artifactId>
<version>3.7.2</version>
</dependency>
Using the command:
mvn help:effective-pom -Dartifact=com.typesafe.scala-logging:scala-logging_2.12:3.7.2
I get this error:
[INFO] Scanning for projects...
[INFO]
[INFO] ---------------------------< mvntmp:mvntmp >----------------------------
[INFO] Building mvntmp 0.0.1-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-help-plugin:3.2.0:effective-pom (default-cli) # mvntmp ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.540 s
[INFO] Finished at: 2020-05-20T15:26:34+02:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-help-plugin:3.2.0:effective-pom (default-cli) on project mvntmp: Unable to get the POM for the artifact 'com.typesafe.scala-logging:scala-logging_2.12:3.7.2'. Verify the artifact parameter.: Some problems were encountered while processing the POMs:
[ERROR] [ERROR] Unknown packaging: bundle # line 6, column 16: 1 problem was encountered while building the effective model for com.typesafe.scala-logging:scala-logging_2.12:3.7.2
[ERROR] [ERROR] Unknown packaging: bundle # line 6, column 16
[ERROR] -> [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/MojoExecutionException

I can't create .war with maven

I created a .war with maven clean install, now I need create other .war, but I get this error ->
- maven-clean-plugin:2.6.1:clean (default-clean) # tutorial---
[INFO] Deleting C:\Users\yo\eclipse-workspace\tutorial\target
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 3.843 s
[INFO] Finished at: 2018-09-24T15:46:51+02:00
[INFO] Final Memory: 17M/228M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.6.1:clean (default-clean) on project tutorial: Failed to clean project: Failed to delete C:\Users\yo\eclipse-workspace\tutorial\target -> [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/MojoExecutionException
Now My field \target is empty and I can't create .war
Some other application has opened the target folder. Due to this maven-clean-plugin is not able to delete the target folder and fails.

Install Maven jar with pom into local repository

I have an old jar (jsf-api-2.0.2.jar). In this jar there is a /META-INF/maven-Folder.
How do I install the jar into my local repository?
install:install-file says I need to specify the artifactId myself. How do I force it to use the information in jsf-api-2.0.2.jar!\META-INF\maven\com.sun.faces\jsf-api\pom.xml?
Output:
mvn install:install-file -Dfile=jsf-api-2.0.2.jar
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) # standalone-pom ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.410s
[INFO] Finished at: Sat Feb 01 12:52:34 CET 2014
[INFO] Final Memory: 13M/368M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-install-plugin:2.4:install-file (default cli) on project standalone-pom: The artifact information is incomplete or not valid:
[ERROR] [0] 'groupId' is missing.
[ERROR] [1] 'artifactId' is missing.
[ERROR] [2] 'packaging' is missing.
[ERROR] [3] 'version' is missing.
[ERROR] -> [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/MojoExecutionException
See http://maven.apache.org/plugins/maven-install-plugin/examples/custom-pom-installation.html
Just ensure you're using at least version 2.5, which introduced this feature.
And by the way: the goal is install-file, not install-jar

Error when deploy github site with maven

With this maven pom file : https://gist.github.com/PhilippeGeek/44f62827bf73bc7d9368, I can't create a blob, the output is:
[INFO] ------------------------------------------------------------------------
[INFO] Building SpeleoGraph 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- site-maven-plugin:0.6:site (default-cli) # SpeleoGraph ---
[INFO] Creating 102 blobs
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.270s
[INFO] Finished at: Sat Jul 13 23:48:01 CEST 2013
[INFO] Final Memory: 9M/152M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.github:site-maven-plugin:0.6:site (default-cli) on project SpeleoGraph: Error creating blob: Unexpected end of file from server -> [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/MojoExecutionException
This problem come form an out-dated version of site-maven-plugin, you should use version 0.8 or more recent.
This may happen with version 0.8 and 0.9 also, when the binary to be deployed to github is over about 30MB.
Issue on github (see comments)
Reference to a work-around for reducing the size of the binary

Resources