【问题标题】:Transferred from Netbeans to Eclipse, now "Severe: PWC6117: File "null" not found"从 Netbeans 转移到 Eclipse,现在“严重:PWC6117:找不到文件“null””
【发布时间】:2015-04-20 08:26:27
【问题描述】:

我将我的 Java maven netbeans glassfish Web 应用程序转移到了 Eclipse。它由一个 .jsp 和一些控制器 servlet 组成,供用户单击内容时使用。

它在 Netbeans 中运行(我右键单击 jsp 并运行它,然后加载网页)。某些控制器方法中的某些功能已损坏,但是当我运行它时网页仍然可以正常打开。

在 Eclipse 中,我右键单击 jsp 并在服务器上运行并获得以下内容(滚动到结尾):

2015-04-20T09:09:28.066+0100|Info: Running GlassFish Version: GlassFish Server Open Source Edition  4.1  (build 13)
2015-04-20T09:09:28.068+0100|Info: Server log file is using Formatter class: com.sun.enterprise.server.logging.ODLLogFormatter
2015-04-20T09:09:28.379+0100|Info: Realm [admin-realm] of classtype [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully created.
2015-04-20T09:09:28.380+0100|Info: Realm [file] of classtype [com.sun.enterprise.security.auth.realm.file.FileRealm] successfully created.
2015-04-20T09:09:28.385+0100|Info: Realm [certificate] of classtype [com.sun.enterprise.security.auth.realm.certificate.CertificateRealm] successfully created.
2015-04-20T09:09:28.609+0100|Info: Authorization Service has successfully initialized.
2015-04-20T09:09:29.171+0100|Info: Registered org.glassfish.ha.store.adapter.cache.ShoalBackingStoreProxy for persistence-type = replicated in BackingStoreFactoryRegistry
2015-04-20T09:09:29.894+0100|Info: Grizzly Framework 2.3.15 started in: 458ms - bound to [/0.0.0.0:8080]
2015-04-20T09:09:30.073+0100|Info: visiting unvisited references
2015-04-20T09:09:30.286+0100|Info: Grizzly Framework 2.3.15 started in: 335ms - bound to [/0.0.0.0:8181]
2015-04-20T09:09:30.360+0100|Info: Grizzly Framework 2.3.15 started in: 37ms - bound to [/0.0.0.0:4848]
2015-04-20T09:09:30.410+0100|Info: Grizzly Framework 2.3.15 started in: 2ms - bound to [/0.0.0.0:3700]
2015-04-20T09:09:30.771+0100|Info: Java security manager is disabled.
2015-04-20T09:09:30.773+0100|Info: Entering Security Startup Service.
2015-04-20T09:09:30.776+0100|Info: Loading policy provider com.sun.enterprise.security.provider.PolicyWrapper.
2015-04-20T09:09:30.823+0100|Info: Security Service(s) started successfully.
2015-04-20T09:09:31.041+0100|Info: Created HTTP listener http-listener-1 on host/port 0.0.0.0:8080
2015-04-20T09:09:31.052+0100|Info: Created HTTP listener http-listener-2 on host/port 0.0.0.0:8181
2015-04-20T09:09:31.055+0100|Info: Created HTTP listener admin-listener on host/port 0.0.0.0:4848
2015-04-20T09:09:31.080+0100|Info: Created virtual server server
2015-04-20T09:09:31.090+0100|Info: Created virtual server __asadmin
2015-04-20T09:09:31.348+0100|Info: Setting JAAS app name glassfish-web
2015-04-20T09:09:31.349+0100|Info: Virtual server server loaded default web module 
2015-04-20T09:09:32.301+0100|Info: visiting unvisited references
2015-04-20T09:09:32.455+0100|Info: visiting unvisited references
2015-04-20T09:09:32.476+0100|Info: visiting unvisited references
2015-04-20T09:09:32.481+0100|Info: visiting unvisited references
2015-04-20T09:09:32.482+0100|Info: visiting unvisited references
2015-04-20T09:09:32.763+0100|Info: Portable JNDI names for EJB Info: [java:global/animelist1/Info, java:global/animelist1/Info!entities.Info]
2015-04-20T09:09:32.825+0100|Info: Portable JNDI names for EJB AnnJAXB: [java:global/animelist1/AnnJAXB, java:global/animelist1/AnnJAXB!main.AnnJAXB]
2015-04-20T09:09:32.836+0100|Info: Portable JNDI names for EJB Ann: [java:global/animelist1/Ann!entities.Ann, java:global/animelist1/Ann]
2015-04-20T09:09:32.850+0100|Info: Portable JNDI names for EJB Anime: [java:global/animelist1/Anime!entities.Anime, java:global/animelist1/Anime]
2015-04-20T09:09:32.884+0100|Info: WELD-000900: 2.2.2 (Final)
2015-04-20T09:09:33.140+0100|Info: HV000001: Hibernate Validator 5.0.0.Final
2015-04-20T09:09:33.413+0100|WARN: WELD-001700: Interceptor annotation class javax.ejb.PostActivate not found, interception based on it is not enabled
2015-04-20T09:09:33.414+0100|WARN: WELD-001700: Interceptor annotation class javax.ejb.PrePassivate not found, interception based on it is not enabled
2015-04-20T09:09:33.606+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] private org.glassfish.jersey.gf.cdi.internal.CdiComponentProvider.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:33.622+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] public org.glassfish.jms.injection.JMSCDIExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:33.646+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] org.glassfish.sse.impl.ServerSentEventCdiExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>, BeanManager) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:34.749+0100|Info: Loading application [animelist1] at [/animelist1]
2015-04-20T09:09:34.753+0100|Info: Loading application animelist1 done in 5,562 ms
2015-04-20T09:09:34.769+0100|Info: GlassFish Server Open Source Edition  4.1  (13) startup time : Felix (2,265ms), startup services(6,789ms), total(9,054ms)
2015-04-20T09:09:35.197+0100|Info: Grizzly Framework 2.3.15 started in: 130ms - bound to [/0.0.0.0:7676]
2015-04-20T09:09:35.284+0100|Info: Registered com.sun.enterprise.glassfish.bootstrap.osgi.EmbeddedOSGiGlassFishImpl@4ae263bf as OSGi service registration: org.apache.felix.framework.ServiceRegistrationImpl@49a71302.
2015-04-20T09:09:35.354+0100|Info: C:\Program Files\glassfish4\glassfish\domains\domain1\autodeploy\bundles does not exist, please create it.
2015-04-20T09:09:36.159+0100|Info: JMXStartupService has started JMXConnector on JMXService URL service:jmx:rmi://J-PC:8686/jndi/rmi://J-PC:8686/jmxrmi
2015-04-20T09:09:36.234+0100|Info: keepstate options resolved to true, saving appId 93684827868430336 for application animelist1.
2015-04-20T09:09:36.840+0100|Info: visiting unvisited references
2015-04-20T09:09:37.021+0100|Info: visiting unvisited references
2015-04-20T09:09:37.036+0100|Info: visiting unvisited references
2015-04-20T09:09:37.047+0100|Info: visiting unvisited references
2015-04-20T09:09:37.048+0100|Info: visiting unvisited references
2015-04-20T09:09:37.049+0100|Info: visiting unvisited references
2015-04-20T09:09:37.153+0100|Info: Portable JNDI names for EJB AnnJAXB: [java:global/animelist1/AnnJAXB, java:global/animelist1/AnnJAXB!main.AnnJAXB]
2015-04-20T09:09:37.169+0100|Info: Portable JNDI names for EJB Ann: [java:global/animelist1/Ann!entities.Ann, java:global/animelist1/Ann]
2015-04-20T09:09:37.186+0100|Info: Portable JNDI names for EJB Anime: [java:global/animelist1/Anime!entities.Anime, java:global/animelist1/Anime]
2015-04-20T09:09:37.201+0100|Info: Portable JNDI names for EJB Info: [java:global/animelist1/Info, java:global/animelist1/Info!entities.Info]
2015-04-20T09:09:37.302+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] public org.glassfish.jms.injection.JMSCDIExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:37.315+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] private org.glassfish.jersey.gf.cdi.internal.CdiComponentProvider.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:37.327+0100|WARN: WELD-000411: Observer method [BackedAnnotatedMethod] org.glassfish.sse.impl.ServerSentEventCdiExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>, BeanManager) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds.
2015-04-20T09:09:38.201+0100|Info: Loading application [animelist1] at [/animelist1]
2015-04-20T09:09:38.252+0100|Info: animelist1 was successfully deployed in 2,101 milliseconds.
2015-04-20T09:09:38.680+0100|Severe: PWC6117: File "null" not found

我是 Eclipse 的新手,也是编程的新手。在 Eclipse 中打开项目时,我可能需要更改一些内容吗?这是一个maven项目,我在eclipse中用maven打开它,一切都很顺利。

或者,有没有办法可以找到有关错误的更多详细信息?当我用谷歌搜索PWC6117: File "null" not found 时,它似乎是人们代码中的特定错误,而我的代码在 netbeans 上运行良好,所以我不知道如何缩小范围

谢谢

【问题讨论】:

标签: java eclipse maven netbeans


【解决方案1】:

我遇到了类似的问题,这与我的welcome file not being defined. 有关 在您的情况下,它可能已在 Netbeans 中定义,但未在 Eclipse 中定义。

【讨论】:

    【解决方案2】:

    由于您的上下文已加载,您的应用程序将始终使用以下 url 模式加载

    protocol//:hostname:port/context-name

    请参阅 How to set the context 了解您的 Web 应用程序。默认情况下,上下文名称是您的项目名称。但是,您可以在 web.xml 文件中更改任何您想要的内容。

    所以你必须使用 url 加载应用程序,

    http://localhost:8080/animelist1

    【讨论】:

      【解决方案3】:

      您应该检查WEB-INF/jsp/ 文件夹中是否有index.jsp。或者您在web.xml 中设置为欢迎文件的任何内容。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2015-04-06
        • 2011-09-30
        • 2011-01-08
        • 2014-12-05
        • 2017-05-16
        • 2013-07-25
        • 2011-10-13
        • 2012-05-08
        相关资源
        最近更新 更多