There is no ID mapped for the user key

Vitaly Razin October 6, 2017

Hello,

When creating a report

https://localhost/secure/ConfigureReport.jspa?startDate=01.08.2017&endDate=31.08.2017&targetGroup=&excludeTargetGroup=analyst&projectRoleId=&projectid=&filterid=&groupByField=customfield_11300&moreFields=&selectedProjectId=12700&reportKey=jira-timesheet-plugin%3Aprojectpivot&atl_token=...

the report falls with an error

ERROR Servlet.service() for servlet [action] in context with path [] threw exception [java.lang.IllegalStateException:
There is no ID mapped for the user key 'user'] with root cause
java.lang.IllegalStateException: There is no ID mapped for the user key 'user'
        at com.atlassian.jira.user.DefaultUserPropertyManager.getPropertySetForUserKey(DefaultUserPropertyManager.java:32)
        at com.atlassian.jira.user.DefaultUserPropertyManager.getPropertySet(DefaultUserPropertyManager.java:25)
        at com.atlassian.jira.user.preferences.DefaultUserPreferencesManager.getExtendedPreferences(DefaultUserPreferencesManager.java:22)
        at com.atlassian.jira.user.preferences.DefaultUserPreferencesManager.getPreferences(DefaultUserPreferencesManager.java:27)
        at com.atlassian.jira.timezone.TimeZoneManagerImpl.getTimeZoneforUser(TimeZoneManagerImpl.java:39)
        ... 2 filtered
        at java.lang.reflect.Method.invoke(Method.java:498)
        at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26)
        at com.sun.proxy.$Proxy222.getTimeZoneforUser(Unknown Source)
        ... 2 filtered
        at java.lang.reflect.Method.invoke(Method.java:498)
        at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:136)
        at com.sun.proxy.$Proxy222.getTimeZoneforUser(Unknown Source)
        at jira.plugin.report.timesheet.TimeBaseService.getTimeSpents(TimeBaseService.java:374)
        at com.fdu.jira.plugin.report.pivot.Pivot.generateReport(Pivot.java:81)
        at com.fdu.jira.plugin.report.AbstractTimebaseReport.generateReportHtml(AbstractTimebaseReport.java:114)
        at com.atlassian.jira.plugin.corereports.web.action.ConfigureReport.doExecute(ConfigureReport.java:172)
        ... 1 filtered
        at com.atlassian.jira.action.JiraActionSupport.execute(JiraActionSupport.java:63)
        ... 7 filtered
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        ... 19 filtered
        at com.softwareplant.ppm.structureint.jiraserver.event.PluginIssueLinkListener.doFilter(PluginIssueLinkListener.java:55)
        ... 36 filtered
        at com.atlassian.greenhopper.jira.filters.ClassicBoardRouter.doFilter(ClassicBoardRouter.java:62)
        ... 7 filtered
        at com.atlassian.jira.plugin.corereports.filters.ReportKeyRewriter.doFilter(ReportKeyRewriter.java:48)
        ... 4 filtered
        at com.atlassian.web.servlet.plugin.request.RedirectInterceptingFilter.doFilter(RedirectInterceptingFilter.java:21)
        ... 58 filtered
        at com.atlassian.jira.security.JiraSecurityFilter.lambda$doFilter$0(JiraSecurityFilter.java:76)
        ... 1 filtered
        at com.atlassian.jira.security.JiraSecurityFilter.doFilter(JiraSecurityFilter.java:74)
        ... 36 filtered
        at com.atlassian.jira.servermetrics.CorrelationIdPopulatorFilter.doFilter(CorrelationIdPopulatorFilter.java:30)
        ... 10 filtered
        at com.atlassian.web.servlet.plugin.request.RedirectInterceptingFilter.doFilter(RedirectInterceptingFilter.java:21)
        ... 4 filtered
        at com.atlassian.web.servlet.plugin.LocationCleanerFilter.doFilter(LocationCleanerFilter.java:36)
        ... 29 filtered
        at com.atlassian.jira.servermetrics.MetricsCollectorFilter.doFilter(MetricsCollectorFilter.java:25)
        ... 28 filtered
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:745)

 this action did not help There is no ID mapped for the user key

In the database I found this user in the table USERHISTORYITEM

can this be the problem?

 

1 answer

0 votes
Andy Heinzer
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 9, 2017

This error indicates there is a problem with records in the Jira database.  Run this SQL query first:

select * from app_user where user_key='user';

You can change that 'user' to the value in your error message.  This should return an id, user_key, and lower_user_name.   The lower_user_name value here is expected to sync up with the cwd_user table's lower_user_name value for some record of some user.

So you should have at least 1 value when running:

select * from cwd_user where lower_user_name='value returned from first query';'

If you don't have any results, then there is something missing in the database.

Vitaly Razin October 10, 2017

The Jira is synchronized with the LDAP. The problem is that some people have renamed the LDAP user login. After the synchronization, authorization problems appeared in the Jira. We had to make changes to the database. To solve the problem.

I apologize for not accurately describing the problem.

This user is not needed at all, which I can still clean up, or rename the user in the user1 to make the report work.

Suggest an answer

Log in or Sign up to answer