Project

General

Profile

Actions

bug #8774

closed

Reimplement term tree editors to implement the general save strategy

Added by Andreas Müller over 4 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Highest
Assignee:
Category:
taxeditor
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Severity:
blocker
Found in Version:
Tags:

Description

Currently term trees save changes in the hierarchy (including new terms/nodes) immediately in the DB. This is against our general save strategy which saves changes only after explicitly pressing the save button.
It also creates huge problems because chnages in the nodes and terms itself are still saved via save button by saving (merging) the full term tree. This seems to lead to inconsistent data under certain circumstances.

Therefore we urgently need to reimplement the save strategy in term tree editors (including the Character Editor which more or less is also a term tree editor).
This is urgent as blocks using the Character-Editor which is a prerequisite for all additivity functionality.

During this reimplementation we also should use TermDtos instead of the whole objects.


Files

picture145-1.png (7.82 KB) picture145-1.png Andreas Müller, 11/09/2020 02:28 PM
picture539-1.png (2.08 KB) picture539-1.png Andreas Müller, 11/27/2020 09:12 AM
picture709-1.png (1.09 KB) picture709-1.png Andreas Müller, 12/01/2020 11:59 AM
picture911-1.png (2.2 KB) picture911-1.png Andreas Müller, 12/02/2020 12:20 PM

Related issues

Related to EDIT - bug #8663: LIE when trying to save a tree nodeDuplicateAndreas Müller

Actions
Related to EDIT - bug #8776: Open issues for TermCollection.allowDuplicates handling in TaxEditorClosedKatja Luther

Actions
Related to EDIT - feature request #8474: Make TermCollection.orderRelevant usable for TermTreesClosedKatja Luther

Actions
Related to EDIT - feature request #8476: Implement support for TermCollection.isFlat in TaxEditorClosedKatja Luther

Actions
Related to EDIT - feature request #9287: Show term details in details view of term tree editorClosedKatja Luther

Actions
Related to EDIT - feature request #9288: Add symbols for flags in use for term trees in term tree editorClosedKatja Luther

Actions
Related to EDIT - feature request #9307: Preferences for display of termtrees and entriesClosedKatja Luther

Actions
Related to EDIT - bug #9334: Show error message when feature tree can not be shown because of dirty dataNewKatja Luther

Actions
Has duplicate EDIT - bug #7990: Moving a feature via d&d does not make the Feature Tree Editor dirtyClosedKatja Luther

Actions
Has duplicate EDIT - bug #8751: Replace saveOrUpdate() in AbstractTermTreeEditorDuplicateAndreas Müller

Actions
Blocks EDIT - feature request #8756: Refresh button for structure tree and property tree in Character EditorFeedbackKatja Luther

Actions
Copied from EDIT - bug #8744: LazyInitializationException (LIE) saving the Character EditorClosedPatrick Plitzner

Actions
Copied to EDIT - feature request #9338: Restructure term menusClosedKatja Luther

Actions
Copied to EDIT - feature request #9337: Open issues for reimplementation of termtree editorsClosedKatja Luther

Actions
Actions #1

Updated by Andreas Müller over 4 years ago

  • Copied from bug #8744: LazyInitializationException (LIE) saving the Character Editor added
Actions #2

Updated by Andreas Müller over 4 years ago

  • Related to bug #8663: LIE when trying to save a tree node added
Actions #3

Updated by Andreas Müller over 4 years ago

  • Related to bug #8751: Replace saveOrUpdate() in AbstractTermTreeEditor added
Actions #4

Updated by Andreas Müller over 4 years ago

  • Related to bug #8776: Open issues for TermCollection.allowDuplicates handling in TaxEditor added
Actions #5

Updated by Andreas Müller over 4 years ago

Actions #6

Updated by Andreas Müller over 4 years ago

Actions #7

Updated by Katja Luther over 4 years ago

  • Description updated (diff)
  • Status changed from New to In Progress
Actions #8

Updated by Katja Luther over 4 years ago

  • Target version changed from Release 5.12 to Release 5.13
Actions #9

Updated by Katja Luther about 4 years ago

  • Target version changed from Release 5.13 to Release 5.14
Actions #10

Updated by Andreas Müller about 4 years ago

  • Blocks feature request #8756: Refresh button for structure tree and property tree in Character Editor added
Actions #11

Updated by Katja Luther about 4 years ago

  • Target version changed from Release 5.14 to Release 5.15
Actions #12

Updated by Katja Luther almost 4 years ago

  • Target version changed from Release 5.15 to Release 5.18
Actions #13

Updated by Katja Luther over 3 years ago

  • Status changed from In Progress to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

all termtree editors are now switched to dtos. please review.

Actions #14

Updated by Katja Luther over 3 years ago

  • % Done changed from 0 to 60
Actions #15

Updated by Andreas Müller over 3 years ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Andreas Müller to Katja Luther

Drag&drop still seems to work like in the old version with no dirty flag but immediate save of change.

Actions #16

Updated by Andreas Müller over 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

Andreas Müller wrote:

Drag&drop still seems to work like in the old version with no dirty flag but immediate save of Change.

Sorry this was not a tree

Actions #17

Updated by Andreas Müller over 3 years ago

Trying to open the feature tree editor opened it in the buttom panel and no tree appeared and no conext menu existed for rem_conf_am.

Opening the named area tree editor worked as expected.

Actions #18

Updated by Andreas Müller over 3 years ago

It is now possible to open 2 term tree Editors of the same type. This is not wanted as a term tree editor always edits all trees and therefore should be singleton, same as term editors.

Actions #19

Updated by Andreas Müller over 3 years ago

Can we still Change the menu that way that we have Vocabularies instead of "Feature", "Named Area", "Others" and then list ALL vocabularies in the same sublist. As the Terms menu is now more populated this seems to be the more approriate way.
Feel free to open a new ticket if task is not straight forward.

Actions #20

Updated by Andreas Müller over 3 years ago

Can we show the details of a term anyway even if it is not editable in the term tree editor. This is because the pure label is often not enough to decide if one took the right term.
If not all information is easily available at least the most important should be shown.

But ofcourse it should be disabled for editing. (but Maybe in future when vocabularies will also use term trees for hierarchy editing might be a requested feature, just in case this is important to know for implementation).

Feel free to create a new ticket if this takes time to implement.

Actions #21

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Can we show the details of a term anyway even if it is not editable in the term tree editor. This is because the pure label is often not enough to decide if one took the right term.
If not all information is easily available at least the most important should be shown.

But ofcourse it should be disabled for editing. (but Maybe in future when vocabularies will also use term trees for hierarchy editing might be a requested feature, just in case this is important to know for implementation).

Feel free to create a new ticket if this takes time to implement.

This needs a more detailed dto and therefore I move this to a new ticket.(#9287)

Actions #22

Updated by Katja Luther over 3 years ago

Actions #23

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Trying to open the feature tree editor opened it in the buttom panel and no tree appeared and no conext menu existed for rem_conf_am.

Opening the named area tree editor worked as expected.

This seems to be related to the database, in other instances the problem does not appear. Needs further testing.

Actions #24

Updated by Andreas Müller over 3 years ago

Changing the name of a vocabulary is not possible. The changes neither show up in the term tree editor nor do they seem to be saved correctly. Dirty flag seems to work.

fixed

Actions #25

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

Changing the name of a vocabulary is not possible. The changes neither show up in the term tree editor nor do they seem to be saved correctly. Dirty flag seems to work.

Also vocabulary flags do not seem to be saved when changed.

fixed

Actions #26

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

Changing the name of a vocabulary is not possible. The changes neither show up in the term tree editor nor do they seem to be saved correctly. Dirty flag seems to work.

I mean term tree not vocabulary ofcourse.

Actions #27

Updated by Andreas Müller over 3 years ago

  • Related to feature request #9288: Add symbols for flags in use for term trees in term tree editor added
Actions #28

Updated by Andreas Müller over 3 years ago

adding a child (which was a duplicate but the tree did not allow duplicates, don't know if this is relevant):

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/termnode.service
last remote request client time : 2020-11-09T15:21:14.826
last remote request response header time : Mon, 09 Nov 2020 15:21:14 GMT
client error time : 2020-11-09T15:21:14.857
login : admin
editor version : 5.18.0.202011082350
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.4.0.20201020
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.NullPointerException)
    at org.eclipse.swt.SWT.error(SWT.java:4533)
    at org.eclipse.swt.SWT.error(SWT.java:4448)
    at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:185)
    at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4211)
    at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3827)
    at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1121)
    at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
    at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1022)
    at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:150)
    at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:693)
    at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
    at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:610)
    at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
    at eu.etaxonomy.taxeditor.Application.start(Application.java:20)
    at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
    at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
    at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
    at org.eclipse.equinox.launcher.Main.run(Main.java:1519)
Caused by: java.lang.NullPointerException
    at eu.etaxonomy.cdm.api.service.TermNodeServiceImpl.addChildNode(TermNodeServiceImpl.java:159)
    at sun.reflect.GeneratedMethodAccessor1905.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:333)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
    at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
    at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:283)
    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:213)
    at com.sun.proxy.$Proxy791.addChildNode(Unknown Source)
    at sun.reflect.GeneratedMethodAccessor1905.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:333)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
    at org.springframework.remoting.support.RemoteInvocationTraceInterceptor.invoke(RemoteInvocationTraceInterceptor.java:78)
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
    at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
    at com.sun.proxy.$Proxy1171.addChildNode(Unknown Source)
    at sun.reflect.GeneratedMethodAccessor1965.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.springframework.remoting.support.RemoteInvocation.invoke(RemoteInvocation.java:212)
    at eu.etaxonomy.cdm.api.remoting.DebuggingRemoteInvocationExecutor.invoke(DebuggingRemoteInvocationExecutor.java:52)
    at org.springframework.remoting.support.RemoteInvocationBasedExporter.invoke(RemoteInvocationBasedExporter.java:78)
    at org.springframework.remoting.support.RemoteInvocationBasedExporter.invokeAndCreateResult(RemoteInvocationBasedExporter.java:114)
    at org.springframework.remoting.httpinvoker.HttpInvokerServiceExporter.handleRequest(HttpInvokerServiceExporter.java:80)
    at org.springframework.web.servlet.mvc.HttpRequestHandlerAdapter.handle(HttpRequestHandlerAdapter.java:51)
    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:967)
    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:901)
    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970)
    at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:872)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
    at org.eclipse.jetty.servlet.ServletHolder$NotAsyncServlet.service(ServletHolder.java:1395)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:755)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1617)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
    at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
    at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:114)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:215)
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:66)
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
    at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:214)
    at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:177)
    at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:347)
    at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:263)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
    at eu.etaxonomy.cdm.servlet.DateHeaderFilter.doFilter(DateHeaderFilter.java:55)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1604)
    at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197)
Actions #29

Updated by Andreas Müller over 3 years ago

The duplicate check should be done when adding the term not only when saving it.

this is fixed.

Actions #30

Updated by Andreas Müller over 3 years ago

When adding/removing terms the tree should stay expanded. Currently it collapses and you have to reopen it. Best would be to focus on the added term (or on the next term, if exists, if removing terms).

Actions #31

Updated by Andreas Müller over 3 years ago

Unordered trees should preferably be ordered alphabetically by label or idInVoc or whatever the first part of the used label is.
However, this has not a hight priority and can be moved to another ticket if not straight forward.

Actions #32

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Trying to open the feature tree editor opened it in the buttom panel and no tree appeared and no conext menu existed for rem_conf_am.

Opening the named area tree editor worked as expected.

This is caused by dirty data, I cleaned up the database, now the feature trees and the character trees show up again.

Actions #33

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

adding a child (which was a duplicate but the tree did not allow duplicates, don't know if this is relevant):

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/termnode.service
last remote request client time : 2020-11-09T15:21:14.826
last remote request response header time : Mon, 09 Nov 2020 15:21:14 GMT
client error time : 2020-11-09T15:21:14.857
login : admin
editor version : 5.18.0.202011082350
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.4.0.20201020
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.NullPointerException)
at org.eclipse.swt.SWT.error(SWT.java:4533)
at org.eclipse.swt.SWT.error(SWT.java:4448)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:185)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4211)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3827)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1121)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1022)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:150)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:693)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:610)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
at eu.etaxonomy.taxeditor.Application.start(Application.java:20)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:673)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:610)
at org.eclipse.equinox.launcher.Main.run(Main.java:1519)
Caused by: java.lang.NullPointerException
at eu.etaxonomy.cdm.api.service.TermNodeServiceImpl.addChildNode(TermNodeServiceImpl.java:159)

after the data cleaning I could not reproduce this exception anymore, maybe it was also related to dirty data. But the user should not be able to create duplicates, this still is an open issue.

Actions #34

Updated by Andreas Müller over 3 years ago

Katja Luther wrote:

...
This is caused by dirty data, I cleaned up the database, now the feature trees and the character trees show up again.

Can you explain how far the data was dirty?
Shouldn't the UI give feedback on dirty data somehow? Why did the dirty data result in such strange result?

Actions #35

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Katja Luther wrote:

...
This is caused by dirty data, I cleaned up the database, now the feature trees and the character trees show up again.

Can you explain how far the data was dirty?
Shouldn't the UI give feedback on dirty data somehow? Why did the dirty data result in such strange result?

You are right the UI should show up a message.

The dirty data was caused by missing terms and feature trees containing character nodes or vice versa, this was allowed in first implementation of term tree editor but this was adapted and now a term tree only contains nodes of one term type.

Actions #36

Updated by Andreas Müller over 3 years ago

Actions #37

Updated by Katja Luther over 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

For the missing feedback I create a new ticket, can we close this ticket?

Actions #38

Updated by Katja Luther over 3 years ago

  • Related to bug #9334: Show error message when feature tree can not be shown because of dirty data added
Actions #39

Updated by Andreas Müller over 3 years ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Andreas Müller to Katja Luther

When moving a term up in feature tree via d&d

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/common.service
last remote request client time : 2020-11-27T08:36:35.887
last remote request response header time : Fri, 27 Nov 2020 08:36:35 GMT
client error time : 2020-11-27T08:36:35.934
login : admin
editor version : 5.18.0.202011262351
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.5.0.20201103
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
java.lang.NullPointerException
    at eu.etaxonomy.cdm.persistence.dto.TermNodeDto.getIndex(TermNodeDto.java:207)
    at eu.etaxonomy.taxeditor.featuretree.e4.FeatureTreeDtoDropAdapter.performDrop(FeatureTreeDtoDropAdapter.java:80)
    at org.eclipse.jface.viewers.ViewerDropAdapter.drop(ViewerDropAdapter.java:254)
    at org.eclipse.swt.dnd.DNDListener.handleEvent(DNDListener.java:91)
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
    at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4418)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1103)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1088)
    at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:802)
    at org.eclipse.swt.dnd.DropTarget.Drop(DropTarget.java:472)
    at org.eclipse.swt.dnd.DropTarget.Drop_64(DropTarget.java:406)
    at org.eclipse.swt.dnd.DropTarget$3.method6(DropTarget.java:270)
    at org.eclipse.swt.internal.ole.win32.COMObject.callback6(COMObject.java:119)
    at org.eclipse.swt.internal.ole.win32.COM.DoDragDrop(Native Method)
    at org.eclipse.swt.dnd.DragSource.drag(DragSource.java:378)
    at org.eclipse.swt.dnd.DragSource.access$0(DragSource.java:304)
    at org.eclipse.swt.dnd.DragSource$1.handleEvent(DragSource.java:173)
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
    at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4418)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
    at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4236)
    at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3824)
    at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1121)
    at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
    at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1022)
Actions #40

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

It is now possible to open 2 term tree Editors of the same type. This is not wanted as a term tree editor always edits all trees and therefore should be singleton, same as term editors.

This seems not to be fixed yet.

Actions #41

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

Trying to open the feature tree editor opened it in the buttom panel and no tree appeared and no conext menu existed for rem_conf_am.
Opening the named area tree editor worked as expected.

It generally works now, but for a very short time it still seems to open it on buttom and then moves it up. This looks not nice (though not critical).

Actions #42

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

Can we still Change the menu that way that we have Vocabularies instead of "Feature", "Named Area", "Others" and then list ALL vocabularies in the same sublist. As the Terms menu is now more populated this seems to be the more approriate way.
Feel free to open a new ticket if task is not straight forward.

This seem also still open

Actions #43

Updated by Andreas Müller over 3 years ago

There is still camle case in the label

Actions #44

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

The duplicate check should be done when adding the term not only when saving it.

this is fixed.

It works now, only when adding multiple terms you get the message and you don't know which term was a duplicate. So the message could say something like "... allow duplicates but the following term(s) are already in the tree. They will not be added.". Also we may want to add a cancel button here if at least 1 term is not a duplicate.
In general we may distinguish the case that all selected terms are duplicates or only a few and adapt the message and the buttoms accordingly.

Actions #45

Updated by Andreas Müller over 3 years ago

Similar to the duplicates issue a term tree can be "flat". In this case adding a child to a term node should not be allowed. The menu should be disabled for term nodes. Children can only be added to the tree itself then.
If this is complicated to implement move to new ticket (but with milestone soon)

Actions #46

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Similar to the duplicates issue a term tree can be "flat". In this case adding a child to a term node should not be allowed. The menu should be disabled for term nodes. Children can only be added to the tree itself then.
If this is complicated to implement move to new ticket (but with milestone soon)

there is a ticket already (#8476). I will have a look.

Actions #47

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Andreas Müller wrote:

Can we still Change the menu that way that we have Vocabularies instead of "Feature", "Named Area", "Others" and then list ALL vocabularies in the same sublist. As the Terms menu is now more populated this seems to be the more approriate way.
Feel free to open a new ticket if task is not straight forward.

This seem also still open

this is fixed.

Actions #48

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Andreas Müller wrote:

It is now possible to open 2 term tree Editors of the same type. This is not wanted as a term tree editor always edits all trees and therefore should be singleton, same as term editors.

This seems not to be fixed yet.

this is fixed.

Actions #49

Updated by Andreas Müller over 3 years ago

Andreas Müller wrote:

Andreas Müller wrote:

The duplicate check should be done when adding the term not only when saving it.

this is fixed.

It works now, only when adding multiple terms you get the message and you don't know which term was a duplicate. So the message could say something like "... allow duplicates but the following term(s) are already in the tree. They will not be added.". Also we may want to add a cancel button here if at least 1 term is not a duplicate.
In general we may distinguish the case that all selected terms are duplicates or only a few and adapt the message and the buttoms accordingly.

There is a related ticket on this issue: #8776 , can you please check how far these issues are fixed. Those not fixed yet we should try to handle soon. (not necessarily this release)

Actions #50

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Andreas Müller wrote:

Andreas Müller wrote:

The duplicate check should be done when adding the term not only when saving it.

this is fixed.

It works now, only when adding multiple terms you get the message and you don't know which term was a duplicate. So the message could say something like "... allow duplicates but the following term(s) are already in the tree. They will not be added.". Also we may want to add a cancel button here if at least 1 term is not a duplicate.
In general we may distinguish the case that all selected terms are duplicates or only a few and adapt the message and the buttoms accordingly.

There is a related ticket on this issue: #8776 , can you please check how far these issues are fixed. Those not fixed yet we should try to handle soon. (not necessarily this release)

Now the message contains the terms not added because of duplication.

Actions #51

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

There is still camle case in the label

this is fixed

Actions #52

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

When adding/removing terms the tree should stay expanded. Currently it collapses and you have to reopen it. Best would be to focus on the added term (or on the next term, if exists, if removing terms).

this is fixed

Actions #53

Updated by Katja Luther over 3 years ago

Actions #54

Updated by Katja Luther over 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

I think all issues are fixed. Only the wrong position for a short time (#9337) and handling of flat trees still open (#8476).

Actions #55

Updated by Andreas Müller over 3 years ago

Actions #56

Updated by Andreas Müller over 3 years ago

I moved the open menu items to #9338

Actions #57

Updated by Andreas Müller over 3 years ago

But this should be done immediately:

Rename menu entry "Term Tree Editor" to "Term Trees" as it is inconsistent with "vocabularies" otherwise.

-> done

Actions #58

Updated by Andreas Müller over 3 years ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Andreas Müller to Katja Luther

Can we remove "Inapplicable IF" and "Only applicable if" for all term trees except for those having term type "Feature" or "Character" or better "Feature" and all its subtypes. As the message "No feature state added yet" says this is only for data related to "Feature".

Actions #59

Updated by Katja Luther over 3 years ago

Andreas Müller wrote:

Can we remove "Inapplicable IF" and "Only applicable if" for all term trees except for those having term type "Feature" or "Character" or better "Feature" and all its subtypes. As the message "No feature state added yet" says this is only for data related to "Feature".

for other termnodes the details view is blank already.

Actions #60

Updated by Andreas Müller over 3 years ago

Katja Luther wrote:

Andreas Müller wrote:

Can we remove "Inapplicable IF" and "Only applicable if" for all term trees except for those having term type "Feature" or "Character" or better "Feature" and all its subtypes. As the message "No feature state added yet" says this is only for data related to "Feature".

for other termnodes the details view is blank already.

Ahh, ofcourse you are right. I made a mistake when testing.

Actions #61

Updated by Katja Luther over 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

I think all remaining issues are solved or moved to new tickets.

Actions #62

Updated by Andreas Müller over 3 years ago

  • Status changed from Resolved to Feedback
  • Assignee changed from Andreas Müller to Katja Luther

AOOB with a rank tree with 3 top level children, first I moved 3rd rank to be child of 2nd rank, than I tried to move it to bcome child of 1st rank or inbetween 1st and 2nd rank => exception:

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/termnode.service
last remote request client time : 2020-12-02T12:13:58.344
last remote request response header time : Wed, 02 Dec 2020 12:13:58 GMT
client error time : 2020-12-02T12:13:58.39
login : admin
editor version : 5.18.0.202012011427
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.5.0.20201103
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
java.lang.ArrayIndexOutOfBoundsException: -1
    at java.util.ArrayList.elementData(ArrayList.java:418)
    at java.util.ArrayList.remove(ArrayList.java:495)
    at eu.etaxonomy.taxeditor.featuretree.e4.FeatureTreeDtoDropAdapter.performDrop(FeatureTreeDtoDropAdapter.java:149)
    at org.eclipse.jface.viewers.ViewerDropAdapter.drop(ViewerDropAdapter.java:254)
    at org.eclipse.swt.dnd.DNDListener.handleEvent(DNDListener.java:91)
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
    at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4418)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1103)
Actions #63

Updated by Andreas Müller over 3 years ago

... this happens whereever I try to move the 3rd rank from position of being child of 2nd rank (but in the same session, no saving before)

Actions #64

Updated by Andreas Müller over 3 years ago

When changing a tree by e.g. changing a flag (order relevant) and then adding a term a message comes that the tree needs to be saved before. After adding the term the term does not appear in the UI, only after saving again it appears.

AND: the changed flag does is reverted again if I click on the tree

Actions #65

Updated by Andreas Müller over 3 years ago

The text for duplicate recognition should be improved from

This term tree does not allow duplicates and there exist nodes with following terms => This term tree does not allow duplicates and therefore the following terms were not added

... and the according German translation

Actions #66

Updated by Andreas Müller over 3 years ago

after moving some ranks around in the term editor I got the following when trying to save:

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/termnode.service
last remote request client time : 2020-12-02T19:34:43.622
last remote request response header time : Wed, 02 Dec 2020 19:34:43 GMT
client error time : 2020-12-02T19:34:59.366
login : admin
editor version : 5.18.0.202012021746
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.6.0.20201124
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.StackOverflowError)
    at org.eclipse.swt.SWT.error(SWT.java:4533)
    at org.eclipse.swt.SWT.error(SWT.java:4448)
    at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:185)
...
Caused by: java.lang.StackOverflowError
    at java.lang.Class.getDeclaringClass(Class.java:1235)
    at java.lang.Class.getEnclosingClass(Class.java:1277)
    at java.lang.Class.getSimpleBinaryName(Class.java:1443)
    at java.lang.Class.getSimpleName(Class.java:1309)
    at eu.etaxonomy.cdm.aspectj.PropertyChangeAspect.isPersistentSet(PropertyChangeAspect.aj:75)
    at eu.etaxonomy.cdm.aspectj.PropertyChangeAspect.ajc$inlineAccessMethod$eu_etaxonomy_cdm_aspectj_PropertyChangeAspect$eu_etaxonomy_cdm_aspectj_PropertyChangeAspect$isPersistentSet(PropertyChangeAspect.aj:1)
    at eu.etaxonomy.cdm.model.term.TermNode.setTreeIndex_aroundBody5$advice(TermNode.java:61)
    at eu.etaxonomy.cdm.model.term.TermNode.setTreeIndex(TermNode.java:1)
...
    at eu.etaxonomy.cdm.persistence.hibernate.SaveOrUpdateEntityListener.reindex(SaveOrUpdateEntityListener.java:67)
    at eu.etaxonomy.cdm.persistence.hibernate.SaveOrUpdateEntityListener.reindex(SaveOrUpdateEntityListener.java:67)
    at eu.etaxonomy.cdm.persistence.hibernate.SaveOrUpdateEntityListener.reindex(SaveOrUpdateEntityListener.java:67)
    at eu.etaxonomy.cdm.persistence.hibernate.SaveOrUpdateEntityListener.reindex(SaveOrUpdateEntityListener.java:67)
    at org.springframework.remoting.support.RemoteInvocationUtils.fillInClientStackTraceIfPossible(RemoteInvocationUtils.java:45)
    at org.springframework.remoting.support.RemoteInvocationResult.recreate(RemoteInvocationResult.java:149)

Actions #67

Updated by Andreas Müller over 3 years ago

D&d a term onto its own child makes both disappear in the UI. Saving this is one way to create the above StackOverflowError.

Actions #68

Updated by Andreas Müller over 3 years ago

D&D a NamedArea term from a NamedArea Tree Term Editor to an Rank Tree Term Editor leeds to the below NPE:

D&D with 2 different term types should generally not be allowed

last remote method : http://test.e-taxonomy.eu:80/cdmserver/rem_conf_am/remoting/common.service
last remote request client time : 2020-12-02T19:48:34.249
last remote request response header time : Wed, 02 Dec 2020 19:48:34 GMT
client error time : 2020-12-02T19:48:34.296
login : admin
editor version : 5.18.0.202012021746
server : test.e-taxonomy.eu (edit-test) / rem_conf_am
schema version : 5.18.6.0.20201124
os : Windows Server 2012 R2 6.3 amd64
java : 1.8.0_121
java.lang.NullPointerException
    at eu.etaxonomy.taxeditor.featuretree.e4.FeatureTreeDtoDropAdapter.performDrop(FeatureTreeDtoDropAdapter.java:141)
    at org.eclipse.jface.viewers.ViewerDropAdapter.drop(ViewerDropAdapter.java:254)
    at org.eclipse.swt.dnd.DNDListener.handleEvent(DNDListener.java:91)
    at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
    at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4418)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
    at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:

By the way shouldn't we rename FeatureTreeDtoDropAdapter to TermTreeDtoDropAdapter?

Actions #69

Updated by Andreas Müller over 3 years ago

The above also happens when D&D a NamedAreae from NamedArea Term Editor to NamedArea Term Tree Editor, so it is probably not term type dependend.

Actions #70

Updated by Andreas Müller over 3 years ago

The tree should stay expanded when saving

Actions #71

Updated by Andreas Müller over 3 years ago

D&D on itself makes a node disappear and saving it creates a stackOverflow

Actions #72

Updated by Katja Luther over 3 years ago

The saving of the termtree editor before adding a new term is not necessary anymore, only moving a new term is not possible yet.

Actions #73

Updated by Katja Luther over 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Katja Luther to Andreas Müller

I move the expand of the tree after saving to the follow up ticket.

Actions #74

Updated by Andreas Müller over 3 years ago

  • Status changed from Resolved to Closed
  • Assignee changed from Andreas Müller to Katja Luther
  • % Done changed from 60 to 100

I think we can close this ticket. All remaining issues will go into the follow up ticket #9337

Actions #75

Updated by Andreas Müller over 3 years ago

Actions #76

Updated by Andreas Müller over 3 years ago

Actions #77

Updated by Andreas Müller over 3 years ago

  • Has duplicate bug #7990: Moving a feature via d&d does not make the Feature Tree Editor dirty added
Actions #78

Updated by Andreas Müller about 3 years ago

  • Related to deleted (bug #8751: Replace saveOrUpdate() in AbstractTermTreeEditor)
Actions #79

Updated by Andreas Müller about 3 years ago

  • Has duplicate bug #8751: Replace saveOrUpdate() in AbstractTermTreeEditor added
Actions

Also available in: Atom PDF