was crawled

1.war package needs to be deleted

org.apache.xerces-2.9.0.jar
org.apache.xml.serializer-2.7.1.jar
stax-api-1.0.1.jar
xercesImpl-2.9.1.jar
xml-apis-1.3.04.jar
xml-apis-ext-1.3.04.jar
xmlbeans-2.6.0.jar
Saxon-HE-9.9.1-4.jar

2. An error is reported when the application starts

Caused by: java.lang.RuntimeException: XPathFactory#newInstance() failed to create an XPathFactory for the default object model: http://java.sun.com/jaxp/xpath/dom with the XPathFactoryConfigurationException: javax.xml.xpath.XPathFactoryConfigurationException: No XPathFctory implementation found for the object model: http://java.sun.com/jaxp/xpath/dom
需要将Saxon-HE-9.9.1-5.jar更新为最新版本

3. Process template deployment error

Insert picture description hereInsert picture description here
Remove stax-api-1.0.1.jar and xercesImpl-2.9.1.jar from the class path lib to ensure that there are no shared libraries, although there may not be a class loader associated with the application.
Another mistake: ObjectMapper uses the class loaded by the parent class loader, so change the application to the parent class loader and load it.

4. Document upload failed:

java.io.IOException: java.io.FileNotFoundException: /opt/IBM/WebSphere/AppServer/profiles/AppSrv01/temp/localhostNode01/server1/xcrms10211_war/xcrms10211.war/home/software/tomcat/tomcatgh/word/20191017 customer communication subsystem before feedback problems 20191022043059356.docx (no such file or directory)
can not be called file.transferTo (dest)
directly BufferedOutputStream

private void uploadFileFromTemp(MultipartFile file, File dest){

	BufferedInputStream in = null;
	BufferedOutputStream out = null;
	
	try {
		in = new BufferedInputStream(file.getInputStream());
		out = new BufferedOutputStream(new FileOutputStream(dest));
		IOUtils.copy(in, out);
		out.close();
	} catch (IOException e) {
		e.printStackTrace();
		throw new XcrmsException("上传文件出错", e);
	} finally {
		IOUtils.closeQuietly(in);
		IOUtils.closeQuietly(out);
	}
}
Published 6 original articles · won 3 · views 6075

Guess you like

Origin blog.csdn.net/Today_1st/article/details/102743940