Confluence will not start after adding AppDynamics to instance

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: サーバーと Data Center のみ。この記事は、サーバーおよび Data Center プラットフォームのアトラシアン製品にのみ適用されます。



問題

When adding AppDynamics to your Confluence installation for monitoring the instance, you may find that Confluence will not start properly after the agent has been added to the server. You may see an ERROR message when attempting to access the instance:

System Error

A system error has occurred — our apologies!

For immediate troubleshooting, consult our knowledge base for a solution.

If you would like to receive support from Atlassian's support team, ask your Confluence administrator to create a support issue on Atlassian's support system with the following information:

1.     a description of your problem and what you were doing at the time it occurred

2.     a copy of the error and system information found below

3.     a copy of the application logs (if possible).

Your Confluence administrator can use the support request form to create a support ticket which will include this information.

We will respond as promptly as possible.
Thank you!

Return to site homepage…

STACKTRACE

You may also see the following stacktrace in the system:

java.lang.IllegalStateException: There should be at least one AvatarProvider module registered in the plugin system.
        at com.atlassian.confluence.user.avatar.AvatarProviderAccessor.getAvatarProvider(AvatarProviderAccessor.java:30)
        at com.atlassian.confluence.user.DefaultUserAccessor.getLogoForUser(DefaultUserAccessor.java:684)
        at com.atlassian.confluence.user.DefaultUserAccessor.lambda$getUserProfilePicture$3(DefaultUserAccessor.java:750)
        at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:133)
        at com.atlassian.confluence.user.DefaultUserAccessor.getUserProfilePicture(DefaultUserAccessor.java:748)
        at sun.reflect.GeneratedMethodAccessor388.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:498)
        at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
        at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
        at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
        at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
        at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
        at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
        at com.sun.proxy.$Proxy83.getUserProfilePicture(Unknown Source)
        ...
 

原因

This ERROR and exception is caused by the fact that AppDynamics uses OSGI Containers. By default, OSGi containers follow a specific model for bootstrap class delegation. Classes that are not specified in the container's CLASSPATH are not delegated to the bootstrap classloader; therefore you must configure the OSGi containers for the App Server Agent classes.

ソリューション

In order to configure the AppDynamics agent, you need to add several lines to the JAVA_OPTS in your application as per the official documentation in order to have Confluence start properly. If you do not add the following lines, then the application will fail to start as the AppDynamics agent will cause issues.

  1. To configure Felix for Jira or Confluence (For JIRA 5.1.8 and newer or Confluence 5.3 and newer):
  2. Update the startup script (e.g. catalina) with the following Java system property:


-Datlassian.org.osgi.framework.bootdelegation=META-INF.services,com.yourkit,com.singularity.*,com.jprofiler,com.jprofiler.*,
org.apache.xerces,org.apache.xerces.*,org.apache.xalan,org.apache.xalan.*,sun.*,com.sun.jndi,com.icl.saxon,com.icl.saxon.*,javax.servlet,javax.servlet.*,
com.sun.xml.bind.*,jdk.internal.reflect,jdk.internal.reflect.*

Update the Java options:

  1. For Linux: JAVA_OPTS=
  2. For Windows: set JAVA_OPTS=%JAVA_OPTS%
-javaagent:/root/AppServerAgent/javaagent.jar"

Confluence 6.13+ comes with an Adopt OpenJDK bundled. To work with Adopt OpenJDK, ensure that you're using an AppDynamics Java Agent 4.5.19. Otherwise, switch to system Java instead of the bundled JRE, to work with Oracle JRE.


(warning) Please add the missing configuration as per the official documentation from AppDynamics to your instance and retry the operation in a test environment first. You must test and validate these settings in a Test or Staging environment first to determine if this solution will work in your environment. As this is a third-party solution, you should consult with AppDynamics if there are additional issues with the monitoring tool.


最終更新日 2022 年 6 月 8 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.