java.lang.ClassNotFoundException: com.sun.faces.util.ReflectionUtils $ ReflectionUtilsListener после обновления JSF 1.2 до JSF 2.2 - PullRequest
0 голосов
/ 03 октября 2018

Мы используем следующие технологии / фреймворки:

  1. Spring 2_5 -> Spring 5_0_9
  2. JSF 1_2 -> 2_2
  3. Java 6 -> Java 8
  4. Tomcat 6 -> Tomcat 8_5

Ниже приведена ошибка, с которой я сталкиваюсь при обновлении:

INFO: Starting Servlet Engine: Apache Tomcat/8.5.4
Oct 03, 2018 3:32:59 PM org.apache.jasper.servlet.TldScanner scanJars
INFO: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
Oct 03, 2018 3:33:07 PM org.apache.jasper.servlet.TldScanner scanJars
INFO: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
Oct 03, 2018 3:33:07 PM org.apache.catalina.core.ContainerBase startInternal
SEVERE: A child container failed during start

    java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/TEST]]
        at java.util.concurrent.FutureTask.report(FutureTask.java:122)
        at java.util.concurrent.FutureTask.get(FutureTask.java:192)
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:911)
        at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:890)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:152)
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1403)
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1393)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)
    Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/TEST]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:158)
        ... 6 more
    Caused by: java.lang.IllegalArgumentException: Unable to create an instance of type [com.sun.faces.util.ReflectionUtils$ReflectionUtilsListener]
        at org.apache.catalina.core.ApplicationContext.addListener(ApplicationContext.java:1027)
        at org.apache.catalina.core.ApplicationContextFacade.addListener(ApplicationContextFacade.java:647)
        at org.apache.jasper.servlet.JasperInitializer.onStartup(JasperInitializer.java:110)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5167)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:152)
        ... 6 more
    Caused by: java.lang.ClassNotFoundException: com.sun.faces.util.ReflectionUtils$ReflectionUtilsListener
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1284)
        at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1118)
        at org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:520)
        at org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:501)
        at org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:118)
        at org.apache.catalina.core.ApplicationContext.addListener(ApplicationContext.java:1009)
        ... 10 more

1 Ответ

0 голосов
/ 04 октября 2018

Проверьте, содержит ли ваш проект файл .TLD из файла jsf-impl.jar.Сравните это с TLD старой банки.Если они оба одинаковы, то сделайте следующее: откройте новый файл JAR из JD-GUI, возьмите новый файл .TLD и замените существующим TLD вашего проекта, затем очистите все и попробуйте снова.

...