Problem phenomenon
When a system is deployed on weblogic12.2.1.3, it reports an error “IllegalStateException zip file closed”. When it is deployed on weblogic12.2.1.2, it does not report an error and can be accessed normally.
Problem analysis
You can find the clear reason on the official website through the error report. The main reason is a bug in Weblogic. Because the application jar file is closed silently due to inactivity, because the jarfile class implements the autoclosable interface, and jarurlhandler does not handle this exception at present, this error is reported. Therefore, it is repaired through patch 27774698. The repair principle is to add a catch block to handle exceptions, And reopen the jar file when there is an IllegalStateException.
In addition, the official suggestion is to apply this patch only when reporting this error. It is not necessary to apply this patch to every system.
Problem continuation
The above problems are solved by patching 27774698, and the deployment application reports an error error creating bean with name ‘wsrmsafregistrationservice’. After that, you can see that spring is initializing bean and wsrmsafregistrationservice in the log, but its full class name is com.oracle.webservices.impl.wls.wsrmsafregistrationservice, which is used internally, @ inject @ named (“safserverservice”), private SAFServerService safServerService; Therefore, when spring does autowire automatic link, it scans the classes inside Weblogic. This scanning should not occur. Therefore, spring autowire filter should be added to the code to avoid scanning the classes inside Weblogic. For the specific adding method, see the official website link doc ID 2397321.1.
Problem handling
The problem of “IllegalStateException zip file closed” is solved by patching 27774698. After the application code is changed and the spring autowire filter is added, the application is successfully deployed and can be accessed normally. This problem is solved!
Read More:
- The Vue project is packaged and deployed to tomcat, and an Error 404 is reported as soon as it is refreshed
- [OpenGL · error] visual studio 2019 reports an error. It is an external symbol gladloadglloader that cannot be parsed. This symbol is referenced in the function main
- C# Member XXX cannot be accessed with an instance with an instance reference;qualify it with a type
- Vue introduction path is correct, but it always reports an error: already included file name‘ ××ב differs from file name ‘ ××ב only in casing.
- An error is reported when installing the package directly in pycharm, but it can be installed through the terminal. Error non zero exit code (2)
- “ XX.app ”It is damaged and cannot be opened. You should move it to the wastebasket.
- When the MAC M1 uiautomatorviewer is opened, it displays blank or reports an error
- Ant Design ‘cross env’ is not an internal or external command, nor is it an error reporting problem for a runnable program
- When the mybatis field contains an expression, an error is reported when it is stored in the database
- In chome browser, console reports an error but does not display it
- The web project removal server reports an error, and the web project in eclipse cannot be automatically deployed to Tomcat
- When SAP receives the goods, the system prompts that it can only be recorded in the period 2009 / 09 and 2009 / 08 of company code 1101
- It is invalid to submit the content directly after pasting it on the mobile terminal of Vue HTML5 editor
- Curl returns empty reply from server. Due to the processing of special characters, curl cannot be accessed and the browser can access it.
- Add a new springboot, and it will appear unable to read meta data for class when it is dependent
- After node.js is installed, use the instruction node version in vscode to show that it is not an external or internal instruction. The solution is as follows:
- It will appear as soon as it is turned on BTServer.exe -Application error (0xc0150002)
- When SSM + Maven project is running, it is prompted that org.springframework.web.servlet.dispatcherserservlet cannot be found
- Unity “Feature `out variable declaration’ cannot be used because it is not part of the C# 4.0” error
- When Dbeaver starts on Mac, it reports an error: “fail to create java virtual machine”