Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9040221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T09:55:58+00:00 2026-06-16T09:55:58+00:00

I’ve been developing in Java using maven for a few days now. Today I

  • 0

I’ve been developing in Java using maven for a few days now. Today I edited my pom.xml based on these instructions. Suddenly running mvn compile is giving me errors as if I was compiling with an older version of java. Stuff like:

error: generics are not supported in -source 1.3

Now I’ve paired my pom.xml back to its original content, and I’m still getting this error. I’ve done a mvn clean and deleted everything under target, and am still having this problem.

Here’s a snippet of maven running the compilation phase:

[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building bahToBeh 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-resources-plugin:2.3:resources (default-resources) @ bahToBeh ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory /home/doug/lucid/bah-bio-demo/bahToBeh/src/main/resources
[INFO] 
[INFO] --- maven-compiler-plugin:2.0.2:compile (default-compile) @ bahToBeh ---
[INFO] Compiling 9 source files to /home/doug/lucid/bah-bio-demo/bahToBeh/target/classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.880s
[INFO] Finished at: Thu Dec 20 13:52:06 EST 2012
[INFO] Final Memory: 7M/105M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile (default-compile) on project bahToBeh: Compilation failure: Compilation failure:
[ERROR] /home/doug/lucid/bah-bio-demo/bahToBeh/src/main/java/com/lucid/bahdemo/parsers/pm/MeshReader.java:[23,4] error: generics are not supported in -source 1.3

And my paired-down 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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>com.lucid</groupId>
  <artifactId>bahToBeh</artifactId>
  <packaging>jar</packaging>
  <version>1.0-SNAPSHOT</version>
  <name>bahToBeh</name>
  <url>http://maven.apache.org</url>
  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.8.1</version>
      <scope>test</scope>
  </dependency>
    <dependency>
      <groupId>com.digitalpebble</groupId>
      <artifactId>behemoth-core</artifactId>
      <version>1.0</version>
  </dependency>
  <dependency>
      <groupId>org.apache.hadoop</groupId>
      <artifactId>hadoop-core</artifactId>
      <version>1.0.4</version>
  </dependency>
  <dependency>
      <groupId>marc4j</groupId>
      <artifactId>marc4j</artifactId>
      <version>2.4</version>
  </dependency>
  </dependencies>
</project>

This had been working fine up until today. I’m not sure what setting I might have changed or how I could have munged up my project. I even double checked that the correct versions of java are installed:

doug@doug-VirtualBox:~/lucid/bah-bio-demo/bahToBeh$ java -version
java version "1.7.0_10"
Java(TM) SE Runtime Environment (build 1.7.0_10-b18)
Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)
doug@doug-VirtualBox:~/lucid/bah-bio-demo/bahToBeh$ javac -version
javac 1.7.0_10

Here is JAVA_HOME

doug@doug-VirtualBox:~/lucid/bah-bio-demo/bahToBeh$ echo $JAVA_HOME
/usr/lib/jvm/java-7-oracle

Maven IS using the pom.xml I think it is, if I run mvn -X compile I get:

DEBUG] (f) project = MavenProject: com.lucid:bahToBeh:1.0-SNAPSHOT @ /home/doug/lucid/bah-bio-demo/bahToBeh/pom.xml

I’ve also deleted my maven repo rm -rf ~/.m2 and saw maven redownload everything same problem.

EDIT — It suddenly works mysteriously
I have no idea what happened, but suddenly now its working. I thought that one thing I changed was I commented out a test. I went and uncommented out the test and then ran mvn compile and this time it compiled. Some state somewhere was out-of-sync and now things magically work?

I hate not knowing why my tools suddenly go wonky, so this is not an answer to the question, merely more information.

EDIT — and it also just suddenly STOPPED working again
Looks like fully specifying the version to compile works though, so dingding thats the winner.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T09:55:59+00:00Added an answer on June 16, 2026 at 9:55 am

    Set the source and target java versions explicitly. http://maven.apache.org/plugins/maven-compiler-plugin/examples/set-compiler-source-and-target.html

    <project>
      [...]
      <build>
        [...]
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.0</version>
            <configuration>
              <source>1.7</source>
              <target>1.7</target>
            </configuration>
          </plugin>
        </plugins>
        [...]
      </build>
      [...]
    </project>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a jquery bug and I've been looking for hours now, I can't
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
I have been unable to fix a problem with Java Unicode and encoding. The
I have thousands of HTML files to process using Groovy/Java and I need to
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I am using JSon response to parse title,date content and thumbnail images and place
Configuring TinyMCE to allow for tags, based on a customer requirement. My config is
this is what i have right now Drawing an RSS feed into the php,
I have a small JavaScript validation script that validates inputs based on Regex. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.