Questions asked by HaraldWeberhttps://answers.axonivy.com/questions/asked-by/119/haraldweber/?type=rssQuestions asked by <a href="/users/119/haraldweber" >HaraldWeber</a>enTue, 08 Aug 2017 09:59:55 -0400Ivy 3.9 User Details loading very slowhttps://answers.axonivy.com/questions/2801/ivy-3-9-user-details-loading-very-slow<p>On a customers installation the User Details in the workflow ui are loading very slow. About 50 seconds.</p> <p>URL: <a href="http://localhost:8081/ivy/wf/Webapp/index.html?pageId=admin%2Fuserform&amp;user=GFKLK">http://localhost:8081/ivy/wf/Webapp/index.html?pageId=admin%2Fuserform&amp;user=GFKLK</a></p> <p>The AAA System is set to Active Directory. After a click on user details i wait 50 seconds and then the following line appears in the server log.</p> <table border="1'"> <tbody><tr height="21"> <td height="21"> <span>LogId</span></td> <td><span>119510222</span></td> </tr> <tr height="21"> <td height="21"><span>SessionId</span></td> <td><span>199</span></td> </tr> <tr height="21"> <td height="21"><span>LogLevel</span></td> <td><span>5</span></td> </tr> <tr height="21"> <td height="21"><span>LogTimestamp</span></td> <td><span>2017-08-04 10:07:30.080</span></td> </tr> <tr height="21"> <td height="21"><span>SequenceNumber</span></td> <td><span>87</span></td> </tr> <tr height="21"> <td height="21"><span>LogMessage</span></td> <td><span lang="EN-US">Open directory context to naming and directory server 'ldap://SOME_SERVER_ADDRESS'</span></td> </tr> <tr height="21"> <td height="21"><span>LogDetailMessage</span></td> <td><span lang="EN-US">-&gt; client: 0:0:0:0:0:0:0:1 SOME_SERVER_ADDRESS -&gt; thread: http-8081-Processor5  Class: JndiAuthenticationAndAuthorization Method: getJndiContext</span></td> </tr> <tr height="0"> <td width="121"></td> <td width="1026"></td> </tr> </tbody></table> <p><br> It seems that the server tries to get some information from the ldap server and runs in a timeout. After that the user details page is shown. Confusing is the part "client: 0:0:0:0:0:0:0:1". Its an ipv6 address. Does the server try to fetch something via ipv6? </p> <p>I disabled ipv6 in Windows but that didn't changed anything.</p> <p>Have you seen a similar case? What can I do to investigate?</p> <p>Server Info: Detail Version 3.9.52.5 (Version 3.9 Build 52 Patch 5) Build Date 21.11.2011 </p>HaraldWeberTue, 08 Aug 2017 09:59:55 -0400https://answers.axonivy.com/questions/2801/ivy-3-9-user-details-loading-very-slowworkflowuiadministrationivy3Threads and the Ivy Objecthttps://answers.axonivy.com/questions/1189/threads-and-the-ivy-object<p>I want to execute some tasks in the background. I used java threads but I get this exception.</p> <pre><code>ch.ivyteam.ivy.environment.EnvironmentNotAvailableException: Access to ivy environment outside a process request thread is not possible. </code></pre> <p>Is there an ivy thread i can use or is it simply not possible?</p>HaraldWeberMon, 02 Mar 2015 17:55:36 -0500https://answers.axonivy.com/questions/1189/threads-and-the-ivy-objectconcurrencythreadEnd a suspended Taskhttps://answers.axonivy.com/questions/1114/end-a-suspended-task<p>How can I end a suspended task? In IWorkflowSession there is a mehtod: </p> <pre><code>public abstract void endWorkingTask(ITask paramITask, String paramString1, String paramString2, String paramString3, boolean paramBoolean) throws PersistencyException; </code></pre> <p>But its undocumented.</p> <p>Or is it better to call ITask.destroy()?</p>HaraldWeberMon, 12 Jan 2015 14:45:47 -0500https://answers.axonivy.com/questions/1114/end-a-suspended-tasktaskPermission Denied: needs Permission SYSTEM but the Session is SYSTEMhttps://answers.axonivy.com/questions/1020/permission-denied-needs-permission-system-but-the-session-is-system<p>I have a strange Exception here: </p> <pre>Session 0 (SYSTEM) is not allowed to call method public ch.ivyteam.ivy.workflow.IProcessData ch.ivyteam.ivy.workflow.internal.Task.getInternalProcessData(). The session does not fulfill the permission rule SESSION IS SYSTEM</pre> <p>This says the Session has the permission SYSTEM but the call was denied because the Session has not the permission SYSTEM.</p> <p>Code is: </p><pre>final ITask task = Ivy.wfTask(); IProcessData ipd = Ivy.session().getSecurityContext() .executeAsSystemUser(new Callable&lt;iprocessdata&gt;() {<p></p> <pre><code> @Override public IProcessData call() throws Exception { return task.getInternalProcessData(); } }); </code></pre> </pre>HaraldWeberThu, 23 Oct 2014 10:52:10 -0400https://answers.axonivy.com/questions/1020/permission-denied-needs-permission-system-but-the-session-is-systemsecuritySave Task data while in taskhttps://answers.axonivy.com/questions/1017/save-task-data-while-in-task<p>How can I save data while I'm in a Task Switch.</p> <p>I'm resuming a Task and want to save data after submitting each form/page. If the user session expires or the user cancels the task the data should load when the user resumes the task the next time.</p>HaraldWeberTue, 21 Oct 2014 10:34:51 -0400https://answers.axonivy.com/questions/1017/save-task-data-while-in-tasktaskHow to get the users tasklisthttps://answers.axonivy.com/questions/969/how-to-get-the-users-tasklist<p>How can i get the task list of the current logged in user without the permission TaskReadAll.</p> <p>All methods i tried call <b>getTaskQueryExecutor</b> which needs the permission TaskReadAll.</p> <p>I think the User should be allowed to read it's own tasks.</p>HaraldWeberThu, 18 Sep 2014 14:12:03 -0400https://answers.axonivy.com/questions/969/how-to-get-the-users-tasklisttasklistWhy can I only have one field of the type List in my entity class?https://answers.axonivy.com/questions/912/why-can-i-only-have-one-field-of-the-type-list-in-my-entity-class<p>When I create a new entity class and want to have more than one List in it, Xpert.ivy says: "If an entity class has more than one collection you have to use 'Set' instead of 'List' as type."</p> <p>I think the JEE Persistence API does not have this limitation.</p>HaraldWeberThu, 14 Aug 2014 11:32:10 -0400https://answers.axonivy.com/questions/912/why-can-i-only-have-one-field-of-the-type-list-in-my-entity-classpersistenceUse different primefaces themes for projectshttps://answers.axonivy.com/questions/897/use-different-primefaces-themes-for-projects<p>In the help topics its written that primefaces themes has to be installed in the servers/designers webapps directory. With this setting themes are configured globally for all projects. What if i want to apply different themes for different projects? Do i have to start ivy server instances for each theme?</p> <p>The primefaces documentation says: "...this approach requires you to create a jar file and add it to the classpath of <strong>your application</strong>"</p> <p>So the designated way to apply themes, is at the project level not the server level.</p> <p>How can I apply a theme only for one project?</p>HaraldWeberWed, 06 Aug 2014 12:14:12 -0400https://answers.axonivy.com/questions/897/use-different-primefaces-themes-for-projectsdesignerserverPersistence Api - Many to Many Relationshiphttps://answers.axonivy.com/questions/616/persistence-api-many-to-many-relationship<p>Is it possible to declare a many to many relationship in the Entity Class Editor?</p>HaraldWeberWed, 02 Apr 2014 14:12:20 -0400https://answers.axonivy.com/questions/616/persistence-api-many-to-many-relationshippersistencePersistence Api - Foreign Key is always nullhttps://answers.axonivy.com/questions/588/persistence-api-foreign-key-is-always-null<p>Hi</p> <p>currently i'm trying to use the persistence api. I stuck at inserting a one to many relationship. The problem is that the foreign key is always null.</p> <p>I have two entity classes. User and Option.</p> <h3>User</h3> <table border="1"> <tbody><tr> <th>Name</th> <th>Type</th> <th>DB Field</th> <th>Persistent</th> <th>Length</th> <th>Properties</th> <th>Association</th> <th>Cascade</th> <th>Mapped by</th> </tr> <tr> <td>id</td> <td>Integer</td> <td>id</td> <td>yes</td> <td></td> <td>id, generated</td> <td></td> <td></td> <td></td> </tr> <tr> <td>name</td> <td>String</td> <td>name</td> <td>yes</td> <td>255</td> <td></td> <td></td> <td></td> <td></td> </tr> <tr> <td>opts</td> <td>Listy&lt;Option&gt;</td> <td></td> <td>yes</td> <td></td> <td></td> <td>ONE_TO_MANY</td> <td>persist, merge</td> <td>user_fk</td> </tr> </tbody></table> <h3>Option</h3> <table border="1"> <tbody><tr> <th>Name</th> <th>Type</th> <th>DB Field</th> <th>Persistent</th> <th>Length</th> <th>Properties</th> <th>Association</th> <th>Cascade</th> <th>Mapped by</th> </tr> <tr> <td>id</td> <td>Integer</td> <td>id</td> <td>yes</td> <td></td> <td>id, generated</td> <td></td> <td></td> <td></td> </tr> <tr> <td>option</td> <td>String</td> <td>opt_value</td> <td>yes</td> <td>255</td> <td></td> <td></td> <td></td> <td></td> </tr> <tr> <td>user_fk</td> <td>User</td> <td>user_fk</td> <td>yes</td> <td></td> <td>not nullable</td> <td>MANY_TO_ONE</td> <td>persist, merge</td> <td></td> </tr> </tbody></table> <p>The Option Objects are created from strings by a converter from a p:selectManyCheckbox. The field user_fk is not set manually in this converter because i don't have a reference to the User object in the converter.</p> <p>Xpert.ivy creates an entity class for User and adds a "setOpts(List)" method for me.</p> <p><code> public void setOpts(java.util.List&lt; persistenceTest.Option &gt; _opts) { opts = _opts; } </code></p> <p>If there where a "addOpt(Option) method I could add the reference to User myself.</p> <p><code> public void addOpt(persistenceTest.Option __opts) { <strong> _opts.setUser_fk(this);</strong> optsList.add(_opts); } </code></p> <p>Am I thinking wrong or is it not possible to automate the creation of foreign keys?</p> <p>Best Regards Harald</p>HaraldWeberWed, 26 Mar 2014 10:25:39 -0400https://answers.axonivy.com/questions/588/persistence-api-foreign-key-is-always-nullpersistence