Logback找不到使用insertFromJNDI在weblogic上运行的所有应用程序 [英] Logback can't find all applications running on weblogic using insertFromJNDI

查看:245
本文介绍了Logback找不到使用insertFromJNDI在weblogic上运行的所有应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在努力找出问题所在.我有一台weblogic 10.3.5.0服务器,已在其中部署了三个应用程序.一个yui应用程序和两个自定义Java应用程序.这些位于测试服务器上.当您使用这些应用程序时,它们可以正常运行,但只有yui会记录日志(logback 1.1.2).

I'm having a real struggle finding out whats wrong. I have a weblogic 10.3.5.0 server where I have deployed three apps. One yui app and two custom java-apps. These are located on a test server. The apps are working fine when you use them, but only yui is logging (logback 1.1.2).

我在本地部署了一个完全相同的应用程序,一切正常.

I have a identical app deployed locally where everything works as intended.

我在logback.xml中使用inserFromJNDI并加载:

I use inserFromJNDI in logback.xml and it loads:

<?xml version="1.0" encoding="UTF-8"?>
<configuration scan="true">
    <insertFromJNDI env-entry-name="java:comp/env/applicationName" as="applicationName" />
    <contextName>{$applicationName}</contextName>
    <jmxConfigurator />
...
</configuration>

在本地它会加载所有三个应用程序,但是在测试服务器上它只会加载yui.

Locally it loads all three apps, but at the test server it only loads yui.

我使用了WLST,并检查了所有应用程序都在domainRuntime()中列出.

I've used WLST and checked that all apps are listed in domainRuntime().

有人可以对此做进一步调查吗?或有一些提示?

Does anyone how to investigate this further? Or have some tips?

如果您需要更多信息,请告诉我,我会提供.谢谢!

Please tell me if you need more info and I will provide. Thank you!

推荐答案

WebLogic和应用程序之间可能存在一些冲突的jar.我有一个类似的问题,在更新WebLogic之后没有日志出现,这是通过将以下内容添加到每个应用程序的weblogic.xml中解决的.

You might have some conflicting jars between WebLogic and your application. I had a similar issue where no logs were appearing after updating WebLogic that was solved by adding the following to the weblogic.xml for each application.

<wls:container-descriptor>
        <wls:prefer-application-packages>
            <wls:package-name>org.slf4j</wls:package-name>
        </wls:prefer-application-packages>
</wls:container-descriptor>

这篇关于Logback找不到使用insertFromJNDI在weblogic上运行的所有应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆