项目场景:
新版的idea使用Free MyBatis plugin插件报错
问题描述
错误信息
java.lang.Throwable: '#LineMarkerInfo(T, TextRange, Icon, int, Function, GutterIconNavigationHandler, Alignment)' is deprecated and going to be removed soon. Please use `LineMarkerInfo(T, TextRange, Icon, Function, GutterIconNavigationHandler, Alignment, Supplier)` instead
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:182)
at com.intellij.diagnostic.PluginException.reportDeprecatedUsage(PluginException.java:105)
at com.intellij.codeInsight.daemon.LineMarkerInfo.<init>(LineMarkerInfo.java:162)
at com.wuzhizhan.mybatis.provider.SimpleLineMarkerProvider.getLineMarkerInfo(SimpleLineMarkerProvider.java:44)
at com.intellij.codeInsight.daemon.impl.LineMarkersPass.queryProviders(LineMarkersPass.java:160)
at com.intellij.codeInsight.daemon.impl.LineMarkersPass.lambdadoCollectInformationdoCollectInformation3(LineMarkersPass.java:85)
at com.intellij.codeInsight.daemon.impl.Divider.divideInsideAndOutsideInOneRoot(Divider.java:115)
at com.intellij.codeInsight.daemon.impl.LineMarkersPass.doCollectInformation(LineMarkersPass.java:80)
at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:56)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.lambdaScheduledPass.lambdadoRun1(PassExecutorService.java:414)atcom.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1084)atcom.intellij.codeInsight.daemon.impl.PassExecutorService1(PassExecutorService.java:414)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1084)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.lambdadoRundoRun2(PassExecutorService.java:407)
at com.intellij.openapi.progress.impl.CoreProgressManager.lambdaexecuteProcessUnderProgressexecuteProcessUnderProgress12(CoreProgressManager.java:624)
at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:698)
at com.intellij.openapi.progress.impl.CoreProgressManager.computeUnderProgress(CoreProgressManager.java:646)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:623)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:66)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.doRun(PassExecutorService.java:406)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.doRun(PassExecutorService.java:406)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.lambdarunrun0(PassExecutorService.java:382)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:174)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:181)
at com.intellij.codeInsight.daemon.impl.PassExecutorServiceScheduledPass.run(PassExecutorService.java:380)
at com.intellij.concurrency.JobLauncherImplScheduledPass.run(PassExecutorService.java:380)
at com.intellij.concurrency.JobLauncherImplVoidForkJoinTask1.exec(JobLauncherImpl.java:184)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
at java.base/java.util.concurrent.ForkJoinPool1.exec(JobLauncherImpl.java:184)
at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
at java.base/java.util.concurrent.ForkJoinPoolWorkQueue.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:183)
原因分析:
因为这个插件已经没人维护了
解决方案:
改用Free MyBatis Tool插件,地址:Free MyBatis Tool - IntelliJ IDEs Plugin | Marketplace