Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 331338 - Java discoverer Benchmark test fails
Summary: Java discoverer Benchmark test fails
Status: CLOSED FIXED
Alias: None
Product: MoDisco
Classification: Modeling
Component: Main (show other bugs)
Version: 0.9.0   Edit
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: 0.9.0 M7   Edit
Assignee: Fabien Giquel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-29 08:40 EST by Stephane Rousseau CLA
Modified: 2013-04-26 09:13 EDT (History)
3 users (show)

See Also:
gdupe: indigo+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stephane Rousseau CLA 2010-11-29 08:40:49 EST
Hello,

Running the benchmark with Modisco 0.9.0 and Eclipse 3.7 on class JavaDiscovererBenchmarkTest fails with a NPE error :

!ENTRY org.eclipse.gmt.modisco.java.discoverer 4 0 2010-11-26 15:58:01.866
!MESSAGE java.lang.NullPointerException (org.eclipse.gmt.modisco.java.discoverer_0.9.0.v201011240900)
!STACK 0
java.lang.NullPointerException
	at org.eclipse.gmt.modisco.java.nousages.impl.TypeImpl.eInverseAdd(TypeImpl.java:97)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eInverseAdd(BasicEObjectImpl.java:1415)
	at org.eclipse.gmt.modisco.java.nousages.impl.TypeAccessImpl.setType(TypeAccessImpl.java:139)
	at org.eclipse.gmt.modisco.java.io.java.JDTVisitor.endVisit(JDTVisitor.java:1944)
	at org.eclipse.jdt.core.dom.PrimitiveType.accept0(PrimitiveType.java:259)
	at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2482)
	at org.eclipse.jdt.core.dom.ASTNode.acceptChild(ASTNode.java:2530)
	at org.eclipse.jdt.core.dom.MethodDeclaration.accept0(MethodDeclaration.java:498)
	at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2482)
	at org.eclipse.jdt.core.dom.ASTNode.acceptChildren(ASTNode.java:2553)
	at org.eclipse.jdt.core.dom.TypeDeclaration.accept0(TypeDeclaration.java:484)
	at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2482)
	at org.eclipse.jdt.core.dom.ASTNode.acceptChildren(ASTNode.java:2553)
	at org.eclipse.jdt.core.dom.CompilationUnit.accept0(CompilationUnit.java:219)
	at org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2482)
	at org.eclipse.gmt.modisco.java.io.java.JavaReader.visitCompilationUnit(JavaReader.java:442)
	at org.eclipse.gmt.modisco.java.io.java.JavaReader.parseTypeRoot(JavaReader.java:399)
	at org.eclipse.gmt.modisco.java.discoverer.benchmark.emfstat.JavaReaderEMFStat.parseTypeRoot(JavaReaderEMFStat.java:70)
	at org.eclipse.gmt.modisco.java.io.java.JavaReader.parsePackage(JavaReader.java:424)
	at org.eclipse.gmt.modisco.java.discoverer.benchmark.emfstat.JavaReaderEMFStat.parsePackage(JavaReaderEMFStat.java:61)
	at org.eclipse.gmt.modisco.java.io.java.JavaReader.readModel(JavaReader.java:297)
	at org.eclipse.gmt.modisco.java.io.java.JavaReader.readModel(JavaReader.java:261)
	at org.eclipse.gmt.modisco.java.discoverer.benchmark.emfstat.JavaReaderEMFStat.readModel(JavaReaderEMFStat.java:47)
	at org.eclipse.gmt.modisco.java.internal.actions.DiscoverSimpleJavaModelFromJavaProject$1.run(DiscoverSimpleJavaModelFromJavaProject.java:109)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
Comment 1 Fabien Giquel CLA 2010-11-29 13:02:24 EST
A first fix step has been commited intos SVN on modisco.java.nousages and nousages.cdo
Comment 2 Gregoire Dupe CLA 2011-05-18 05:13:01 EDT
Hello,

I’ve launched the memory behavior benchmark on the plug-in project org.apache.commons.codec.

I did not get any error in the log and the report has been correctly generated (except the diagram generation but this is another issue).
I’ve us the version 0.9.0.v201105171434.

Regards,
Gregoire Dupe
Comment 3 Gregoire Dupe CLA 2011-05-18 05:45:29 EDT
Hello,

The unit test org.eclipse.modisco.java.discoverer.benchmark.tests.JavaDiscovererBenchmarkTest.test001() runs properly on my computer (without any error or warning message in the log).

I assume that we can then mark the bug as closed.

Regards,
Gregoire Dupe