Unable to login into Capture for JIRA

症状

atlassian-jira.log に次のメッセージが表示される。

2013-09-27 14:03:24,328 http-bio-8080-exec-7906 ERROR admin 843x912355x1 vxlf28 10.0.50.131 /rest/bonfire/1.0/sessions/user [atlassian.bonfire.rest.SessionResource] Unable to complete Bonfire REST method 
java.lang.NullPointerException
at com.atlassian.bonfire.predicates.UserIsParticipantPredicate.apply(UserIsParticipantPredicate.java:20)
	at com.atlassian.bonfire.predicates.UserIsParticipantPredicate.apply(UserIsParticipantPredicate.java:8)
	at com.google.common.collect.Iterators.any(Iterators.java:681)
	at com.google.common.collect.Iterables.any(Iterables.java:617)
	at com.atlassian.bonfire.service.BonfirePermissionServiceImpl.canCreateNote(BonfirePermissionServiceImpl.java:69)
	at com.atlassian.bonfire.util.SessionDisplayUtils.getDisplayHelper(SessionDisplayUtils.java:67)
	at com.atlassian.bonfire.rest.SessionResource.createSessionBeanForExtension(SessionResource.java:870)
	at com.atlassian.bonfire.rest.SessionResource.access$8300(SessionResource.java:81)
	at com.atlassian.bonfire.rest.SessionResource$15.call(SessionResource.java:682)
	at com.atlassian.bonfire.rest.SessionResource$15.call(SessionResource.java:647)
	at com.atlassian.bonfire.rest.util.RestCall.response(RestCall.java:36)
	at com.atlassian.bonfire.rest.util.BonfireRestResource.response(BonfireRestResource.java:53)
	at com.atlassian.bonfire.rest.SessionResource.getSessionsForExtension(SessionResource.java:646)
	at sun.reflect.GeneratedMethodAccessor5686.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper$ResponseOutInvoker$1.invoke(DispatchProviderHelper.java:234)
	at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper$1.intercept(DispatchProviderHelper.java:100)
	at com.atlassian.plugins.rest.common.interceptor.impl.DefaultMethodInvocation.invoke(DefaultMethodInvocation.java:61)
	at com.atlassian.plugins.rest.common.expand.interceptor.ExpandInterceptor.intercept(ExpandInterceptor.java:38)
	at com.atlassian.plugins.rest.common.interceptor.impl.DefaultMethodInvocation.invoke(DefaultMethodInvocation.java:61)
	at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper.invokeMethodWithInterceptors(DispatchProviderHelper.java:132)
	at com.atlassian.plugins.rest.common.interceptor.impl.DispatchProviderHelper$ResponseOutInvoker._dispatch(DispatchProviderHelper.jav

また、atlassian-bonfire.log には次の内容が表示される。

2013-10-01 16:14:38,821 http-bio-8080-exec-8591 ERROR admin 974x1071588x2 14pbsyh 10.0.50.76 /sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml [com.atlassian.velocity.DefaultVelocityManager] MethodInvocationException occurred getting message body from Velocity: com.atlassian.jira.util.dbc.Assertions$NullArgumentException: participant should not be null!
com.atlassian.jira.util.dbc.Assertions$NullArgumentException: participant should not be null!

原因

原因 1:

There is a lost permission (which is not one of JIRA's default permissions) in one permission scheme, which is causing Capture for JIRA to block the users from logging in for lack of permissions. This permission may have been added by a third-party plugin.

原因 2:

There is a test session in a JIRA project that contains a reference for broken participants in the test session. Check the second resolution if this is the case.

ソリューション 1

The resolution will be to remove this lost permission directly in the database:

  1. Create an XML Backup (Administration -> System -> Import & Export), so in case anything goes wrong we have rollback point.

  2. Jira をシャットダウンします。
  3. Run the following query in your database:

    DELETE FROM schemepermissions WHERE perm_type NOT IN ('group', 'projectrole', 'reporter', 'user', 'lead', 'assignee', 'groupCF', 'userCF');
  4. Jira を起動します。
  5. Try to login into Capture for JIRA

ソリューション 2

  1. Open all of your test sessions from all projects and find the one that's broken. You will identify the test broken test session when you click on it, as it will take you to an error page;
  2. Once the broken test session is identified, click with the right mouse button over the test session name and choose the "Copy Link" option. Paste the link in a text file to analyse the URL shown. It will show you something like this:

    (info) See the "testSessionID" value from the URL. In this case is 10066. Keep this number as we will use this value later.

  3. Generate an XML Backup from JIRA so in case anything goes wrong during the database update we have point to rollback the instance to.
  4. Jira をシャットダウンします。
  5. Run the following query in the database to find the value of the broken Test session:

    SELECT ID, ENTITY_NAME, ENTITY_ID, PROPERTY_KEY, propertytype FROM propertyentry WHERE ENTITY_NAME='Excalibur.Session.Storage' AND ENTITY_ID='xxxx' AND PROPERTY_KEY='data';

    (info) Where 'xxxx' from the query above will be the ID you found in the URL.

  6. Remember the first value from the output of this query, which will be something like:

    +-------+---------------------------+-----------+--------------+--------------+
    | ID | ENTITY_NAME | ENTITY_ID | PROPERTY_KEY | propertytype |
    +-------+---------------------------+-----------+--------------+--------------+
    | 17229 | Excalibur.Session.Storage | 10042 | data | 6 |
    +-------+---------------------------+-----------+--------------+--------------+

    (info) Remember the value from the ID column, which is not the same value you used before. This one is the "ENTITY_ID" value and will no longer be used.

  7. If this query returns a valid output, run the query below to delete it from JIRA:

    DELETE FROM propertyentry WHERE id='xxxxx';

    (info) Where 'xxxxx' will be the ID (value from the first column) of the query above.

  8. Run the first select again to confirm that the value has been deleted;
  9. Start JIRA:
  10. Check if Capture for JIRA is working fine;


 

Last modified on Mar 30, 2016

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

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