Hi,

 

My team has 3 developers. One of us is having the following problem. The
other two of us are not. Does anyone have ideas for how to fix this? We
are using Ibator 1.2.2.

 

Right-click on IbatorConfig.xml and choose "Generate iBATIS Artifacts."
Progress bar goes part-way, then shows this error:

 

Severity: Error

Message: Unexpected error while running Ibator.

Exception Stack Trace:

java.lang.ArrayIndexOutOfBoundsException: 247

                at
org.eclipse.jdt.internal.formatter.CodeFormatterVisitor.visit(CodeFormat
terVisitor.java:3239)

                at
org.eclipse.jdt.internal.compiler.ast.ConstructorDeclaration.traverse(Co
nstructorDeclaration.java:497)

                at
org.eclipse.jdt.internal.formatter.CodeFormatterVisitor.format(CodeForma
tterVisitor.java:542)

                at
org.eclipse.jdt.internal.formatter.CodeFormatterVisitor.formatClassBodyD
eclarations(CodeFormatterVisitor.java:1528)

                at
org.eclipse.jdt.internal.formatter.CodeFormatterVisitor.format(CodeForma
tterVisitor.java:772)

                at
org.eclipse.jdt.internal.formatter.DefaultCodeFormatter.internalFormatCl
assBodyDeclarations(DefaultCodeFormatter.java:452)

                at
org.eclipse.jdt.internal.formatter.DefaultCodeFormatter.formatClassBodyD
eclarations(DefaultCodeFormatter.java:229)

                at
org.eclipse.jdt.internal.formatter.DefaultCodeFormatter.format(DefaultCo
deFormatter.java:202)

                at
org.eclipse.jdt.internal.formatter.DefaultCodeFormatter.format(DefaultCo
deFormatter.java:188)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteFormatter.formatStri
ng(ASTRewriteFormatter.java:238)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteFormatter.formatNode
(ASTRewriteFormatter.java:363)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteFormatter.getFormatt
edResult(ASTRewriteFormatter.java:179)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.doTextInser
t(ASTRewriteAnalyzer.java:1152)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer$ListRewrite
r.rewriteList(ASTRewriteAnalyzer.java:569)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.rewritePara
graphList(ASTRewriteAnalyzer.java:997)

                at
org.eclipse.jdt.internal.core.dom.rewrite.ASTRewriteAnalyzer.visit(ASTRe
writeAnalyzer.java:1575)

                at
org.eclipse.jdt.core.dom.TypeDeclaration.accept0(TypeDeclaration.java:46
7)

                at
org.eclipse.jdt.core.dom.ASTNode.accept(ASTNode.java:2480)

                at
org.eclipse.jdt.core.dom.rewrite.ASTRewrite.internalRewriteAST(ASTRewrit
e.java:271)

                at
org.eclipse.jdt.core.dom.rewrite.ASTRewrite.rewriteAST(ASTRewrite.java:2
02)

                at
org.apache.ibatis.ibator.eclipse.core.merge.JavaFileMerger.getMergedSour
ce(Unknown Source)

                at
org.apache.ibatis.ibator.eclipse.core.callback.EclipseShellCallback.merg
eJavaFile(Unknown Source)

                at org.apache.ibatis.ibator.api.Ibator.generate(Unknown
Source)

                at org.apache.ibatis.ibator.api.Ibator.generate(Unknown
Source)

                at
org.apache.ibatis.ibator.eclipse.ui.actions.RunIbatorThread.run(Unknown
Source)

                at
org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1800)

                at
org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1782)

                at
org.apache.ibatis.ibator.eclipse.ui.actions.RunIbatorAction$IbatorRunner
.run(Unknown Source)

                at
org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalCon
text.java:121)

Session Data: 

eclipse.buildId=

java.version=1.6.0_18

java.vendor=Sun Microsystems Inc.

BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US

Framework arguments:  -product org.eclipse.epp.package.jee.product

Command-line arguments:  -os win32 -ws win32 -arch x86 -product
org.eclipse.epp.package.jee.product

 

 

 

WORKAROUND: deleting the previously-generated "XyzExample.java" file
before the code-gen eliminates this error. But it's kind of annoying to
have to do that.

 

Since the stack mentions that Eclipse JDT is parsing a constructor we
tried an experiment: delete all the constructors from XyzExample.java
and then re-generate the artifacts. We still got the same error.

 

 

Brian Morearty | Grow Your Business Division, Intuit | Staff Software
Engineer | direct 650-944-6852 

 

Reply via email to