Giter Club home page Giter Club logo

emt4j's Introduction

Eclipse Adoptium

This organization provides a home for Git repositories that contain the activities of the Adoptium Working Group, the Eclipse Adoptium Top Level Project and several Eclipse projects that fall under that top level project:

NOTE: The high-level project and issue tracking across all projects is kept in the Adoptium repo issue tracking system.


Please see the Eclipse Adoptium Project description for more information regarding the Adoptium top-level project or its sub-projects (visually depicted in the diagram below).

graph TD

subgraph Eclipse Adoptium
    classDef public fill:#CFE1F3,stroke:#333,stroke-width:4px,color:#000000
    classDef private fill:#FF0000,stroke:#333,stroke-width:4px,color:#000000
    style public fill:#CFE1F3,stroke:#333,stroke-width:4px,color:#000000
    style private fill:#FF0000,stroke:#333,stroke-width:4px,color:#000000
    subgraph Adoptium
        AdoptiumTrigger[adoptium]:::public --- website["adoptium.net"]:::public --- api["api.adoptium.net"]:::public --- blog["blog.adoptium.net"]:::public --- dash["dash.adoptium.net"]:::public
    end
    subgraph Temurin
        subgraph Build
            buildTrigger[temurin-build]:::public --- mirror["mirror-scripts"]:::public --- src["jdk, jdk8u, jdk8u-aarch32, jdk17u"]:::public --- release["github-release-scripts"]:::public --- binaries["temurin8-binaries,<br/>temurin11-binaries,<br/>temurin17-binaries,<br/>temurin19-binaries"]:::public --- installer["installer"]:::public --- build["build-jdk"]:::public
        end
        subgraph Infrastructure
            direction LR
            infraTrigger[infrastructure]:::public --- jenkins["ci-jenkins-pipelines"]:::public --- jenkinshelper["jenkins-helper"]:::public --- support["adoptium-support"]:::public
        end
    end
    subgraph Temurin Compliance
        TCKTrigger[temurin-compliance]:::private --- infra["infrastructure"]:::private --- jck8["JCK8-unzipped"]:::private --- jck11["JCK11-unzipped"]:::private --- jck17["JCK17-unzipped"]:::private --- jck19["JCK19-unzipped"]:::private
    end
    subgraph AQAvit
        AQAvitTrigger[aqa-tests]:::public --- tkg["TKG"]:::public --- test-tools["aqa-test-tools"]:::public --- stf["STF"]:::public --- systemtest["aqa-systemtest"]:::public --- bumblebench["bumblebench"]:::public --- run-aqa["run-aqa"]:::public
    end
    subgraph Incubator
        IncubatorTrigger[jdk11u-fast-startup-incubator]:::public
    end
end
Loading

Eclipse Adoptium Working Group

The Adoptium Working Group promotes and supports high-quality runtimes and associated technology for use across the Java ecosystem. Our vision is to meet the needs of Eclipse and the broader Java community by providing a marketplace for high-quality Java runtimes for Java-based applications. We embrace existing standards and a wide variety of hardware and cloud platforms.

Eclipse Adoptium Top Level Project

The mission of the Eclipse Adoptium Top-Level Project is to distribute high-quality runtimes and associated technology for use within the Java ecosystem. We achieve this through a set of Projects under the Adoptium Project Management Committee (PMC) and a close working partnership with external projects, most notably OpenJDK for providing the Java SE runtime implementation. Our goal is to meet the needs of both the Eclipse community and broader runtime users by providing a comprehensive set of technologies around runtimes for Java applications that operate alongside existing standards, infrastructures, and cloud platforms.

Eclipse AQAvit project

AQAvit is the quality and runtime branding evaluation project for Java SE runtimes and associated technology. During a release it takes a functionally complete Java runtime and ensures that all the additional qualities are present that make it suitable for production use. These quality criteria include good performance, exceptional security, resilience and endurance, and the ability to pass a wide variety of application test suites. In addition to verifying that functionally complete runtimes are release ready, the AQA tests may also serve to verify new functionality during runtime development.

Eclipse Temurin project

The Eclipse Temurin project provides code and processes that support the building of runtime binaries and associated technologies that are high performance, enterprise-caliber, cross-platform, open-source licensed, and Java SE TCK-tested for general use across the Java ecosystem.

Eclipse Temurin Compliance project

The Eclipse Temurin Compliance project is responsible for obtaining, managing, and executing the Oracle Java SE Compatibility Kit (JCK) on Eclipse Temurin binaries. The work is done on private infrastructure and using code managed in closed repositories only available to committers of Temurin Compliance. The public artefacts produced by this project are limited to an indication of whether a particular Eclipse Temurin binary is Java SE compliant or not.

Eclipse Mission Control project

Eclipse Mission Control enables you to monitor and manage Java applications without introducing the performance overhead normally associated with these types of tools. It uses data collected for normal adaptive dynamic optimization of the Java Virtual Machine (JVM). Besides minimizing the performance overhead, this approach eliminates the problem of the observer effect, which occurs when monitoring tools alter the execution characteristics of the system.

emt4j's People

Contributors

archzi avatar d-d-h avatar dependabot[bot] avatar gaogao-mem avatar johanjanssen avatar leveretconey avatar lingjun-cg avatar oraluben avatar qiuchenjian avatar voimulax avatar ziyilin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

emt4j's Issues

How to obtain the contents of the file jdk_default_export_to_unnamed.cfg

Hi,
jdk_default_export_to_unnamed.cfg is used to filter out the unwanted add-exports option.

           if (jdkDefaultExportToUnnamed.contains(packageName.get())) {
                continue;
            }

how to obtain the contents of the file jdk_default_export_to_unnamed.cfg?
such as the ‘sun.awt’ , i think it shoud add '--add-exports=java.desktop/sun.awt=ALL-UNNAMED' , but it is in jdk_default_export_to_unnamed.cfg

Possible Memory Leak?

Using emt4j:process-test-classes of the Maven Plugin on a particularly large project (~700MB) with over 30 gigs of memory allocated

Failed to analyze classes
java.lang.RuntimeException: Failed to convert <com.web.viewmodels.matrix.MatrixViewModel: java.util.List getAllListDisplayedDateWithoutCurrentFilter(com.web.viewmodels.matrix.utils.MatrixFilter)>
        at soot.asm.AsmMethodSource.getBody(AsmMethodSource.java:2250)
        at soot.SootMethod.retrieveActiveBody(SootMethod.java:446)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.doAnalyze(CLDRDateFormatAnalyzer.java:40)
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:45)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.analyze(CLDRDateFormatAnalyzer.java:33)
        at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
        at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
        at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
        at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.analyze(ClassAnalyzer.java:42)
        at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:54)
        at org.eclipse.emt4j.analysis.source.DirectorySource.parse(DirectorySource.java:48)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$execute$2(AnalysisExecutor.java:91)
        at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
        at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384)
        at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
        at java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)
        at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)
        at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
        at java.util.concurrent.ForkJoinPool$WorkQueue.execLocalTasks(ForkJoinPool.java:1040)
        at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1058)
        at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
        at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:175)
Caused by: java.lang.OutOfMemoryError: Java heap space
        at java.util.HashMap.resize(HashMap.java:705)
        at java.util.HashMap.putVal(HashMap.java:664)
        at java.util.HashMap.put(HashMap.java:613)
        at java.util.HashSet.add(HashSet.java:220)
        at soot.asm.AsmMethodSource.addEdges(AsmMethodSource.java:1855)
        at soot.asm.AsmMethodSource.convert(AsmMethodSource.java:1954)
        at soot.asm.AsmMethodSource.getBody(AsmMethodSource.java:2248)
        at soot.SootMethod.retrieveActiveBody(SootMethod.java:446)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.doAnalyze(CLDRDateFormatAnalyzer.java:40)
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:45)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.analyze(CLDRDateFormatAnalyzer.java:33)
        at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
        at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
        at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
        at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
        at org.eclipse.emt4j.analysis.AnalysisExecutor$$Lambda$46/1579936920.accept(Unknown Source)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.analyze(ClassAnalyzer.java:42)
        at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:54)
        at org.eclipse.emt4j.analysis.source.DirectorySource.parse(DirectorySource.java:48)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$execute$2(AnalysisExecutor.java:91)
        at org.eclipse.emt4j.analysis.AnalysisExecutor$$Lambda$45/1649527633.accept(Unknown Source)
        at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
        at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384)
        at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
        at java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)
        at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)
        at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
        at java.util.concurrent.ForkJoinPool$WorkQueue.execLocalTasks(ForkJoinPool.java:1040)
        at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1058)
        at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)

using openjdk 1.8 and emt4j 0.8.0 from java 8 to 17

java.nio.file.NoSuchFileException

Hi,
I think this code needs to be protected in some scenarios in CheckMojo.java

        if (project.equals(projects.get(0))) {
            prepare();
        } else {
            load();
        }

this code use the first project to init the file, but I met the first project is empty, so never run prepare(),
and the second project throw exception

Caused by: java.nio.file.NoSuchFileException: D:\project\xxx\xxx\.emt4j\modules
    at sun.nio.fs.WindowsException.translateToIOException (WindowsException.java:79)
    at sun.nio.fs.WindowsException.rethrowAsIOException (WindowsException.java:97)
    at sun.nio.fs.WindowsException.rethrowAsIOException (WindowsException.java:102)
    at sun.nio.fs.WindowsFileSystemProvider.newByteChannel (WindowsFileSystemProvider.java:230)
    at java.nio.file.Files.newByteChannel (Files.java:361)
    at java.nio.file.Files.newByteChannel (Files.java:407)
    at java.nio.file.spi.FileSystemProvider.newInputStream (FileSystemProvider.java:384)
    at java.nio.file.Files.newInputStream (Files.java:152)
    at java.nio.file.Files.newBufferedReader (Files.java:2784)
    at java.nio.file.Files.newBufferedReader (Files.java:2816)
    at org.eclipse.emt4j.plugin.CheckMojo.load (CheckMojo.java:114)
    at org.eclipse.emt4j.plugin.CheckMojo.preCheck (CheckMojo.java:61)
    at org.eclipse.emt4j.plugin.BaseCheckMojo.doExecute (BaseCheckMojo.java:86)
    at org.eclipse.emt4j.plugin.BaseMojo.execute (BaseMojo.java:75)

I think using a stastic flag is a better choice, or check the file every project

Failure to find org.eclipse.emt4j:emt4j-parent:pom:${emt4j.version}

I deploy the tool to the private repo,

image

and config the plugin:

<plugin>
    <groupId>org.eclipse.emt4j</groupId>
    <artifactId>emt4j-maven-plugin</artifactId>
    <version>0.3</version>
    <executions>
        <execution>
            <phase>process-classes</phase>
            <goals>
                <goal>check</goal>
            </goals>
        </execution>
    </executions>
    <configuration>
        <fromVersion>8</fromVersion>
        <toVersion>11</toVersion>
        <targetJdkHome>/path/to/java/11.0.17-amzn</targetJdkHome>
    </configuration>
</plugin>

then run the command:

$ mvn org.eclipse.emt4j:emt4j-maven-plugin:0.3:check  -DfromVersion=8 -DtoVersion=11  -DprojectBuildDir=/path/to/project/target -DoutputFile=/path/to/project/target/report.html  -DoutputFormat=html
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] project                                                     [pom]
[INFO] project-domain                                              [jar]
[INFO] project-dao                                                 [jar]
[INFO] project-service                                             [jar]
[INFO] project-web                                                 [war]
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for project 0.0.1:
[INFO]
[INFO] project ..................................... SKIPPED
[INFO] project-domain .............................. SKIPPED
[INFO] project-dao ................................. SKIPPED
[INFO] project-service ............................. SKIPPED
[INFO] project-web ................................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  0.251 s
[INFO] Finished at: 2022-11-12T18:49:01+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.eclipse.emt4j:emt4j-maven-plugin:0.3 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.eclipse.emt4j:emt4j-maven-plugin:jar:0.3: Failure to find org.eclipse.emt4j:emt4j-parent:pom:${emt4j.version} in https://repo.example.com/plugins-releases was cached in the local repository, resolution will not be reattempted until the update interval of plugins-releases has elapsed or updates are forced -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException

Please publish emt4j-maven-plugin to The Central Repository. Publish emt4j-maven-plugin to The Central Repository is more convenient for everyone to use.

mvn clean install fails due to toolchain check expecting a legacy adoptopenjdk 8

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-toolchains-plugin:3.0.0:toolchain (default) on project emt4j-agent-common: Misconfigured toolchains.: Non-existing JDK home configuration at /Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command

Should probably be temurin and perhaps a doc update is required as well (what minimum jdks do you need installed)

Does the tool support scanning maven dependencies?

Use the EMT4J command-line tool 0.2

I tried to use this tool to scan the spring boot application jar package (from jdk8 to jdk17).
It seems that there is no dependency scanning, because there is a dependency( hbase-client 1.3.1 ) in my application that does not support jdk17.

analysis cannot run in Windows

What are you trying to do? Run analysis.bat in Windows

Expected behaviour: Successfully output the report

Observed behaviour: Throws an IOException: Clean up temporary directory: emt4j-unzip9818339042477963997 failed!

Any other comments:

1.Analysis
  1.Analysis *******.jar

Exception in thread "main" java.lang.Error: Clean up temporary directory: emt4j-unzip9818339042477963997 failed!
        at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.deleteFiles(JarAnalyzer.java:128)
        at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.analyze(JarAnalyzer.java:80)
        at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:49)
        at org.eclipse.emt4j.analysis.source.SingleJarSource.parse(SingleJarSource.java:38)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.execute(AnalysisExecutor.java:96)
        at org.eclipse.emt4j.analysis.AnalysisMain.doAnalysis(AnalysisMain.java:101)
        at org.eclipse.emt4j.analysis.AnalysisMain.main(AnalysisMain.java:47)
Caused by: java.nio.file.FileSystemException: C:\Users\Voimulax\AppData\Local\Temp\emt4j-unzip9818339042477963997\BOOT-INF\lib\lucene-analyzers-common-8.11.1.jar: 另一个程序正在使用此文件,进程无法访问。
        at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:92)
        at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
        at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:108)
        at java.base/sun.nio.fs.WindowsFileSystemProvider.implDelete(WindowsFileSystemProvider.java:275)
        at java.base/sun.nio.fs.AbstractFileSystemProvider.delete(AbstractFileSystemProvider.java:105)
        at java.base/java.nio.file.Files.delete(Files.java:1152)
        at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer$1.visitFile(JarAnalyzer.java:117)
        at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer$1.visitFile(JarAnalyzer.java:114)
        at java.base/java.nio.file.Files.walkFileTree(Files.java:2812)
        at java.base/java.nio.file.Files.walkFileTree(Files.java:2883)
        at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.deleteFiles(JarAnalyzer.java:114)
        ... 6 more

ERROR: java.util.ConcurrentModificationException

When use the emt4j:check of the mvn plugin, it will cause ConcurrentModificationException
image

Failed to analyze aspectjweaver-1.9.4.jar
java.util.ConcurrentModificationException
	at java.base/java.util.ArrayList$Itr.checkForComodification(ArrayList.java:1013)
	at java.base/java.util.ArrayList$Itr.next(ArrayList.java:967)
	at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:43)
	at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.analyze(CLDRDateFormatAnalyzer.java:33)
	at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
	at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
	at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
	at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
	at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
	at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
	at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.analyze(JarAnalyzer.java:60)
	at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:52)
	at org.eclipse.emt4j.analysis.source.SingleJarSource.parse(SingleJarSource.java:38)

JDK Version: 17.0.1-oracle
emt4j Version: 0.8.0

0.8.0版本分析失败 ConcurrentModificationException

看起来是并行流里面使用了不安全的ArrayList?
java.util.ConcurrentModificationException
at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:911)
at java.util.ArrayList$Itr.next(ArrayList.java:861)
at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:43)
at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.analyze(CLDRDateFormatAnalyzer.java:33)
at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.analyze(JarAnalyzer.java:102)
at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.analyze(JarAnalyzer.java:81)
at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:52)
at org.eclipse.emt4j.analysis.source.SingleJarSource.parse(SingleJarSource.java:38)
at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$execute$2(AnalysisExecutor.java:91)
at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1384)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
at java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)
at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at java.util.concurrent.ForkJoinTask.doInvoke(ForkJoinTask.java:401)
at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:734)
at java.util.stream.ForEachOps$ForEachOp.evaluateParallel(ForEachOps.java:159)
at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateParallel(ForEachOps.java:173)
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233)
at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:485)
at java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:650)
at org.eclipse.emt4j.analysis.AnalysisExecutor.execute(AnalysisExecutor.java:88)
at org.eclipse.emt4j.analysis.AnalysisMain.doAnalysis(AnalysisMain.java:105)
at org.eclipse.emt4j.analysis.AnalysisMain.main(AnalysisMain.java:52)

java.lang.ClassCastException: class soot.jimple.NullConstant cannot be cast to class soot.Local

Hi
Got the below exception

Failed to analyze opennlp-tools-1.5.3.jar
java.lang.ClassCastException: class soot.jimple.NullConstant cannot be cast to class soot.Local (soot.jimple.NullConstant and soot.Local are in unnamed module of loader org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry$SootAnalysisClassLoader @1c145458)
        at org.eclipse.emt4j.common.staticanalysis.impl.CastArraysAsListToArrayAnalyzer.doAnalyze(CastArraysAsListToArrayAnalyzer.java:66)
  Analyze bctsp-jdk14-1.38.jar done
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:45)
        at org.eclipse.emt4j.common.staticanalysis.impl.CastArraysAsListToArrayAnalyzer.analyze(CastArraysAsListToArrayAnalyzer.java:41)
        at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
        at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
        at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
        at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
  Analyze javafx-swing-11.0.2-win.jar done      at org.eclipse.emt4j.analysis.analyzer.JarAnalyzer.analyze(JarAnalyzer.java:60)
        at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:52)
        at org.eclipse.emt4j.analysis.source.SingleJarSource.parse(SingleJarSource.java:38)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$execute$2(AnalysisExecutor.java:91)
        at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
        at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1654)
  Analyze izpack-api-5.2.0.jar done
        at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
        at java.base/java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)

        at java.base/java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:746)
        at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
        at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
        at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
        at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
        at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:177)

java.lang.NoSuchMethodException: org.eclipse.emt4j.agent.common.rule.AgentReferenceClassRule.set(java.lang.String)

Exception in thread "main" java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at sun.instrument.InstrumentationImpl.loadClassAndStartAgent(InstrumentationImpl.java:386)
	at sun.instrument.InstrumentationImpl.loadClassAndCallPremain(InstrumentationImpl.java:401)
Caused by: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
	at org.eclipse.emt4j.agent.jdk8.MainAgent.premain(MainAgent.java:82)
	... 6 more
Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.eclipse.emt4j.agent.jdk8.MainAgent.premain(MainAgent.java:61)
	... 6 more
Caused by: java.lang.RuntimeException: org.eclipse.emt4j.common.JdkMigrationException: InstanceRuleManager init exception!
	at org.eclipse.emt4j.agent.common.AgentInit.init(AgentInit.java:30)
	... 11 more
Caused by: org.eclipse.emt4j.common.JdkMigrationException: InstanceRuleManager init exception!
	at org.eclipse.emt4j.common.rule.InstanceRuleManager.init(InstanceRuleManager.java:88)
	at org.eclipse.emt4j.agent.common.AgentFacade.initInstanceRules(AgentFacade.java:94)
	at org.eclipse.emt4j.agent.common.AgentFacade.init(AgentFacade.java:72)
	at org.eclipse.emt4j.agent.common.AgentInit.init(AgentInit.java:27)
	... 11 more
Caused by: java.lang.NoSuchMethodException: org.eclipse.emt4j.agent.common.rule.AgentReferenceClassRule.set(java.lang.String)
	at java.lang.Class.getMethod(Class.java:1786)
	at org.eclipse.emt4j.common.rule.InstanceRuleManager.setValue(InstanceRuleManager.java:93)
	at org.eclipse.emt4j.common.rule.InstanceRuleManager.init(InstanceRuleManager.java:78)
	... 14 more

When I usse

            <plugin>
                <groupId>org.eclipse.emt4j</groupId>
                <artifactId>emt4j-maven-plugin</artifactId>
                <version>0.8.0</version>
                <executions>
                    <execution>
                        <phase>initialize</phase>
                        <goals>
                            <goal>inject-agent</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>check</id>
                        <phase>test</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <fromVersion>8</fromVersion>
                    <toVersion>17</toVersion>
                    <outputFile>report_running.html</outputFile>
                </configuration>
            </plugin>

java.lang.InterruptedException when put dependency in ReportRecorder

Hi
Has anyone seen this problem?

org.apache.maven.plugins:maven-surefire-plugin:2.19:test failed: There was an error in the forked process
[ERROR] org.apache.maven.surefire.testset.TestSetFailedException: java.lang.RuntimeException: java.lang.InterruptedException
[ERROR] 	at org.apache.maven.surefire.common.junit4.JUnit4RunListener.rethrowAnyTestMechanismFailures(JUnit4RunListener.java:209)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.createRequestAndRun(JUnitCoreWrapper.java:131)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.executeEager(JUnitCoreWrapper.java:101)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.execute(JUnitCoreWrapper.java:77)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCoreProvider.invoke(JUnitCoreProvider.java:177)
[ERROR] 	at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:286)
[ERROR] 	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:240)
[ERROR] 	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:121)
[ERROR] Caused by: java.lang.RuntimeException: java.lang.InterruptedException
[ERROR] 	at org.eclipse.emt4j.agent.common.AgentFacade.record(AgentFacade.java:136)
[ERROR] 	at org.eclipse.emt4j.agent.common.rule.systemclassloader.GetSystemClassLoaderCallback.enter(GetSystemClassLoaderCallback.java:41)
[ERROR] 	at java.lang.Class.getClassLoader(Class.java:685)
[ERROR] 	at org.junit.runner.Description.getTestClass(Description.java:288)
[ERROR] 	at org.apache.maven.surefire.junitcore.NonConcurrentRunListener.describesNewTestSet(NonConcurrentRunListener.java:93)
[ERROR] 	at org.apache.maven.surefire.junitcore.NonConcurrentRunListener.finishLastTestSetIfNecessary(NonConcurrentRunListener.java:77)
[ERROR] 	at org.apache.maven.surefire.junitcore.NonConcurrentRunListener.testFailure(NonConcurrentRunListener.java:130)
[ERROR] 	at org.junit.runner.notification.SynchronizedRunListener.testFailure(SynchronizedRunListener.java:63)
[ERROR] 	at org.junit.runner.notification.RunNotifier$4.notifyListener(RunNotifier.java:142)
[ERROR] 	at org.junit.runner.notification.RunNotifier$SafeNotifier.run(RunNotifier.java:72)
[ERROR] 	at org.junit.runner.notification.RunNotifier.fireTestFailures(RunNotifier.java:138)
[ERROR] 	at org.junit.runner.notification.RunNotifier.fireTestFailure(RunNotifier.java:132)
[ERROR] 	at org.junit.internal.runners.model.EachTestNotifier.addFailure(EachTestNotifier.java:23)
[ERROR] 	at org.junit.runners.ParentRunner.run(ParentRunner.java:369)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCore.run(JUnitCore.java:55)
[ERROR] 	at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.createRequestAndRun(JUnitCoreWrapper.java:130)
[ERROR] 	... 6 more
[ERROR] Caused by: java.lang.InterruptedException
[ERROR] 	at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireInterruptibly(AbstractQueuedSynchronizer.java:1222)
[ERROR] 	at java.util.concurrent.locks.ReentrantLock.lockInterruptibly(ReentrantLock.java:335)
[ERROR] 	at java.util.concurrent.LinkedBlockingQueue.put(LinkedBlockingQueue.java:339)
[ERROR] 	at org.eclipse.emt4j.agent.common.file.ReportRecorder.record(ReportRecorder.java:74)
[ERROR] 	at org.eclipse.emt4j.agent.common.AgentFacade.record(AgentFacade.java:133)
[ERROR] 	... 21 more

Not a valid fromVersion: 11,toVersion:21 pair!

image As shown in the figure, the document states that 11 and 21 are supported configurations, but when actually used, it prompts `Not a valid fromVersion: 11,toVersion:21 pair!`

This is my pom configuration:

            <plugin>
                <groupId>org.eclipse.emt4j</groupId>
                <artifactId>emt4j-maven-plugin</artifactId>
                <version>0.8.0</version>
                <executions>
                    <execution>
                        <phase>process-test-classes</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <fromVersion>11</fromVersion>
                    <toVersion>21</toVersion>
                    <outputFile>report.html</outputFile>
                </configuration>
            </plugin>

IssueContextList about dependent components

Hi,all
It seems emt4j will scan dependent components in my application.Then they are sanned some issues.as the following:
Weixin Image_20240620150244

In fact, this is not in my code.So how to handle this type issue?
Looking forwoed to your reply,thanks.

java.lang.RuntimeException: couldn't find method <clinit>(*) in com.scort.es.jndi.url.URLContext

Hi

Got this third one below

java.lang.RuntimeException: couldn't find method <clinit>(*) in com.scort.es.jndi.url.URLContext
        at soot.SootClass.getMethodByName(SootClass.java:609)
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.globalTarget(BaseAnalyzer.java:97)
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.getDefValues(BaseAnalyzer.java:68)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.isTarget(CLDRDateFormatAnalyzer.java:67)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.doAnalyze(CLDRDateFormatAnalyzer.java:56)
        at org.eclipse.emt4j.common.staticanalysis.impl.BaseAnalyzer.analyze(BaseAnalyzer.java:45)
        at org.eclipse.emt4j.common.staticanalysis.impl.CLDRDateFormatAnalyzer.analyze(CLDRDateFormatAnalyzer.java:33)  Analyze classes done

        at org.eclipse.emt4j.common.staticanalysis.InvokerImpl.invoke(InvokerImpl.java:117)
        at org.eclipse.emt4j.common.staticanalysis.StaticAnalysisEntry.analyze(StaticAnalysisEntry.java:75)
        at org.eclipse.emt4j.common.rule.impl.WholeClassRule.check(WholeClassRule.java:68)
        at org.eclipse.emt4j.common.rule.ExecutableRule.execute(ExecutableRule.java:70)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$null$1(AnalysisExecutor.java:99)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.processClass(ClassAnalyzer.java:65)
        at org.eclipse.emt4j.analysis.analyzer.ClassAnalyzer.analyze(ClassAnalyzer.java:42)
        at org.eclipse.emt4j.analysis.analyzer.DependencyAnalyzer.iterateDo(DependencyAnalyzer.java:54)
  Analyze classes done
        at org.eclipse.emt4j.analysis.source.DirectorySource.parse(DirectorySource.java:48)
        at org.eclipse.emt4j.analysis.AnalysisExecutor.lambda$execute$2(AnalysisExecutor.java:91)
        at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
        at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1654)
        at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
        at java.base/java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290)  Analyze ctgclient-4.0.jar done

        at java.base/java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:746)
        at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
        at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
        at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)  Analyze slf4j-reload4j-1.7.35.jar done

        at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
        at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:177)

怎么理解P级定义

The "priority" decides the sequence of check results in the report file,定义了优先级对于报告输出的顺序定义。想了解下这个p4是不是代表我就可以在升级jdk版本时候可以忽略不做改造的?或则说,我只需要关注p1,p2即可

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.