Open wkii opened 4 years ago
目前高版本有什么特别的地方吗?
mark
高版本支持jdk8的日期类型,LocalDateTime 等
1.3.7也有问题
java.lang.VerifyError: Bad type on operand stack Exception Details: Location: tk/mybatis/mapper/generator/MapperCommentGenerator.addComment(Lorg/mybatis/generator/api/dom/xml/XmlElement;)V @10: invokevirtual Reason: Type 'org/mybatis/generator/api/dom/xml/TextElement' (current frame, stack[1]) is not assignable to 'org/mybatis/generator/api/dom/xml/Element' Current Frame: bci: @10 flags: { } locals: { 'tk/mybatis/mapper/generator/MapperCommentGenerator', 'org/mybatis/generator/api/dom/xml/XmlElement' } stack: { 'org/mybatis/generator/api/dom/xml/XmlElement', 'org/mybatis/generator/api/dom/xml/TextElement' } Bytecode: 0x0000000: 2bbb 0005 5912 06b7 0007 b600 08bb 0009 0x0000010: 59b7 000a 4d2c 120b b600 0c57 2c12 0eb6 0x0000020: 000c 572b bb00 0559 2cb6 000f b700 07b6 0x0000030: 0008 2bbb 0005 5912 10b7 0007 b600 08b1 0x0000040:
java.lang.VerifyError: Bad type on operand stack Exception Details: Location: tk/mybatis/mapper/generator/MapperCommentGenerator.addComment(Lorg/mybatis/generator/api/dom/xml/XmlElement;)V @10: invokevirtual Reason: Type 'org/mybatis/generator/api/dom/xml/TextElement' (current frame, stack[1]) is not assignable to 'org/mybatis/generator/api/dom/xml/Element' Current Frame: bci: @10 flags: { } locals: { 'tk/mybatis/mapper/generator/MapperCommentGenerator', 'org/mybatis/generator/api/dom/xml/XmlElement' } stack: { 'org/mybatis/generator/api/dom/xml/XmlElement', 'org/mybatis/generator/api/dom/xml/TextElement' } Bytecode: 0x0000000: 2bbb 0005 5912 06b7 0007 b600 08bb 0009 0x0000010: 59b7 000a 4d2c 120b b600 0c57 2c12 0eb6 0x0000020: 000c 572b bb00 0559 2cb6 000f b700 07b6 0x0000030: 0008 2bbb 0005 5912 10b7 0007 b600 08b1 0x0000040:
[INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1.322 s [INFO] Finished at: 2021-01-31T09:38:02+08:00 [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.mybatis.generator:mybatis-generator-maven-plugin:1.3.7:generate (default-cli) on project mall-db: Execution default-cli of goal org.mybatis.generator:mybatis-generator-maven-plugin:1.3.7:generate failed: A required class was missing while executing org.mybatis.generator:mybatis-generator-maven-plugin:1.3.7:generate: org/dom4j/io/SAXReader [ERROR] ----------------------------------------------------- [ERROR] realm = plugin>org.mybatis.generator:mybatis-generator-maven-plugin:1.3.7 [ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy [ERROR] urls[0] = file:/Users/yourname/.m2/repository/org/mybatis/generator/mybatis-generator-maven-plugin/1.3.7/mybatis-generator-maven-plugin-1.3.7.jar [ERROR] urls[1] = file:/Users/yourname/.m2/repository/mysql/mysql-connector-java/5.1.46/mysql-connector-java-5.1.46.jar [ERROR] urls[2] = file:/Users/yourname/.m2/repository/com/itfsw/mybatis-generator-plugin/1.2.12/mybatis-generator-plugin-1.2.12.jar [ERROR] urls[3] = file:/Users/yourname/.m2/repository/org/apache/commons/commons-lang3/3.5/commons-lang3-3.5.jar [ERROR] urls[4] = file:/Users/yourname/.m2/repository/javax/enterprise/cdi-api/1.0/cdi-api-1.0.jar [ERROR] urls[5] = file:/Users/yourname/.m2/repository/org/eclipse/sisu/org.eclipse.sisu.inject/0.3.3/org.eclipse.sisu.inject-0.3.3.jar [ERROR] urls[6] = file:/Users/yourname/.m2/repository/org/codehaus/plexus/plexus-component-annotations/1.5.5/plexus-component-annotations-1.5.5.jar [ERROR] urls[7] = file:/Users/yourname/.m2/repository/org/codehaus/plexus/plexus-utils/3.1.0/plexus-utils-3.1.0.jar [ERROR] urls[8] = file:/Users/yourname/.m2/repository/org/mybatis/generator/mybatis-generator-core/1.3.7/mybatis-generator-core-1.3.7.jar [ERROR] Number of foreign imports: 1 [ERROR] import: Entry[import from realm ClassRealm[maven.api, parent: null]] [ERROR] [ERROR] ----------------------------------------------------- [ERROR] : org.dom4j.io.SAXReader [ERROR] -> [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/PluginContainerException
<plugin>
<groupId>org.mybatis.generator</groupId>
<artifactId>mybatis-generator-maven-plugin</artifactId>
<version>1.3.7</version>
<configuration>
<configurationFile>
mybatis-generator/generatorConfig.xml
</configurationFile>
<overwrite>true</overwrite>
<verbose>true</verbose>
</configuration>
<dependencies>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.46</version>
</dependency>
<dependency>
<groupId>com.itfsw</groupId>
<artifactId>mybatis-generator-plugin</artifactId>
<version>1.2.12</version>
</dependency>
</dependencies>
</plugin>
java.lang.VerifyError: Bad type on operand stack Exception Details: Location: tk/mybatis/mapper/generator/MapperCommentGenerator.addComment(Lorg/mybatis/generator/api/dom/xml/XmlElement;)V @10: invokevirtual Reason: Type 'org/mybatis/generator/api/dom/xml/TextElement' (current frame, stack[1]) is not assignable to 'org/mybatis/generator/api/dom/xml/Element' Current Frame: bci: @10 flags: { } locals: { 'tk/mybatis/mapper/generator/MapperCommentGenerator', 'org/mybatis/generator/api/dom/xml/XmlElement' } stack: { 'org/mybatis/generator/api/dom/xml/XmlElement', 'org/mybatis/generator/api/dom/xml/TextElement' } Bytecode: 0x0000000: 2bbb 0005 5912 06b7 0007 b600 08bb 0009 0x0000010: 59b7 000a 4d2c 120b b600 0c57 2c12 0eb6 0x0000020: 000c 572b bb00 0559 2cb6 000f b700 07b6 0x0000030: 0008 2bbb 0005 5912 10b7 0007 b600 08b1 0x0000040:
java.lang.VerifyError: Bad type on operand stack Exception Details: Location: tk/mybatis/mapper/generator/MapperCommentGenerator.addComment(Lorg/mybatis/generator/api/dom/xml/XmlElement;)V @10: invokevirtual Reason: Type 'org/mybatis/generator/api/dom/xml/TextElement' (current frame, stack[1]) is not assignable to 'org/mybatis/generator/api/dom/xml/Element' Current Frame: bci: @10 flags: { } locals: { 'tk/mybatis/mapper/generator/MapperCommentGenerator', 'org/mybatis/generator/api/dom/xml/XmlElement' } stack: { 'org/mybatis/generator/api/dom/xml/XmlElement', 'org/mybatis/generator/api/dom/xml/TextElement' } Bytecode: 0x0000000: 2bbb 0005 5912 06b7 0007 b600 08bb 0009 0x0000010: 59b7 000a 4d2c 120b b600 0c57 2c12 0eb6 0x0000020: 000c 572b bb00 0559 2cb6 000f b700 07b6 0x0000030: 0008 2bbb 0005 5912 10b7 0007 b600 08b1 0x0000040:
请教一下,这个日志是怎么生成的。
实测目前最多支持到1.3.7。 但扔需反馈一个bug。
使用以下插件配置后
配合 MyBatis Generator Maven Plugin 1.4.0的时候会报以下错误: