ejb 1.0 앱을 ejb 3.1 앱으로 마이그레이션 중입니다. 현재 응용 프로그램은 jdk 8의 WebLogic Server 버전 : 12.1.3.0.0에서 실행됩니다. POC의 경우 하나의 세션 빈과 하나의 엔터티 빈을 선택하고 업데이트 된 ejb-jar.xml, orm.xml 및 지속성을 제공하여 3.1로 업그레이드했습니다. .xml (아래). 나는 persistence.xml을 내 EJB-JAR/META-INF 디렉토리에 있음을 확인했다weblogic 12c "[xX] [mM] [1L]"과 일치하는 처리 명령 대상이 허용되지 않습니다.
weblogic.application.ModuleException: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 6; The processing instruction target matching "[xX][mM][lL]" is not allowed.
at weblogic.application.internal.ExtensibleModuleWrapper.prepare(ExtensibleModuleWrapper.java:114)
at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:100)
at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:175)
at weblogic.application.internal.flow.ModuleStateDriver$1.next(ModuleStateDriver.java:170)
at weblogic.application.utils.StateMachineDriver$ParallelChange.run(StateMachineDriver.java:80)
at weblogic.work.ContextWrap.run(ContextWrap.java:40)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:548)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:311)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:263)
Caused by: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 6; The processing instruction target matching "[xX][mM][lL]" is not allowed.
:
<?xml version="1.0" encoding="UTF-8"?>
<persistence version="2.0" xmlns="http://java.sun.com/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
<persistence-unit name="myPersistenceUnit" transaction-type="JTA">
<provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
<jta-data-source>java:/myDataSource</jta-data-source>
<exclude-unlisted-classes>false</exclude-unlisted-classes>
<properties>
<property name="hibernate.show_sql" value="false"/>
<property name="useColumnNamesInFindColumn" value="true"/>
<property name="useOldAliasMetadataBehavior" value="true"/>
</properties>
</persistence-unit>
</persistence>
나는 그러나 아래의 XML 파싱 오류를 얻고있다. 내 ejb.jar에서 persistence.xml을 제거하면 오류가 사라지고 세션 빈이 조회되고 엔티티 bean 지속성이 실패합니다. 그래서 오류가 persistence.xml에 있다고 가정합니다. UTF-8 형식으로 persistence.xml을 저장했습니다. 또한 일부 게시물에서 제안한대로 <?
앞에 빈 공간이 없는지 확인했습니다. 어떤 포인터?