You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by GitBox <gi...@apache.org> on 2021/12/27 15:27:36 UTC

[GitHub] [wicket] asvanberg opened a new pull request #489: Remove Apache collections4 as a runtime dependency

asvanberg opened a new pull request #489:
URL: https://github.com/apache/wicket/pull/489


   For such a huge dependency it was barely used and in many instances was completely unnecessary. The biggest change would be how `MarkupContainer` children are stored.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@wicket.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [wicket] papegaaij commented on pull request #489: Remove Apache collections4 as a runtime dependency

Posted by GitBox <gi...@apache.org>.
papegaaij commented on pull request #489:
URL: https://github.com/apache/wicket/pull/489#issuecomment-1002075419


   This change will impose a huge performance impact on removing children. The complexity will change from O(1) to O(n) for a removal. This was the very reason why we used the LinkedMap from commons collections: it maintains a double linked list 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@wicket.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [wicket] asvanberg commented on pull request #489: Remove Apache collections4 as a runtime dependency

Posted by GitBox <gi...@apache.org>.
asvanberg commented on pull request #489:
URL: https://github.com/apache/wicket/pull/489#issuecomment-1002554981


   Are there any benchmarks that can be run to measure the performance difference? Or do you have a scenario in mind with "big component trees" where a lot of component removals are happening?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@wicket.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [wicket] papegaaij commented on pull request #489: Remove Apache collections4 as a runtime dependency

Posted by GitBox <gi...@apache.org>.
papegaaij commented on pull request #489:
URL: https://github.com/apache/wicket/pull/489#issuecomment-1004354514


   Unfortunately, we don't have any benchmarks in place. I once tried to get JMH working, but it gave a lot of issues in Eclipse. In this case, the scenario isn't that complicated: create a component with about 10000 children and remove them again. You'll notice the difference in performance. Removing all components is not a very common operation, but removing (or replacing) a few is. It's very unfortunate that LinkedHashMap does not expose methods for bidirectional traversal. It does maintain a double linked list, but the 'before' reference is internal.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@wicket.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [wicket] martin-g commented on pull request #489: Remove Apache collections4 as a runtime dependency

Posted by GitBox <gi...@apache.org>.
martin-g commented on pull request #489:
URL: https://github.com/apache/wicket/pull/489#issuecomment-1002443954


   I agree with @papegaaij that the new implementation of `previousKey()` will be slower and this will affect applications with big component trees.
   Many of the other suggested changes could be made! But since we will have to keep collections4 in the classpath I wonder whether there is a need.
   
   In the past Wicket (versions 1.0/1.1) have solved such problems by copying classes like `LinkedMap` in wicket-util. But this may lead to copying many classes - all directly used by LinkedMap.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@wicket.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org