<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How do I get user info from userID in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32093#M13595</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah, now it makes sense. When you add an attach file option in the form, the next task will turn async. That means it is no longer executed under the logged in user context! Hence you get null. Try executing your logic from an execution listener attached to the start&amp;nbsp;activity&amp;nbsp;or on the sequence flow if you really need the user context.&amp;nbsp;It is not a bug, it is working as designed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 12 Oct 2017 00:09:04 GMT</pubDate>
    <dc:creator>cjose</dc:creator>
    <dc:date>2017-10-12T00:09:04Z</dc:date>
    <item>
      <title>How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32078#M13580</link>
      <description>I have been researching and found out that this is the best way to current usr info from activiti DB. However, it comes out to be null.This is my code.. First, I get userIDList&amp;lt;IdentityLink&amp;gt; identityLink = processEngine.getRuntimeService().getIdentityLinksForProcessInstance(processID);Iteratin</description>
      <pubDate>Mon, 09 Oct 2017 20:51:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32078#M13580</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-09T20:51:01Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32079#M13581</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;btw,&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;ProcessEngine processEngine = ProcessEngines.getDefaultProcessEngine();&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Oct 2017 21:04:56 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32079#M13581</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-09T21:04:56Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32080#M13582</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This returns null as well..&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;List&amp;lt;String&amp;gt; userInfos = processEngine.getIdentityService().getUserInfoKeys(userID);&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Oct 2017 21:17:12 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32080#M13582</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-09T21:17:12Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32081#M13583</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;which version are you using? The Community version or the Enterprise version (Alfresco Process Services)?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Oct 2017 21:57:38 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32081#M13583</guid>
      <dc:creator>cjose</dc:creator>
      <dc:date>2017-10-10T21:57:38Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32082#M13584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the response. &lt;/P&gt;&lt;P&gt;I was developing on community but server is enterprise. I have now switched development to Enterprise and using this command to retrieve userinfo but it still throws&amp;nbsp; null pointer.. I have following in my file&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;import com.activiti.service.api.UserService;&lt;/P&gt;&lt;P&gt;@Autowired&lt;BR /&gt;&amp;nbsp;static UserService userService;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;User user = userService.findUser(Long.parseLong(userID)); (Getting UserID from IdentityLink code above.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 18:20:54 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32082#M13584</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T18:20:54Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32083#M13585</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;import com.activiti.domain.idm.User;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 18:22:19 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32083#M13585</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T18:22:19Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32084#M13586</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yeah, if server is enterprise, you need to use the enterprise apis. The identity implementation in Alfresco Process Services is different from what is available in the core engine. Hence it is returning null (as per your original post) when you try to use the core engine apis&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 18:45:45 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32084#M13586</guid>
      <dc:creator>cjose</dc:creator>
      <dc:date>2017-10-11T18:45:45Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32085#M13587</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am now using enterprise .. do you know which API can give me userinfo &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I saw similar post ..&lt;/P&gt;&lt;P&gt;&lt;A href="https://migration33.stage.lithium.com/thread/227323"&gt;How to get user firstname and lastname in a generated document&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;but haven't had any luck yet&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 18:59:29 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32085#M13587</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T18:59:29Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32086#M13588</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you looking to get a user who is currently logged id? If yes, you can use the following.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;com.activiti.domain.idm.User currentUser = SecurityUtils.getCurrentUserObject();&amp;nbsp; This page has an example -&amp;nbsp;&lt;A class="link-titled" href="https://docs.alfresco.com/process-services1.7/topics/custom_rest_endpoints.html" title="https://docs.alfresco.com/process-services1.7/topics/custom_rest_endpoints.html" rel="nofollow noopener noreferrer"&gt;Custom REST endpoints | Alfresco Documentation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 19:07:33 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32086#M13588</guid>
      <dc:creator>cjose</dc:creator>
      <dc:date>2017-10-11T19:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32087#M13589</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, I am looking for current logged in user.. Thanks ! . Let me try this&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 19:20:27 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32087#M13589</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T19:20:27Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32088#M13590</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That didn't work either.. Maybe I have to call it from service task.. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 20:16:23 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32088#M13590</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T20:16:23Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32089#M13591</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I mean script task&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 20:21:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32089#M13591</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T20:21:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32090#M13592</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It would help if you can post all the details such as bpmn file, service java code etc in one post when asking questions. From this post, it is difficult to understand whether you are doing it from a service/script task or even execution/task/event listeners etc. Also, if this is getting executed without a user context (ie, async) you won't have any user info where your bpmn definition will help!&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 20:23:34 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32090#M13592</guid>
      <dc:creator>cjose</dc:creator>
      <dc:date>2017-10-11T20:23:34Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32091#M13593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;of course thanks Ciju. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think I found a bug in the system.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am now able to get userinfo through SecurityUtils.getCurrentUserObject(); Only if the form in previous activity (not activiti) does not have a file upload option with Alfresco repo enabled.&lt;/P&gt;&lt;P&gt;So i have a form on start event which has attach file option and after that i have service task which calls javadelegate and it prints the user info if I don't enable alfresco repo files to be attached.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 22:59:24 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32091#M13593</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T22:59:24Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32092#M13594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN&gt;Steps:&lt;BR /&gt;&lt;BR /&gt;1. Create a form with attach file and configure it accept local files and alfresco files.&lt;BR /&gt;2. Create a java api or bean .. add code to capture userinfo .. see attachment for example. &lt;BR /&gt;3. Create a process with start event -&amp;gt; service task -&amp;gt; end&lt;BR /&gt;4. attach form to start event and configure service task to call your java api&lt;BR /&gt;5. check the log and you will see that userinfo in null. &lt;BR /&gt;&lt;BR /&gt;Now remove the alfresco option and republish the app and run it again. UserInfo is now available&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Oct 2017 23:22:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32092#M13594</guid>
      <dc:creator>vsangal</dc:creator>
      <dc:date>2017-10-11T23:22:32Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get user info from userID</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32093#M13595</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah, now it makes sense. When you add an attach file option in the form, the next task will turn async. That means it is no longer executed under the logged in user context! Hence you get null. Try executing your logic from an execution listener attached to the start&amp;nbsp;activity&amp;nbsp;or on the sequence flow if you really need the user context.&amp;nbsp;It is not a bug, it is working as designed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Oct 2017 00:09:04 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/how-do-i-get-user-info-from-userid/m-p/32093#M13595</guid>
      <dc:creator>cjose</dc:creator>
      <dc:date>2017-10-12T00:09:04Z</dc:date>
    </item>
  </channel>
</rss>

