eclipse-collections icon indicating copy to clipboard operation
eclipse-collections copied to clipboard

Adding value extractors for primitive iterable types

Open marko-bekhta opened this issue 8 years ago • 10 comments

Hi all,

as per http://beanvalidation.org/2.0/spec/#valueextractordefinition Bean validation 2.0 offers so called ValueExtractor mechanism to allow adding constraints for containers. I've added a couple of such extractors in a separate module for primitive iterables. Do you think this would be a good addition for Eclipse Collections? If so - it'll be great if you can point me to other collections that are not yet included but should probably have such extractors. Looking forward for the feedback. Thanks!

marko-bekhta avatar Oct 14 '17 11:10 marko-bekhta

@marko-bekhta firstly apologies for the delay in reply. I like the idea of having value extractors, but I would not want to have it in the same repository. We can have more than 1 repository for a project. Few reasons why:

  1. Addition of new dependencies: I want to keep Eclipse Collections dependency free. Also, to add new dependencies we will have to carefully look at the licenses and get it reviewed by Eclipse Foundation
  2. Release process: I would like to keep the release schedule of value extractors and Eclipse Collections separate. I expect the value extractor project to be fairly agile at start and then less aggressive when it stabilizes.
  3. Ease of experimentation: Eclipse Collections is a stable and mature project, where as I can see Value Extractors to be experimental at start and then mature over time. I am fine with that, but would like to break it up in to separate parts.
  4. Copyrights: From your PR the copyrights need to be updated. Please refer to: http://www.eclipse.org/projects/handbook/#ip-copyright-headers

How soon do you need value extractors? This will help me prioritize the conversations for new repository creation, etc.

nikhilnanivadekar avatar Oct 29 '17 16:10 nikhilnanivadekar

Hi @nikhilnanivadekar no worries, it's fine :) You have good points on having it separate. I was actually thinking that adding a new module to the current project would allow to package a separate releasable jar. But it would mean that both main collection jar as well as a value extractors should be released at the same time. So having a different project sounds better.

Copyrights: From your PR the copyrights need to be updated. Please refer to: http://www.eclipse.org/projects/handbook/#ip-copyright-headers

Hah, haven't seen that one. I'll make the changes and force-push the commit.

As for the last question - there's no rush on my side, so whenever you have time for this, is fine for me.

Also if I missed some collections - let me know, I can add extractors for those as well (either now or when the new repo is ready, depending on what works better for you)

marko-bekhta avatar Oct 30 '17 12:10 marko-bekhta

Hi @nikhilnanivadekar any news on this? I've fixed the license headers and in addition rebased on top of lates master changes.

marko-bekhta avatar Feb 04 '18 14:02 marko-bekhta

Apologies @marko-bekhta I forgot about this. I will follow up on getting a different repository for value extractors and post you. Thanks for your patience!

nikhilnanivadekar avatar Feb 10 '18 23:02 nikhilnanivadekar

hi @nikhilnanivadekar :) how's the follow up on a repository? Maybe I can help with something there ?

marko-bekhta avatar Mar 01 '18 13:03 marko-bekhta

I am pretty tied up at the moment. @itohiro73 can you please help take this forward?

nikhilnanivadekar avatar Mar 01 '18 13:03 nikhilnanivadekar

Hi, any news? If you can point me into the right direction I can try to get this moving forward. Thanks!

marko-bekhta avatar Sep 24 '18 08:09 marko-bekhta

@nikhilnanivadekar @marko-bekhta this PR is almost two years old. Should we revisit, rethink or close this?

donraab avatar Jul 12 '20 02:07 donraab

@donraab that's a good question :wink: I haven't seen much interest/need in these particular extractors since the time this PR was opened. Hence I'll leave it up to you to decide how you'd like to move forward with it. If any help is needed from me to bring this work up to date - just let me know.

marko-bekhta avatar Jul 14 '20 10:07 marko-bekhta

Apologies for the tardy reply. We have 2 options:

  1. Create a new module in Eclipse Collections repo so that value extractors can be released as a part of the main project
  2. Create a separate repo for value extractors

Both the approaches have their pros and cons.

  • If we add to the existing repo, we essentially add new dependencies which will need to go through Change Request approval, etc. Also, I personally prefer to have the main project free of external dependencies

  • If we create a new repo then it adds the additional steps to setup the infrastructure for releases, etc, etc.

Question to @marko-bekhta how do you foresee the extractors being used? I am not an hibernate expert so don't quite know how the value extractors will be situated and used. If you have documentation or code or blogs where I can get myself educated with this, it will help make us the decision.

Appreciate your patience and support! Cheers!

nikhilnanivadekar avatar Aug 10 '20 02:08 nikhilnanivadekar