【问题标题】:What is stable version for jasperreports-maven-plugin?jasperreports-maven-plugin 的稳定版本是什么?
【发布时间】:2013-08-28 18:18:53
【问题描述】:

在我的项目中,我使用的是 Maven 3.0.4 和 JasperReports 5.1.0。要编译 JRXML 文件,请使用 jasperreports-maven-plugins。我有 1.0-beta-2 版本的 jasperreports-maven-plugin。由于它是 beta 版本 (1.0-beta-2) 我可以知道,jasperreports-maven-plugin 的稳定版本可以使用吗?

在我的 pom.xml 文件中使用的插件下方

<properties>
      <jasperreports.version>5.1.0</jasperreports.version>
</properties>

<build>
      <plugins>
         <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>jasperreports-maven-plugin</artifactId>
            <version>1.0-beta-2</version>
            <configuration>
               <sourceDirectory>src/main/resources/reports</sourceDirectory>
               <outputDirectory>${project.build.directory}/classes/reports</outputDirectory>
            </configuration>
            <executions>
               <execution>
                  <!-- Need to bind to the compile phase cuz the reports uses classes under target/classes. The default is the generate-resources phase. -->
                  <phase>compile</phase>
                  <goals>
                     <goal>compile-reports</goal>
                  </goals>
               </execution>
            </executions>
            <dependencies>
               <dependency>
                  <groupId>net.sf.jasperreports</groupId>
                  <artifactId>jasperreports</artifactId>
                  <version>${jasperreports.version}</version>
               </dependency>
               <dependency>
                  <groupId>org.codehaus.groovy</groupId>
                  <artifactId>groovy-all</artifactId>
                  <version>2.0.1</version>
                  <scope>compile</scope>
                  <optional>true</optional>
               </dependency>
            </dependencies>
         </plugin>
      </plugins>
   </build>

【问题讨论】:

标签: maven jasper-reports


【解决方案1】:

忘记官方的 maven 插件吧。我已经使用alexnederlof's Jasper report maven plugin 很长时间了,而且效果很好。

您可以在 github 上找到更多信息:

来自 org.codehaus.mojo 的原始 jasperreports-maven-plugin 是 有点慢。这个插件快 10 倍。我用 52 份报告对其进行了测试 使用原始插件需要 48 秒,而使用原始插件只需 4.7 秒 这个插件。

在他的blog:

原始插件是在 Java 4 中创建的,单线程和 上一次提交回购协议的时间是(在撰写本文时)31 日 2009 年 8 月。看起来并不是一个真正活跃的项目。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-04-22
    • 1970-01-01
    • 1970-01-01
    • 2016-03-07
    • 1970-01-01
    • 1970-01-01
    • 2021-06-23
    相关资源
    最近更新 更多