plantuml-maven-plugin 7954 seems not to support new activity syntax

0 votes
asked Aug 2, 2013 in Bug by michael.baedorf (120 points)
Hi,

I' trying something like

@startuml

start
     :suche mit Name und PLZ;
     if (Mandant gefunden) then (nein)
         :suche mit Name und Ort;
     else (ja)
         if (genau ein Mandant) then (nein)
             :filtere Mandanten mit Ort;
             if (genau ein Mandant) then (nein)
                 :filtere Mandant weiter mit Strasse;
                 if (genau ein Mandant) then (nein)
                     :setze null als Returnwert;
                 endif
              endif
          endif
    endif
    stop

@enduml

and it works fine using eclipse, but maven plugin reports

@startuml

start
:suche mit Name und PLZ;
^^^^^^^^^^^^^^^^^^^^^^^^
 Syntax Error?

1 Answer

0 votes
answered Aug 2, 2013 by plantuml (295,000 points)

That's because the new activity syntax has been released after V7954.

You should use https://github.com/jeluard/maven-plantuml-plugin/issues to report issues on this plugin.

Anyway, https://github.com/jeluard/maven-plantuml-plugin/blob/master/README.md has just been updated by Julien Eluard (thanks Julien).


You can now specify a version of PlantUML to be able to use latest release :

<build>
  <plugins>
    <plugin>
      <groupId>com.github.jeluard</groupId>
      <artifactId>plantuml-maven-plugin</artifactId>
      <version>7941</version>
      <configuration>
        <sourceFiles>
          <directory>${basedir}</directory>
          <includes>
            <include>src/main/plantuml/**/*.txt</include>
          </includes>
        </sourceFiles>
      </configuration>
      <dependencies>
        <dependency>
          <groupId>net.sourceforge.plantuml</groupId>
          <artifactId>plantuml</artifactId>
          <version>7976</version>
        </dependency>
      </dependencies>
    </plugin>
  </plugins>
</build>

 

commented Mar 15, 2017 by anonymous
plantuml-maven-plugin is no longer maintained and the plugin breaks after version PlantUML v8031(ish)
```
Caused by: java.lang.IncompatibleClassChangeError: Found interface net.sourceforge.plantuml.GeneratedImage, but class was expected
    at com.github.plantuml.maven.PlantUMLMojo.execute(PlantUMLMojo.java:191)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
```


but you can use the maven exec plugin instead
```
 <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>exec-maven-plugin</artifactId>
                <version>1.5.0</version>
                <executions>
                    <execution>
                        <id>default-cli</id>
                        <goals>
                            <goal>java</goal>
                        </goals>
                        <phase>verify</phase>
                        <configuration>
                            <mainClass>net.sourceforge.plantuml.Run</mainClass>
                            <arguments>
                                <argument>-o</argument>
                                <argument>${basedir}/target/plantuml</argument>
                                <argument>${basedir}/documentation/**/*.puml</argument>
                            </arguments>
                            <includePluginDependencies>true</includePluginDependencies>
                            <includeProjectDependencies>false</includeProjectDependencies>
                            <executableDependency>
                                <groupId>net.sourceforge.plantuml</groupId>
                                <artifactId>plantuml</artifactId>
                            </executableDependency>
                        </configuration>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>net.sourceforge.plantuml</groupId>
                        <artifactId>plantuml</artifactId>
                        <version>8057</version>
                    </dependency>
                </dependencies>
            </plugin>
```
commented Mar 15, 2017 by plantuml (295,000 points)
GeneratedImage used to be an class and is now an interface.
Not sure to understand why it breaks the plugin. DId you have the last version of it (PlantUMLMojo.java:191 does not seem to match a code line).

We are also not maintaining this project. Maybe you could write to some contributors ( https://github.com/jeluard/maven-plantuml-plugin ) :
Fixing this should not be a big issue.

Sorry that we cannot do more!
...