简体   繁体   English

Maven / Java,IllegalStateException指的是什么?

[英]Maven / Java, what does IllegalStateException refer to?

I've been trying to run a Maven / Java application that should connect to an external server and start a visual tool. 我一直在尝试运行应连接到外部服务器并启动可视工具的Maven / Java应用程序。 I've tried to compile and run the code but I always have been reading the same error: 我尝试编译并运行代码,但我一直都在读取相同的错误:

[ERROR] Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:java
(default-cli) on project seco-mart-registration-tool: An exception occured while 
executing the Java class. null: InvocationTargetException: Cannot deserialize base type 
java.util.List<class org.seco.mart.model.interfaces.ServiceInterface> from C:\Users\Chicco
\Desktop\BioSeCoBis\seco-mart-server\data\marts\theatre.si (format: JSON, charset: UTF-8, 
autoClose: false). IllegalStateException -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal 
org.codehaus.mojo:exec-maven-plugin:1.2.1:java (default-cli) on project seco-mart-
registration-tool: An exception occured while executing the Java class. null

I have no idea of what this IllegalStateException could stand for. 我不知道这个IllegalStateException可以代表什么。 Do you have any clue? 你有什么线索吗?

Thanks 谢谢

The messages states the reason for the error, you just have to ignore some of the clutter: 这些消息指出了错误的原因,您只需要忽略一些混乱情况即可:

Cannot deserialize base type 无法反序列化基本类型
java.util.List<class org.seco.mart.model.interfaces.ServiceInterface>

The InvocationTargetException is thrown by the exec-maven-plugin which tried to run the whole thing and is caused by and uncatched IllegalStateException . InvocationTargetException由exec-maven-plugin引发,后者试图运行整个事件,并且是由未捕获的IllegalStateException引起的。 That exception probably tries to tell you that the object just can't be deserialized in its current state. 该异常可能试图告诉您,对象不能在其当前状态下反序列化。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM