vscode-maven
                                
                                 vscode-maven copied to clipboard
                                
                                    vscode-maven copied to clipboard
                            
                            
                            
                        Maven Projects does not list the plugins even after refresh
Issue Type: Bug
- Open a existing maven pom.xml project
- once the java server started and every background activity is completed.
- Select the Maven Projects in the Explorer view.
- I am able to see the project. Then expanding it by clicking on > shows me plugins. However further clicking on the Plugins displays nothing.
Extension version: 0.21.1 VS Code version: Code 1.43.1 (fe22a9645b44368865c0ba92e2fb881ff1afce94, 2020-03-18T07:01:20.184Z) OS version: Windows_NT x64 10.0.18363
System Info
| Item | Value | 
|---|---|
| CPUs | Intel(R) Core(TM) i5-6300U CPU @ 2.40GHz (4 x 2496) | 
| GPU Status | 2d_canvas: enabled flash_3d: enabled flash_stage3d: enabled flash_stage3d_baseline: enabled gpu_compositing: enabled multiple_raster_threads: enabled_on oop_rasterization: disabled_off protected_video_decode: unavailable_off rasterization: enabled skia_renderer: disabled_off_ok video_decode: enabled viz_display_compositor: enabled_on viz_hit_test_surface_layer: disabled_off_ok webgl: enabled webgl2: enabled | 
| Load (avg) | undefined | 
| Memory (System) | 7.86GB (0.75GB free) | 
| Process Argv | |
| Screen Reader | no | 
| VM | 0% | 

It's possible that effective pom was not succesfully calculated. You can open: Output -> Maven for Java , there will be detailed log where we can find clues.
"local repository not specified in maven settings" after which Spawn {"command":" is there. I tried setting up path to settings.xml and that does not resolve the issue. No other information found on the output > Maven for Java
The “local repository” one is just a warning. Following the “spawn” one, there should be detailed output of the command, see if it’s successfully executed?
I'm also having this issue.
This is my pom.xml
<?xml version="1.0" encoding="UTF-8"?>
<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>
  <groupId>dev.simsek</groupId>
  <artifactId>demo</artifactId>
  <version>1.0-SNAPSHOT</version>
  <name>demo</name>
  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.compiler.source>13</maven.compiler.source>
    <maven.compiler.target>13</maven.compiler.target>
  </properties>
  <dependencies>
    <dependency>
      <artifactId>javaee-api</artifactId>
      <groupId>javax</groupId>
      <version>7.0</version>
      <scope>provided</scope>
    </dependency>
  </dependencies>
  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.wildfly.plugins</groupId>
          <artifactId>wildfly-maven-plugin</artifactId>
          <version>2.1.0.Beta1</version>
          </plugin>
      </plugins>
    </pluginManagement>
  </build>
</project>
This is the output of the extensions:
localRepository not specified in Maven Settings.
Spawn {"command":"mvn","args":["help:effective-pom","-Doutput=\"c:\\Users\\foo\\AppData\\Roaming\\Code\\User\\workspaceStorage\\4f8b31b3118d9c5498424702d4fc2a48\\vscjava.vscode-maven\\ac940065cf6815cf0306f5943e2bf7f4\"","-f","\"c:\\sources\\demo\\pom.xml\""]}
[INFO] Scanning for projects...
[INFO] 
[INFO] --------------------------< dev.simsek:demo >---------------------------
[INFO] Building demo 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- maven-help-plugin:3.2.0:effective-pom (default-cli) @ demo ---
[INFO] Effective-POM written to: c:\Users\foo\AppData\Roaming\Code\User\workspaceStorage\4f8b31b3118d9c5498424702d4fc2a48\vscjava.vscode-maven\ac940065cf6815cf0306f5943e2bf7f4
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  1.532 s
[INFO] Finished at: 2020-04-21T18:43:05+02:00
[INFO] ------------------------------------------------------------------------
Plugin Version: 0.21.2 Java: Openjdk 13 VsCode: 1.44.2 Maven: 3.6.3
Update:
Just looked into the path c:\Users\foo\AppData\Roaming\Code\User\workspaceStorage\4f8b31b3118d9c5498424702d4fc2a48\vscjava.vscode-maven\ac940065cf6815cf0306f5943e2bf7f4. It's empty
cheers flash :zap:
I was able to solve this "issue". I removed the "pluginmanagement" xml node and now it is able to list the wildfly plugin.
  <build>
    <plugins>
      <plugin>
        <groupId>org.wildfly.plugins</groupId>
        <artifactId>wildfly-maven-plugin</artifactId>
        <version>2.1.0.Beta1</version>
        </plugin>
    </plugins>
  </build>
cheers flash :zap:
I had a similar problem
When calling maven, I need to use -gs settings/xml -s settings.xml as per our local standards. This works fine - except that the maven invocation to calculate the effective pom runs in the Maven bin directory, and not the top level folder of the project. Since there isn't a settings.xml file there, it fails.
I added a settings.xml to the bin directory, but that's a hack. This extension should run the Maven to calculate the POM in the same folder as it runs all other maven commands
I was able to solve this "issue". I removed the "pluginmanagement" xml node and now it is able to list the wildfly plugin.
<build> <plugins> <plugin> <groupId>org.wildfly.plugins</groupId> <artifactId>wildfly-maven-plugin</artifactId> <version>2.1.0.Beta1</version> </plugin> </plugins> </build>cheers flash ⚡
It works! Thank you very much!
  <build>
    <plugins>
      <plugin>
        <groupId>org.wildfly.plugins</groupId>
        <artifactId>wildfly-maven-plugin</artifactId>
        <version>2.1.0.Beta1</version>
        </plugin>
    </plugins>
  </build>
Can confirm that this works +1 . Thank you!
I'm not able to reproduce the issue with pom.xml given in https://github.com/microsoft/vscode-maven/issues/480#issuecomment-617283035 , it simply lists all default plugins, which is expected.
As for https://github.com/microsoft/vscode-maven/issues/480#issuecomment-617296635 , yes, if you want to introduce a plugin, you should add it into plugins node directly under build instead of pluginManagement. pluginManagement is used to manage version of plugins.
I'm interested in the fact that many of you have the same case. How do you scaffold the project, is there a wrong wildfly template?
In my case, the scaffold was created with
mvn -B archetype:generate -DgroupId=com.mycompany.app -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart -DarchetypeVersion=1.4
From the maven getting started guide https://maven.apache.org/guides/getting-started/index.html.
I think this is just user error and the default maven docs being a bit confusing.
Thanks for the info.
I'm closing this issue as no further logs provided by the original author.