Uploaded image for project: 'Red Hat CodeReady Studio (devstudio)'
  1. Red Hat CodeReady Studio (devstudio)
  2. JBDS-4154

JavaEE Web Project > Run As > Maven not working

XMLWordPrintable

    • Hide
      1. Install yum repositories [^rh-eclipse46.repo] and [^rh-eclipse46-devstudio-snapshots-10_2.repo]
      2. sudo yum install rh-eclipse46-base
      3. sudo yum install rh-eclipse46-devstudio
        (rh-eclipse46-devstudio-10.2-0.20161028.1735.el7.x86_64 in my case)
      4. Import "Java EE Web project" from Red Hat Central
      5. Right click on project and choose Run As->Maven clean
      Show
      Install yum repositories [^rh-eclipse46.repo] and [^rh-eclipse46-devstudio-snapshots-10_2.repo] sudo yum install rh-eclipse46-base sudo yum install rh-eclipse46-devstudio (rh-eclipse46-devstudio-10.2-0.20161028.1735.el7.x86_64 in my case) Import "Java EE Web project" from Red Hat Central Right click on project and choose Run As->Maven clean
    • Hide

      This is a problem with embedded maven installation.
      Workaround is to use the system maven:
      1. sudo yum install maven
      2. In Eclipse, Preferences->Maven->Installation->Add
      3. Point to /usr/share/maven directory
      4. Select this user installation instead of the default (embedded) one
      And don't forget to add JBoss maven repo to your ~/.m2/settings.xml file for proper maven support.

      Show
      This is a problem with embedded maven installation. Workaround is to use the system maven: 1. sudo yum install maven 2. In Eclipse, Preferences->Maven->Installation->Add 3. Point to /usr/share/maven directory 4. Select this user installation instead of the default (embedded) one And don't forget to add JBoss maven repo to your ~/.m2/settings.xml file for proper maven support.
    • NEW

      I am not able to use embedded Maven. When I try to run Maven clean (or whatever else) I get following error message in Console (nothing in Error log):

      Exception in thread "main" java.lang.NoClassDefFoundError: org/slf4j/Logger
      	at java.lang.Class.getDeclaredMethods0(Native Method)
      	at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
      	at java.lang.Class.privateGetMethodRecursive(Class.java:3048)
      	at java.lang.Class.getMethod0(Class.java:3018)
      	at java.lang.Class.getMethod(Class.java:1784)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.getEnhancedMainMethod(Launcher.java:172)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:268)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
      Caused by: java.lang.ClassNotFoundException: org.slf4j.Logger
      	at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
      	... 10 more
      

      Standalone maven installation works fine.

        1. maven171-fix.png
          184 kB
          Nick Boldt
        2. maven171-fix-installed.png
          17 kB
          Nick Boldt

              nickboldt Nick Boldt
              lvalach_jira Lukáš Valach (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: