From gunnar at hibernate.org Wed Aug 10 10:45:14 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Wed, 10 Aug 2016 16:45:14 +0200 Subject: [bv-dev] BV 2.0 - Introductions Message-ID: Hi everyone, I'm very happy to report that the review ballot for the Bean Validation 2.0 JSR proposal was approved by the JCP EC with a great majority [1]! This means we can get the ball rolling and work towards an early draft of the new spec revision. As described in [2], the schedule is compact and thus we'll need to choose the things to tackle wisely. The most important issue will be making BV fit for Java 8, but we should be able to address some other requests besides that. The JSR proposal [3] contains a few potential ideas, but I'm very eager to learn about your requests and demands from the field. Anything which helps to further improve usefulness and/or usability of BV is worth discussing. Note that you don't need to be on the expert group - although you are very welcome to join [7] - in order to contribute. We also value any inputs by non-members on this mailing list, the forum [4] and the issue tracker [5]. The JCP 2.10 rules (under which this JSR operates) foresee the role of "Contributors" which has very low entry barriers. Before diving into details though, let's have a quick round of introductions so everyone knows who they are dealing with :) Let me start: I'm working as a software engineer in the Hibernate team at Red Hat and took over the lead of the BV JSR from Emmanuel Bernard (who will remain active in the EG). In the past I've been contributing to the 1.1 spec (e.g. method validation), worked on the reference implementation Hibernate Validator (which I'm also leading now) and the 1.1 TCK. Besides BV, I'm working on several other projects in the Hibernate universe, most notably Hibernate OGM (providing object mapping via JPA to NoSQL stores) and Hibernate Search (providing full-text search for JPA domain models). I'm looking forward very much to make BV 2.0 happen together with all of you! I'll soon start separate thread(s) on some first action items. --Gunnar PS: Please subscribe to the beanvalidation-dev list [6] if you haven't done so yet; it's where discussions mostly will take place. To be sure I've sent this mail in copy to all those who had signalled an interest in contributing to BV 2.0 beforehand. [1] https://www.jcp.org/en/jsr/results?id=5871 [2] http://beanvalidation.org/news/2016/07/15/bean-validation-2-0-is-coming/ [3] https://jcp.org/en/jsr/detail?id=380 [4] https://forum.hibernate.org/viewforum.php?f=26 [5] https://hibernate.atlassian.net/projects/BVAL/summary [6] http://lists.jboss.org/pipermail/beanvalidation-dev/ [7] https://jcp.org/en/jsr/egnom?id=380 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160810/c7c7dfe8/attachment.html From gerhard.petracek at gmail.com Wed Aug 10 11:13:24 2016 From: gerhard.petracek at gmail.com (Gerhard Petracek) Date: Wed, 10 Aug 2016 17:13:24 +0200 Subject: [bv-dev] BV 2.0 - Introductions In-Reply-To: References: Message-ID: great to hear that! regards, gerhard 2016-08-10 16:45 GMT+02:00 Gunnar Morling : > Hi everyone, > > I'm very happy to report that the review ballot for the Bean Validation > 2.0 JSR proposal was approved by the JCP EC with a great majority [1]! > > This means we can get the ball rolling and work towards an early draft of > the new spec revision. As described in [2], the schedule is compact and > thus we'll need to choose the things to tackle wisely. The most important > issue will be making BV fit for Java 8, but we should be able to address > some other requests besides that. > > The JSR proposal [3] contains a few potential ideas, but I'm very eager to > learn about your requests and demands from the field. Anything which helps > to further improve usefulness and/or usability of BV is worth discussing. > > Note that you don't need to be on the expert group - although you are very > welcome to join [7] - in order to contribute. We also value any inputs by > non-members on this mailing list, the forum [4] and the issue tracker [5]. > The JCP 2.10 rules (under which this JSR operates) foresee the role of > "Contributors" which has very low entry barriers. > > Before diving into details though, let's have a quick round of > introductions so everyone knows who they are dealing with :) > > Let me start: > > I'm working as a software engineer in the Hibernate team at Red Hat and > took over the lead of the BV JSR from Emmanuel Bernard (who will remain > active in the EG). In the past I've been contributing to the 1.1 spec (e.g. > method validation), worked on the reference implementation Hibernate > Validator (which I'm also leading now) and the 1.1 TCK. Besides BV, I'm > working on several other projects in the Hibernate universe, most notably > Hibernate OGM (providing object mapping via JPA to NoSQL stores) and > Hibernate Search (providing full-text search for JPA domain models). > > I'm looking forward very much to make BV 2.0 happen together with all of > you! > > I'll soon start separate thread(s) on some first action items. > > --Gunnar > > PS: Please subscribe to the beanvalidation-dev list [6] if you haven't > done so yet; it's where discussions mostly will take place. To be sure I've > sent this mail in copy to all those who had signalled an interest in > contributing to BV 2.0 beforehand. > > [1] https://www.jcp.org/en/jsr/results?id=5871 > [2] http://beanvalidation.org/news/2016/07/15/bean- > validation-2-0-is-coming/ > [3] https://jcp.org/en/jsr/detail?id=380 > [4] https://forum.hibernate.org/viewforum.php?f=26 > [5] https://hibernate.atlassian.net/projects/BVAL/summary > [6] http://lists.jboss.org/pipermail/beanvalidation-dev/ > [7] https://jcp.org/en/jsr/egnom?id=380 > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160810/79332056/attachment.html From hendrik.ebbers at me.com Wed Aug 10 11:43:17 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Wed, 10 Aug 2016 17:43:17 +0200 Subject: [bv-dev] BV 2.0 - Introductions In-Reply-To: References: Message-ID: Cool news! Cheers, Hendrik > Am 10.08.2016 um 16:45 schrieb Gunnar Morling : > > Hi everyone, > > I'm very happy to report that the review ballot for the Bean Validation 2.0 JSR proposal was approved by the JCP EC with a great majority [1]! > > This means we can get the ball rolling and work towards an early draft of the new spec revision. As described in [2], the schedule is compact and thus we'll need to choose the things to tackle wisely. The most important issue will be making BV fit for Java 8, but we should be able to address some other requests besides that. > > The JSR proposal [3] contains a few potential ideas, but I'm very eager to learn about your requests and demands from the field. Anything which helps to further improve usefulness and/or usability of BV is worth discussing. > > Note that you don't need to be on the expert group - although you are very welcome to join [7] - in order to contribute. We also value any inputs by non-members on this mailing list, the forum [4] and the issue tracker [5]. The JCP 2.10 rules (under which this JSR operates) foresee the role of "Contributors" which has very low entry barriers. > > Before diving into details though, let's have a quick round of introductions so everyone knows who they are dealing with :) > > Let me start: > > I'm working as a software engineer in the Hibernate team at Red Hat and took over the lead of the BV JSR from Emmanuel Bernard (who will remain active in the EG). In the past I've been contributing to the 1.1 spec (e.g. method validation), worked on the reference implementation Hibernate Validator (which I'm also leading now) and the 1.1 TCK. Besides BV, I'm working on several other projects in the Hibernate universe, most notably Hibernate OGM (providing object mapping via JPA to NoSQL stores) and Hibernate Search (providing full-text search for JPA domain models). > > I'm looking forward very much to make BV 2.0 happen together with all of you! > > I'll soon start separate thread(s) on some first action items. > > --Gunnar > > PS: Please subscribe to the beanvalidation-dev list [6] if you haven't done so yet; it's where discussions mostly will take place. To be sure I've sent this mail in copy to all those who had signalled an interest in contributing to BV 2.0 beforehand. > > [1] https://www.jcp.org/en/jsr/results?id=5871 > [2] http://beanvalidation.org/news/2016/07/15/bean-validation-2-0-is-coming/ > [3] https://jcp.org/en/jsr/detail?id=380 > [4] https://forum.hibernate.org/viewforum.php?f=26 > [5] https://hibernate.atlassian.net/projects/BVAL/summary > [6] http://lists.jboss.org/pipermail/beanvalidation-dev/ > [7] https://jcp.org/en/jsr/egnom?id=380 > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160810/478c3442/attachment-0001.html From gunnar at hibernate.org Thu Aug 18 05:17:36 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Thu, 18 Aug 2016 11:17:36 +0200 Subject: [bv-dev] Three new EG members Message-ID: Hi, I'm very glad to welcome three new members to the BV 2.0 expert group: Hendrik Ebbers, Marco Molteni and Werner Keil! Hendrik from Canoo Engineering AG is very active in the JavaFX field and has lots of experiences when it comes to using BV in the context of UIs and JavaFX. Marco Molteni works as an independent consultant and brings a broad range of experience with applying BV in projects e.g. in the field of banking to the table. Werner Keil finally is a long-term member of the Java EE community and is member of the JCP EC and several other expert groups, amongst them being Java Money (JSR 354) for which we should discuss integration with BV. Hendrik, Marco, Werner, I'll leave it to yourselves to introduce you in greater depth and share your expectations/ideas towards BV 2.0. Welcome again and great to have you aboard! --Gunnar -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160818/4a57460a/attachment.html From guillaume.smet at gmail.com Fri Aug 19 03:46:37 2016 From: guillaume.smet at gmail.com (Guillaume Smet) Date: Fri, 19 Aug 2016 09:46:37 +0200 Subject: [bv-dev] BV 2.0 - Introductions In-Reply-To: References: Message-ID: Hi everyone, So, looks like we are all a bit shy! Let me also introduce myself. I'm working as a software engineer at Red Hat and I'm part of the Hibernate team. I will assist Gunnar in making this new version of the spec and reference implementation a real thing. I joined Red Hat a few months ago after having spent 13 years in a French IT services company specialized in OSS. As Gunnar, besides BV, I'm also working on Hibernate OGM and Hibernate Search - I contributed to Search in my previous life. On a more personal note, I live in Lyon, France. I'm really happy to join you! Let's get started! -- Guillaume From gunnar at hibernate.org Fri Aug 19 03:55:44 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Fri, 19 Aug 2016 09:55:44 +0200 Subject: [bv-dev] Spec document converted to AsciiDoc Message-ID: Hi all, In a huge team effort (thanks Sanne, Guillaume et al.!) the BV spec has been converted from DocBook into AsciiDoc. This should make the editing and collaboration experience much nicer (easier syntax, renders much faster, rich diff on GitHub etc.). The AsciiDoc sources of the individual spec chapters can be found at [1]. A rendered HTML version is published on beanvalidation.org [2]. Refer to the README.md in the repo if you want to build the spec yourself locally. It'd be a great help if everyone could take a look at the document and report back on any formatting or other issues that may have sneaked in during conversion. No actual changes to the wording have been made at this point apart from adding some pointers that this is about BV 2.0 and JSR 380. Thanks for any feedback, --Gunnar [1] https://github.com/beanvalidation/beanvalidation-spec/tree/master/sources [2] http://beanvalidation.org/latest-draft/spec/ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/7bf41531/attachment.html From gunnar at hibernate.org Fri Aug 19 05:46:25 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Fri, 19 Aug 2016 11:46:25 +0200 Subject: [bv-dev] Some first proposals Message-ID: Hi all, The way we've been working towards changes in BV 1.1 was via a proposal document for each suggested change, investigating different options, their pros and cons etc. As needed, we'd also prototype specific approaches in the RI. Once consensus was reached, someone would modify the spec document as per the agreed on solution. Proposals are simple AsciiDoc files living on the website. There are already a couple of first proposals for BV 2.0 listed [1]. Feedback on these is highly welcome, either on GitHub (e.g. by commenting inline or sending a PR with another option for a given issue) or here on the mailing list. Hendrik, the one for BVAL-214 ([2], "Ability to validate an object and a list of changes") may be of specific interest for JavaFX, because it should improve cross-field validation in UI use cases (think of field "password" should match field "password confirm"). What we should do for JavaFX in general is a very interesting topic on its own, but probably better to discuss that one separately. Everyone is welcome to work on new proposals themselves. If you are interested, check out the issues currently marked for 2.0 in the JIRA tracker [3] and let me know if you'd like to get going on individual items. This list of BV 2.0 change candidates is not cast in stone (nor will we be able to address all of it), so if you think something should be (up high) on that list, please speak up. My personal focus will mostly be on the Java 8 related changes for the time being, with the usage of type level annotations being the one requiring the most consideration probably. Cheers, --Gunnar [1] http://beanvalidation.org/proposals/ [2] http://beanvalidation.org/proposals/BVAL-214 [3] https://hibernate.atlassian.net/issues/?jql=project%20%3D%20BVAL%20AND%20status%20in%20(Open%2C%20Reopened)%20AND%20fixVersion%20%3D%202.0%20ORDER%20BY%20priority%20DESC -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/7e4da0af/attachment.html From gunnar at hibernate.org Fri Aug 19 06:29:47 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Fri, 19 Aug 2016 12:29:47 +0200 Subject: [bv-dev] Namespace for XML descriptors Message-ID: Hi all, The XML descriptors in BV (validation.xml, constraint mapping XML files) use a jboss.org specific namespace as of 1.1. We should change that into something under jcp.org [1] which is what all other descriptors of Java EE techs do as of Java EE 7 (see Antonio Goncalves' blog post on this topic at [2]). What's rather unclear to me is why most of techs share the same namespace " http://xmlns.jcp.org/xml/ns/javaee", e.g. JSF, CDI and Servlet as per Antonio's post. I think having a specific names space for BV is more sensible (as done by JPA, too), not the least because BV isn't tied to EE. So I'd suggest to use * http://xmlns.jcp.org/xml/ns/validation" (for validation.xml) * http://xmlns.jcp.org/xml/ns/validation/mapping" (for constraint validation mapping files) Any thoughts? Thanks, --Gunnar [1] https://hibernate.atlassian.net/browse/BVAL-455 [2] https://antoniogoncalves.org/2013/06/04/java-ee-7-deployment-descriptors/ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/a5913182/attachment.html From hendrik.ebbers at me.com Fri Aug 19 06:33:51 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Fri, 19 Aug 2016 12:33:51 +0200 Subject: [bv-dev] Three new EG members In-Reply-To: References: Message-ID: <38DB67F8-1654-426B-882E-957FDCF35180@me.com> Hi all, I want to use this mail to introduce myself. I?m a Java developer at Canoo Engineering AG and live in Dortmund, Germany. The last years I worked on several JavaFX projects and did a lot of JavaFX community work (D-Zone RefCard, talks, ?). In general I?m a Java developer / consultant / architect and work in JavaEE, Spring or frontend (JavaFX or Swing) projects. If you want to know more about me you can have a look here: www.guigarage.com :) I already used JBV in several projects on the server and the client. Last years I did a first proof of concept how JBV can be used in JavaFX: https://github.com/guigarage/ValidateFX I did extensions for other projects, too. https://github.com/canoo/dolphin-platform/tree/master/platform-extras/dolphin-platform-bean-validation Cheers, Hendrik > Am 18.08.2016 um 11:17 schrieb Gunnar Morling : > > Hi, > > I'm very glad to welcome three new members to the BV 2.0 expert group: Hendrik Ebbers, Marco Molteni and Werner Keil! > > Hendrik from Canoo Engineering AG is very active in the JavaFX field and has lots of experiences when it comes to using BV in the context of UIs and JavaFX. > > Marco Molteni works as an independent consultant and brings a broad range of experience with applying BV in projects e.g. in the field of banking to the table. > > Werner Keil finally is a long-term member of the Java EE community and is member of the JCP EC and several other expert groups, amongst them being Java Money (JSR 354) for which we should discuss integration with BV. > > Hendrik, Marco, Werner, I'll leave it to yourselves to introduce you in greater depth and share your expectations/ideas towards BV 2.0. Welcome again and great to have you aboard! > > --Gunnar > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev From hendrik.ebbers at me.com Fri Aug 19 06:52:49 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Fri, 19 Aug 2016 12:52:49 +0200 Subject: [bv-dev] Namespace for XML descriptors In-Reply-To: References: Message-ID: <657FCDC3-8C27-4ACD-B2A2-5AF0BC7EAB8F@me.com> Hi Gunnar, I like the idea. Cheers, Hendrik > Am 19.08.2016 um 12:29 schrieb Gunnar Morling : > > Hi all, > > The XML descriptors in BV (validation.xml, constraint mapping XML files) use a jboss.org specific namespace as of 1.1. We should change that into something under jcp.org [1] which is what all other descriptors of Java EE techs do as of Java EE 7 (see Antonio Goncalves' blog post on this topic at [2]). > > What's rather unclear to me is why most of techs share the same namespace "http://xmlns.jcp.org/xml/ns/javaee ", e.g. JSF, CDI and Servlet as per Antonio's post. I think having a specific names space for BV is more sensible (as done by JPA, too), not the least because BV isn't tied to EE. > > So I'd suggest to use > > * http://xmlns.jcp.org/xml/ns/validation " (for validation.xml) > * http://xmlns.jcp.org/xml/ns/validation/mapping " (for constraint validation mapping files) > > Any thoughts? > > Thanks, > > --Gunnar > > [1] https://hibernate.atlassian.net/browse/BVAL-455 > [2] https://antoniogoncalves.org/2013/06/04/java-ee-7-deployment-descriptors/ > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/7b804874/attachment.html From hendrik.ebbers at me.com Fri Aug 19 07:10:39 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Fri, 19 Aug 2016 13:10:39 +0200 Subject: [bv-dev] CI for API, TCK.. Message-ID: Hi, should we use Travis (https://travis-ci.org) for CI of all the repos? I can provide a PR that contains the configuration. Cheers, Hendrik From guillaume.smet at gmail.com Fri Aug 19 08:23:37 2016 From: guillaume.smet at gmail.com (Guillaume Smet) Date: Fri, 19 Aug 2016 14:23:37 +0200 Subject: [bv-dev] CI for API, TCK.. In-Reply-To: References: Message-ID: Hi Hendrik, At the moment, the official CI for BV and Hibernate Validator is on Cloudbees: https://hibernate-validator.ci.cloudbees.com/ . I did the work to add a .travis.yml for Validator a while ago so that we can have CI for our own forks. Not sure it's worth it for every repository but it might be worth the work for some. Gunnar, thoughts? On Fri, Aug 19, 2016 at 1:10 PM, Hendrik Ebbers wrote: > Hi, > > should we use Travis (https://travis-ci.org) for CI of all the repos? I > can provide a PR that contains the configuration. > > Cheers, > > Hendrik > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/78062f29/attachment.html From gunnar at hibernate.org Fri Aug 19 08:41:38 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Fri, 19 Aug 2016 14:41:38 +0200 Subject: [bv-dev] CI for API, TCK.. In-Reply-To: References: Message-ID: Hi, Thanks for making this proposal! As Guillaume is saying, we have CI jobs for all the BV/HV artifacts on CloudBees already (some other related things such as the website build are on the main Hibernate CI server). So I don't think we'll gain very much by adding the Travis configuration. But if would actually be helpful to you, e.g. in order to more easily have CI for your own forks, then I don't mind having the config added. Glad to accept a PR if you feel like giving it a shot. Cheers, --Gunnar 2016-08-19 14:23 GMT+02:00 Guillaume Smet : > Hi Hendrik, > > At the moment, the official CI for BV and Hibernate Validator is on > Cloudbees: https://hibernate-validator.ci.cloudbees.com/ . > > I did the work to add a .travis.yml for Validator a while ago so that we > can have CI for our own forks. > > Not sure it's worth it for every repository but it might be worth the work > for some. > > Gunnar, thoughts? > > > On Fri, Aug 19, 2016 at 1:10 PM, Hendrik Ebbers > wrote: > >> Hi, >> >> should we use Travis (https://travis-ci.org) for CI of all the repos? I >> can provide a PR that contains the configuration. >> >> Cheers, >> >> Hendrik >> _______________________________________________ >> beanvalidation-dev mailing list >> beanvalidation-dev at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/beanvalidation-dev >> > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/1341dafc/attachment.html From hendrik.ebbers at me.com Fri Aug 19 08:47:20 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Fri, 19 Aug 2016 14:47:20 +0200 Subject: [bv-dev] CI for API, TCK.. In-Reply-To: References: Message-ID: Hi, that?s fine :) I didn?t know that a CI is already setup. > Am 19.08.2016 um 14:41 schrieb Gunnar Morling : > > Hi, > > Thanks for making this proposal! > > As Guillaume is saying, we have CI jobs for all the BV/HV artifacts on CloudBees already (some other related things such as the website build are on the main Hibernate CI server). > > So I don't think we'll gain very much by adding the Travis configuration. But if would actually be helpful to you, e.g. in order to more easily have CI for your own forks, then I don't mind having the config added. Glad to accept a PR if you feel like giving it a shot. > > Cheers, > > --Gunnar > > > > > 2016-08-19 14:23 GMT+02:00 Guillaume Smet >: > Hi Hendrik, > > At the moment, the official CI for BV and Hibernate Validator is on Cloudbees: https://hibernate-validator.ci.cloudbees.com/ . > > I did the work to add a .travis.yml for Validator a while ago so that we can have CI for our own forks. > > Not sure it's worth it for every repository but it might be worth the work for some. > > Gunnar, thoughts? > > > On Fri, Aug 19, 2016 at 1:10 PM, Hendrik Ebbers > wrote: > Hi, > > should we use Travis (https://travis-ci.org ) for CI of all the repos? I can provide a PR that contains the configuration. > > Cheers, > > Hendrik > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/7ab7a46c/attachment-0001.html From gunnar at hibernate.org Fri Aug 19 08:50:33 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Fri, 19 Aug 2016 14:50:33 +0200 Subject: [bv-dev] CI for API, TCK.. In-Reply-To: References: Message-ID: Seems we should add some pointer on beanvalidation.org :) 2016-08-19 14:47 GMT+02:00 Hendrik Ebbers : > Hi, > > that?s fine :) I didn?t know that a CI is already setup. > > Am 19.08.2016 um 14:41 schrieb Gunnar Morling : > > Hi, > > Thanks for making this proposal! > > As Guillaume is saying, we have CI jobs for all the BV/HV artifacts on > CloudBees already (some other related things such as the website build are > on the main Hibernate CI server). > > So I don't think we'll gain very much by adding the Travis configuration. > But if would actually be helpful to you, e.g. in order to more easily have > CI for your own forks, then I don't mind having the config added. Glad to > accept a PR if you feel like giving it a shot. > > Cheers, > > --Gunnar > > > > > 2016-08-19 14:23 GMT+02:00 Guillaume Smet : > >> Hi Hendrik, >> >> At the moment, the official CI for BV and Hibernate Validator is on >> Cloudbees: https://hibernate-validator.ci.cloudbees.com/ . >> >> I did the work to add a .travis.yml for Validator a while ago so that we >> can have CI for our own forks. >> >> Not sure it's worth it for every repository but it might be worth the >> work for some. >> >> Gunnar, thoughts? >> >> >> On Fri, Aug 19, 2016 at 1:10 PM, Hendrik Ebbers >> wrote: >> >>> Hi, >>> >>> should we use Travis (https://travis-ci.org) for CI of all the repos? I >>> can provide a PR that contains the configuration. >>> >>> Cheers, >>> >>> Hendrik >>> _______________________________________________ >>> beanvalidation-dev mailing list >>> beanvalidation-dev at lists.jboss.org >>> https://lists.jboss.org/mailman/listinfo/beanvalidation-dev >>> >> >> >> _______________________________________________ >> beanvalidation-dev mailing list >> beanvalidation-dev at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/beanvalidation-dev >> > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/95c8ec1a/attachment.html From guillaume.smet at gmail.com Fri Aug 19 10:46:59 2016 From: guillaume.smet at gmail.com (Guillaume Smet) Date: Fri, 19 Aug 2016 16:46:59 +0200 Subject: [bv-dev] Namespace for XML descriptors In-Reply-To: References: Message-ID: Hi, I like the idea. Would go for bean-validation though, instead of validation. -- Guillaume On Fri, Aug 19, 2016 at 12:29 PM, Gunnar Morling wrote: > Hi all, > > The XML descriptors in BV (validation.xml, constraint mapping XML files) > use a jboss.org specific namespace as of 1.1. We should change that into > something under jcp.org [1] which is what all other descriptors of Java > EE techs do as of Java EE 7 (see Antonio Goncalves' blog post on this topic > at [2]). > > What's rather unclear to me is why most of techs share the same namespace " > http://xmlns.jcp.org/xml/ns/javaee", e.g. JSF, CDI and Servlet as per > Antonio's post. I think having a specific names space for BV is more > sensible (as done by JPA, too), not the least because BV isn't tied to EE. > > So I'd suggest to use > > * http://xmlns.jcp.org/xml/ns/validation" (for validation.xml) > * http://xmlns.jcp.org/xml/ns/validation/mapping" (for constraint > validation mapping files) > > Any thoughts? > > Thanks, > > --Gunnar > > [1] https://hibernate.atlassian.net/browse/BVAL-455 > [2] https://antoniogoncalves.org/2013/06/04/java-ee-7- > deployment-descriptors/ > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/6ef816cc/attachment.html From moltenma at gmail.com Fri Aug 19 16:02:23 2016 From: moltenma at gmail.com (Marco Molteni) Date: Fri, 19 Aug 2016 22:02:23 +0200 Subject: [bv-dev] Three new EG members In-Reply-To: <38DB67F8-1654-426B-882E-957FDCF35180@me.com> References: <38DB67F8-1654-426B-882E-957FDCF35180@me.com> Message-ID: Hello everybody, It seems that it's my turn to introduce myself. I'm a Java consultant since 2001. I worked as freelance for software companies, governmental agencies and banks staying all the time on the front (sitting at the clients desk). As you know external consultants are called when there are too many problems that nobody can/want solve and the deadline is .. dead. In short, just the fun :) I had roles as Developer, Technical consultant, Analyst, Project manager ... whatever the client needed. I live and work in Switzerland. Currently I'm working as Java developer on some banking projects for Hewlett Packard. More here: http://mycv.host Bean Validator I used the RI in some projects in which there was a lot of data exchange between services (RS and WS). As usual, the analysts enjoyed to write tons of rules about all the possible values for each field and the developers spent moths to write validation code like : 'if (age == null || age <18 || ...)' for every field. The introduction of BV reduced a lot the amount of issues and code. Unfortunately it seems that nobody think about BV when they start to use (more and more frequently) WS or REST services (maybe because the RI contains the name Hibernate?). My expectations? An easy to use, performant, flexible and well know tool for the Java developers. I'm glad if I can help with this. beanvalidation-dev: I will read all the communications on the list, but I will have the possibility to participate only when I leave the client office. Cheers, Marco On Fri, Aug 19, 2016 at 12:33 PM, Hendrik Ebbers wrote: > Hi all, > > I want to use this mail to introduce myself. > > I?m a Java developer at Canoo Engineering AG and live in Dortmund, > Germany. The last years I worked on several JavaFX projects and did a lot > of JavaFX community work (D-Zone RefCard, talks, ?). In general I?m a Java > developer / consultant / architect and work in JavaEE, Spring or frontend > (JavaFX or Swing) projects. If you want to know more about me you can have > a look here: www.guigarage.com :) > > I already used JBV in several projects on the server and the client. Last > years I did a first proof of concept how JBV can be used in JavaFX: > https://github.com/guigarage/ValidateFX > I did extensions for other projects, too. https://github.com/canoo/ > dolphin-platform/tree/master/platform-extras/dolphin- > platform-bean-validation > > Cheers, > > Hendrik > > > Am 18.08.2016 um 11:17 schrieb Gunnar Morling : > > > > Hi, > > > > I'm very glad to welcome three new members to the BV 2.0 expert group: > Hendrik Ebbers, Marco Molteni and Werner Keil! > > > > Hendrik from Canoo Engineering AG is very active in the JavaFX field and > has lots of experiences when it comes to using BV in the context of UIs and > JavaFX. > > > > Marco Molteni works as an independent consultant and brings a broad > range of experience with applying BV in projects e.g. in the field of > banking to the table. > > > > Werner Keil finally is a long-term member of the Java EE community and > is member of the JCP EC and several other expert groups, amongst them being > Java Money (JSR 354) for which we should discuss integration with BV. > > > > Hendrik, Marco, Werner, I'll leave it to yourselves to introduce you in > greater depth and share your expectations/ideas towards BV 2.0. Welcome > again and great to have you aboard! > > > > --Gunnar > > > > _______________________________________________ > > beanvalidation-dev mailing list > > beanvalidation-dev at lists.jboss.org > > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160819/31d039a8/attachment-0001.html From moltenma at gmail.com Fri Aug 19 18:18:20 2016 From: moltenma at gmail.com (Marco Molteni) Date: Sat, 20 Aug 2016 00:18:20 +0200 Subject: [bv-dev] Namespace for XML descriptors In-Reply-To: References: Message-ID: Hi, I like the idea of Gunnar too. Personally, I'm not a big fan of the hypens in the names (e.g. bean-validation). I would ask Antonio if there is any particular to use the 'javaee' namespace. I didn't find any debate about the non-conformity of the Persistence API (http://xmlns.jcp.org/xml/ns/persistence/). Marco On Fri, Aug 19, 2016 at 12:29 PM, Gunnar Morling wrote: > Hi all, > > The XML descriptors in BV (validation.xml, constraint mapping XML files) > use a jboss.org specific namespace as of 1.1. We should change that into > something under jcp.org [1] which is what all other descriptors of Java > EE techs do as of Java EE 7 (see Antonio Goncalves' blog post on this topic > at [2]). > > What's rather unclear to me is why most of techs share the same namespace " > http://xmlns.jcp.org/xml/ns/javaee", e.g. JSF, CDI and Servlet as per > Antonio's post. I think having a specific names space for BV is more > sensible (as done by JPA, too), not the least because BV isn't tied to EE. > > So I'd suggest to use > > * http://xmlns.jcp.org/xml/ns/validation" (for validation.xml) > * http://xmlns.jcp.org/xml/ns/validation/mapping" (for constraint > validation mapping files) > > Any thoughts? > > Thanks, > > --Gunnar > > [1] https://hibernate.atlassian.net/browse/BVAL-455 > [2] https://antoniogoncalves.org/2013/06/04/java-ee-7- > deployment-descriptors/ > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160820/f9189921/attachment.html From moltenma at gmail.com Mon Aug 22 13:37:32 2016 From: moltenma at gmail.com (Marco Molteni) Date: Mon, 22 Aug 2016 19:37:32 +0200 Subject: [bv-dev] BV 2.0 - Add constraints? Message-ID: Hi all, It would be possible to add some built-in constraints to the V 2.0? @NotBlank, @NotEmpty, @Length are used very often in projects, they are already present in Hibernate Validator and their implementation is well defined. What do you think? Here a list of the most used constraint for GitHub's projects (the numbers change at every request but you get the idea. HV = Hibernate Validator, BV = Bean Validation): 189'143 - BV - NotNull 56'902 - BV - Size 39'551 - HV - NotEmpty <- 20'687 - HV - NotBlank <- 17'735 - BV - Pattern 16'763 - HV - Email 16'033 - BV - Min 12'769 - HV - Length <- 7'806 - BV - Digits 4'982 - BV - Max 4'971 - BV - Past 3'598 - BV - DecimalMin 2'753 - BV - AssertTrue 2'379 - BV - DecimalMax 2'308 - BV - Future 1'999 - HV - Range 1'497 - HV - URL < 1'000 other constraints Thanks Cheers Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160822/1148fde0/attachment.html From hendrik.ebbers at me.com Mon Aug 22 14:32:14 2016 From: hendrik.ebbers at me.com (Hendrik Ebbers) Date: Mon, 22 Aug 2016 20:32:14 +0200 Subject: [bv-dev] BV 2.0 - Add constraints? In-Reply-To: References: Message-ID: An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160822/8b0c6961/attachment.html From gunnar at hibernate.org Tue Aug 23 06:15:53 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Tue, 23 Aug 2016 12:15:53 +0200 Subject: [bv-dev] BV 2.0 - Add constraints? In-Reply-To: References: Message-ID: Hi Marco, Nice research! Out of curiosity, how did you get these numbers? Historically, the spec stayed on the conservative end in terms of built-in constraints. @NotEmpty etc. can quite easily be implemented or even just be composed based on other built-in constraints. But the numbers you shared indeed indicate some usefulness of adding at least some. Would be interesting to know what others think? Cheers, --Gunnar 2016-08-22 20:32 GMT+02:00 Hendrik Ebbers : > +1 > > Am 22.08.2016 um 19:37 schrieb Marco Molteni : > > Hi all, > > It would be possible to add some built-in constraints to the V 2.0? > > @NotBlank, @NotEmpty, @Length are used very often in projects, they are > already present in Hibernate Validator and their implementation is well > defined. > > What do you think? > > Here a list of the most used constraint for GitHub's projects (the numbers > change at every request but you get the idea. HV = Hibernate Validator, > BV = Bean Validation): > > 189'143 - BV - NotNull > 56'902 - BV - Size > 39'551 - HV - NotEmpty <- > 20'687 - HV - NotBlank <- > 17'735 - BV - Pattern > 16'763 - HV - Email > 16'033 - BV - Min > 12'769 - HV - Length <- > 7'806 - BV - Digits > 4'982 - BV - Max > 4'971 - BV - Past > 3'598 - BV - DecimalMin > 2'753 - BV - AssertTrue > 2'379 - BV - DecimalMax > 2'308 - BV - Future > 1'999 - HV - Range > 1'497 - HV - URL > < 1'000 other constraints > > Thanks > > Cheers > > Marco > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160823/11708d8e/attachment-0001.html From moltenma at gmail.com Tue Aug 23 11:49:44 2016 From: moltenma at gmail.com (Marco Molteni) Date: Tue, 23 Aug 2016 17:49:44 +0200 Subject: [bv-dev] BV 2.0 - Add constraints? In-Reply-To: References: Message-ID: Hi Gunnar, Here the procedure to find the result: 1. Quick and dirty copy this url and rellace the class name in the result page https://github.com/search?l=&q=javax.validation.constraints.NotNull+language%3AJava&ref=advsearch&type=Code&utf8=%E2%9C%93 2. Step by step You can go here: https://github.com/search/advanced You should search the full class name of the annotation, ex. : javax.validation.constraints.NotNull You can set the language to Java. After you execute the query you can filter only the results in 'Code'. Like this you can find where an annotation class is imported. Remarks: At every execution the result change 5-10%, it's absolutely not scientific (I don't know how it works their index and search) but you can get an idea of the usage of some classes. Cheers, Marco On Tue, Aug 23, 2016 at 12:15 PM, Gunnar Morling wrote: > Hi Marco, > > Nice research! Out of curiosity, how did you get these numbers? > > Historically, the spec stayed on the conservative end in terms of built-in > constraints. @NotEmpty etc. can quite easily be implemented or even just be > composed based on other built-in constraints. But the numbers you shared > indeed indicate some usefulness of adding at least some. > > Would be interesting to know what others think? > > Cheers, > > --Gunnar > > > > > 2016-08-22 20:32 GMT+02:00 Hendrik Ebbers : > >> +1 >> >> Am 22.08.2016 um 19:37 schrieb Marco Molteni : >> >> Hi all, >> >> It would be possible to add some built-in constraints to the V 2.0? >> >> @NotBlank, @NotEmpty, @Length are used very often in projects, they are >> already present in Hibernate Validator and their implementation is well >> defined. >> >> What do you think? >> >> Here a list of the most used constraint for GitHub's projects (the >> numbers change at every request but you get the idea. HV = Hibernate >> Validator, BV = Bean Validation): >> >> 189'143 - BV - NotNull >> 56'902 - BV - Size >> 39'551 - HV - NotEmpty <- >> 20'687 - HV - NotBlank <- >> 17'735 - BV - Pattern >> 16'763 - HV - Email >> 16'033 - BV - Min >> 12'769 - HV - Length <- >> 7'806 - BV - Digits >> 4'982 - BV - Max >> 4'971 - BV - Past >> 3'598 - BV - DecimalMin >> 2'753 - BV - AssertTrue >> 2'379 - BV - DecimalMax >> 2'308 - BV - Future >> 1'999 - HV - Range >> 1'497 - HV - URL >> < 1'000 other constraints >> >> Thanks >> >> Cheers >> >> Marco >> _______________________________________________ >> beanvalidation-dev mailing list >> beanvalidation-dev at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/beanvalidation-dev >> >> >> >> _______________________________________________ >> beanvalidation-dev mailing list >> beanvalidation-dev at lists.jboss.org >> https://lists.jboss.org/mailman/listinfo/beanvalidation-dev >> > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160823/b97ba63f/attachment.html From gunnar at hibernate.org Thu Aug 25 06:10:17 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Thu, 25 Aug 2016 12:10:17 +0200 Subject: [bv-dev] Proposal for supporting new Java 8 date/time types Message-ID: Hi, I've pushed another proposal to the website [1], it's about adding @Past/@Future support for the date/time types added in Java 8 (java.time.* package, added by JSR 310). The proposal essentially standardizes the proprietary support we had in HV, plus some additions. Please let me know what you think, especially on the questions towards the end. Either put comments inline on the source on GitHub [2] or let's have a discussion here. I haven't been using JSR 310 extensively myself, so any feedback by those who have is more than welcome. Thanks, --Gunnar [1] http://beanvalidation.org/proposals/BVAL-496/ [2] https://github.com/beanvalidation/beanvalidation.org/blob/production/proposals/BVAL-496.adoc -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160825/651e6edb/attachment.html From emmanuel at hibernate.org Thu Aug 25 07:41:08 2016 From: emmanuel at hibernate.org (Emmanuel Bernard) Date: Thu, 25 Aug 2016 13:41:08 +0200 Subject: [bv-dev] BV 2.0 - Introductions In-Reply-To: References: Message-ID: <20160825114108.GF83706@hibernate.org> Hey everyone, I'm glad we finally managed to get this ball rolling :) I'm Emmanuel Bernard, I'm the platform architect for data related products at Red Hat middleware and the former spec lead of Bean Validation. I'll be contributing as much as I can. Anyways, the lead of the spec is in good hands. Cheers Emmanuel On Wed 2016-08-10 16:45, Gunnar Morling wrote: > Hi everyone, > > I'm very happy to report that the review ballot for the Bean Validation 2.0 > JSR proposal was approved by the JCP EC with a great majority [1]! > > This means we can get the ball rolling and work towards an early draft of > the new spec revision. As described in [2], the schedule is compact and > thus we'll need to choose the things to tackle wisely. The most important > issue will be making BV fit for Java 8, but we should be able to address > some other requests besides that. > > The JSR proposal [3] contains a few potential ideas, but I'm very eager to > learn about your requests and demands from the field. Anything which helps > to further improve usefulness and/or usability of BV is worth discussing. > > Note that you don't need to be on the expert group - although you are very > welcome to join [7] - in order to contribute. We also value any inputs by > non-members on this mailing list, the forum [4] and the issue tracker [5]. > The JCP 2.10 rules (under which this JSR operates) foresee the role of > "Contributors" which has very low entry barriers. > > Before diving into details though, let's have a quick round of > introductions so everyone knows who they are dealing with :) > > Let me start: > > I'm working as a software engineer in the Hibernate team at Red Hat and > took over the lead of the BV JSR from Emmanuel Bernard (who will remain > active in the EG). In the past I've been contributing to the 1.1 spec (e.g. > method validation), worked on the reference implementation Hibernate > Validator (which I'm also leading now) and the 1.1 TCK. Besides BV, I'm > working on several other projects in the Hibernate universe, most notably > Hibernate OGM (providing object mapping via JPA to NoSQL stores) and > Hibernate Search (providing full-text search for JPA domain models). > > I'm looking forward very much to make BV 2.0 happen together with all of > you! > > I'll soon start separate thread(s) on some first action items. > > --Gunnar > > PS: Please subscribe to the beanvalidation-dev list [6] if you haven't done > so yet; it's where discussions mostly will take place. To be sure I've sent > this mail in copy to all those who had signalled an interest in > contributing to BV 2.0 beforehand. > > [1] https://www.jcp.org/en/jsr/results?id=5871 > [2] http://beanvalidation.org/news/2016/07/15/bean-validation-2-0-is-coming/ > [3] https://jcp.org/en/jsr/detail?id=380 > [4] https://forum.hibernate.org/viewforum.php?f=26 > [5] https://hibernate.atlassian.net/projects/BVAL/summary > [6] http://lists.jboss.org/pipermail/beanvalidation-dev/ > [7] https://jcp.org/en/jsr/egnom?id=380 > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev From emmanuel at hibernate.org Thu Aug 25 08:03:36 2016 From: emmanuel at hibernate.org (Emmanuel Bernard) Date: Thu, 25 Aug 2016 14:03:36 +0200 Subject: [bv-dev] Namespace for XML descriptors In-Reply-To: References: Message-ID: <20160825120336.GG83706@hibernate.org> On Fri 2016-08-19 12:29, Gunnar Morling wrote: > * http://xmlns.jcp.org/xml/ns/validation" (for validation.xml) > * http://xmlns.jcp.org/xml/ns/validation/mapping" (for constraint > validation mapping files) This is my preference as well (i.e. not to have javaee in the namespace). Emmanuel From gunnar at hibernate.org Thu Aug 25 08:23:08 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Thu, 25 Aug 2016 14:23:08 +0200 Subject: [bv-dev] Namespace for XML descriptors In-Reply-To: <20160825120336.GG83706@hibernate.org> References: <20160825120336.GG83706@hibernate.org> Message-ID: Cool. It has been changed like this, with one small deviation, it's " http://xmlns.jcp.org/xml/ns/validation/configuration" and " http://xmlns.jcp.org/xml/ns/validation/mapping". The reasoning for appending "configuration" to the main one being closer resemblance to the previous BV name. Also the file is named "validation-configuration-2.0.xsd" instead of "validation-2.0.xsd". I've asked the PMO how to put up files to jcp.org eventually but am still waiting to hear back. --Gunnar 2016-08-25 14:03 GMT+02:00 Emmanuel Bernard : > On Fri 2016-08-19 12:29, Gunnar Morling wrote: > > * http://xmlns.jcp.org/xml/ns/validation" (for validation.xml) > > * http://xmlns.jcp.org/xml/ns/validation/mapping" (for constraint > > validation mapping files) > > This is my preference as well (i.e. not to have javaee in the > namespace). > > Emmanuel > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160825/d1cb5cd0/attachment-0001.html From emmanuel at hibernate.org Thu Aug 25 08:28:08 2016 From: emmanuel at hibernate.org (Emmanuel Bernard) Date: Thu, 25 Aug 2016 14:28:08 +0200 Subject: [bv-dev] BV 2.0 - Add constraints? In-Reply-To: References: Message-ID: <20160825122808.GA90254@hibernate.org> The historical reason for the restricted list of constraints in the BV spec is that this set represents the fundamental constraints you can express and often propagate to other systems (like DB DDLs). So the reluctance came from this and a hope that an ecosystem of constraints would be built. But these numbers are interesting (*) and embracing more constraints looks like a good idea. It is probably worth doing a blog to gather feedback. Or maybe a survey. (*) GitHub hosts a list of "non-usual" projects, most 9-5 projects are behind closed source doors. So there is a natural skew. Emmanuel On Mon 2016-08-22 19:37, Marco Molteni wrote: > Hi all, > > It would be possible to add some built-in constraints to the V 2.0? > > @NotBlank, @NotEmpty, @Length are used very often in projects, they are > already present in Hibernate Validator and their implementation is well > defined. > > What do you think? > > Here a list of the most used constraint for GitHub's projects (the numbers > change at every request but you get the idea. HV = Hibernate Validator, BV > = Bean Validation): > > 189'143 - BV - NotNull > 56'902 - BV - Size > 39'551 - HV - NotEmpty <- > 20'687 - HV - NotBlank <- > 17'735 - BV - Pattern > 16'763 - HV - Email > 16'033 - BV - Min > 12'769 - HV - Length <- > 7'806 - BV - Digits > 4'982 - BV - Max > 4'971 - BV - Past > 3'598 - BV - DecimalMin > 2'753 - BV - AssertTrue > 2'379 - BV - DecimalMax > 2'308 - BV - Future > 1'999 - HV - Range > 1'497 - HV - URL > < 1'000 other constraints > > Thanks > > Cheers > > Marco > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev From moltenma at gmail.com Mon Aug 29 01:38:59 2016 From: moltenma at gmail.com (Marco Molteni) Date: Mon, 29 Aug 2016 07:38:59 +0200 Subject: [bv-dev] Promote fail fast? Message-ID: Hi guys, What do you think about the 'promotion' of fail-fast (from hibernate validator) to the BV API? I see frequently this 2 use cases (in the 9-5 projects) to support the request ;) 1. batch: there are a lot of batch processes that have to validate the input data (flat file -> bean -> validation) and return for each bean only a technical error if at least one field is not valid ('input refused'). When there are millions (e.g. payments transactions) of beans to validate in a batch and 30-50 fields for each bean the fail-fast saves a lot of time (and the night is never long enough for all the batches required) ;) 2. REST response: in the validation of REST services often when 2 systems exchange data the answer in case of error is an HTTP 4xx without many details. The fail-fast is a time and machine resources saving when your application is accessed by (hundred of) thousand users through some external web client (e.g. JS client). In the do-it-yourself implementations for the 2 uses cases at the first error an IllegalArgumentException is thrown with the information of the first error found. The full test of every field is very well suited for uses cases in which there is a human to machine communication (e.g. web forms). If your opinion is positive I can do more investigations if needed. Cheers Marco -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160829/1dd8644c/attachment.html From gunnar at hibernate.org Tue Aug 30 02:48:59 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Tue, 30 Aug 2016 08:48:59 +0200 Subject: [bv-dev] Promote fail fast? In-Reply-To: References: Message-ID: Hi Marco, Thanks for bringing up this proposal. I think it'd be a good addition. Can you open a BVAL issue for it? A variation could be to not stop after the first failure but after the first n, with n being a configurable number. I can't see a compelling use case for this, though. Usually you just want a quick exit if an object is invalid, so a binary setting should do it. @Others, any thoughts from your side? Cheers, --Gunnar 2016-08-29 7:38 GMT+02:00 Marco Molteni : > Hi guys, > > What do you think about the 'promotion' of fail-fast (from hibernate > validator) to the BV API? > > I see frequently this 2 use cases (in the 9-5 projects) to support the > request ;) > > 1. batch: there are a lot of batch processes that have to validate the > input data (flat file -> bean -> validation) and return for each bean only > a technical error if at least one field is not valid ('input refused'). > When there are millions (e.g. payments transactions) of beans to validate > in a batch and 30-50 fields for each bean the fail-fast saves a lot of time > (and the night is never long enough for all the batches required) ;) > > 2. REST response: in the validation of REST services often when 2 systems > exchange data the answer in case of error is an HTTP 4xx without many > details. The fail-fast is a time and machine resources saving when your > application is accessed by (hundred of) thousand users through some > external web client (e.g. JS client). > > In the do-it-yourself implementations for the 2 uses cases at the first > error an IllegalArgumentException is thrown with the information of the > first error found. > > The full test of every field is very well suited for uses cases in which > there is a human to machine communication (e.g. web forms). > > If your opinion is positive I can do more investigations if needed. > > Cheers > > Marco > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/19de0114/attachment.html From emmanuel at hibernate.org Tue Aug 30 04:42:52 2016 From: emmanuel at hibernate.org (Emmanuel Bernard) Date: Tue, 30 Aug 2016 10:42:52 +0200 Subject: [bv-dev] Promote fail fast? In-Reply-To: References: Message-ID: <20160830084252.GM90254@hibernate.org> I don't think a n option would make sense. One that might make sense is to keep validating a failing field with the remaining constraints before stopping to at least have a comprehensive view of the failure especially when constraints are composed. Emmanuel On Tue 2016-08-30 8:48, Gunnar Morling wrote: > Hi Marco, > > Thanks for bringing up this proposal. I think it'd be a good addition. Can > you open a BVAL issue for it? > > A variation could be to not stop after the first failure but after the > first n, with n being a configurable number. I can't see a compelling use > case for this, though. Usually you just want a quick exit if an object is > invalid, so a binary setting should do it. > > @Others, any thoughts from your side? > > Cheers, > > --Gunnar > > > 2016-08-29 7:38 GMT+02:00 Marco Molteni : > > > Hi guys, > > > > What do you think about the 'promotion' of fail-fast (from hibernate > > validator) to the BV API? > > > > I see frequently this 2 use cases (in the 9-5 projects) to support the > > request ;) > > > > 1. batch: there are a lot of batch processes that have to validate the > > input data (flat file -> bean -> validation) and return for each bean only > > a technical error if at least one field is not valid ('input refused'). > > When there are millions (e.g. payments transactions) of beans to validate > > in a batch and 30-50 fields for each bean the fail-fast saves a lot of time > > (and the night is never long enough for all the batches required) ;) > > > > 2. REST response: in the validation of REST services often when 2 systems > > exchange data the answer in case of error is an HTTP 4xx without many > > details. The fail-fast is a time and machine resources saving when your > > application is accessed by (hundred of) thousand users through some > > external web client (e.g. JS client). > > > > In the do-it-yourself implementations for the 2 uses cases at the first > > error an IllegalArgumentException is thrown with the information of the > > first error found. > > > > The full test of every field is very well suited for uses cases in which > > there is a human to machine communication (e.g. web forms). > > > > If your opinion is positive I can do more investigations if needed. > > > > Cheers > > > > Marco > > > > _______________________________________________ > > beanvalidation-dev mailing list > > beanvalidation-dev at lists.jboss.org > > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev From gunnar at hibernate.org Tue Aug 30 08:34:03 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Tue, 30 Aug 2016 14:34:03 +0200 Subject: [bv-dev] Making built-in constraints repeatable Message-ID: Hi all, One of the things making life easier in Java 8 is repeatable annotations [1], for instance allowing to specify several @Pattern constraints, without the explicit usage of @Pattern.List. The transition is very smooth for BV built-in constraints, essentially we just need to mark them with @Repeatable, using the existing inner @List annotations as containers. Hence I didn't bother to create a separate proposal document but instead Guillaume and me have prepared changes for the API and the spec already. You can find the GitHub pull requests at [2] and [3], respectively. Speaking of changes to the API sources, we also increased the Java version to 8, bumped the project version to 2.0.0-SNAPSHOT and we've prepared a change for BVAL-486 [4] which is about not going through the provider resolver if a specific provider type is passed into bootstrapping via Validation#byProvider(). This was a tad inconvenient when e.g. explicitly bootstrapping the RI under OSGi, where you still had to provide a specific provider resolver. Please let me know if you have any concerns or other remarks on any of these by the end of the week. Silence will be taken as expression of agreement :) Cheers, --Gunnar [1] https://docs.oracle.com/javase/tutorial/java/annotations/repeating.html [2] https://github.com/beanvalidation/beanvalidation-api/pull/65 [3] https://github.com/beanvalidation/beanvalidation-spec/pull/111 [4] https://github.com/beanvalidation/beanvalidation-api/pull/66 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/5deb789c/attachment.html From gunnar at hibernate.org Tue Aug 30 08:39:33 2016 From: gunnar at hibernate.org (Gunnar Morling) Date: Tue, 30 Aug 2016 14:39:33 +0200 Subject: [bv-dev] Proposal for supporting new Java 8 date/time types In-Reply-To: References: Message-ID: Anyone with thoughts/input on supporting the JSR 310 types? 2016-08-25 12:10 GMT+02:00 Gunnar Morling : > Hi, > > I've pushed another proposal to the website [1], it's about adding > @Past/@Future support for the date/time types added in Java 8 (java.time.* > package, added by JSR 310). The proposal essentially standardizes the > proprietary support we had in HV, plus some additions. > > Please let me know what you think, especially on the questions towards the > end. Either put comments inline on the source on GitHub [2] or let's have a > discussion here. > > I haven't been using JSR 310 extensively myself, so any feedback by those > who have is more than welcome. > > Thanks, > > --Gunnar > > [1] http://beanvalidation.org/proposals/BVAL-496/ > [2] https://github.com/beanvalidation/beanvalidation. > org/blob/production/proposals/BVAL-496.adoc > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/7ff65dfe/attachment-0001.html From moltenma at gmail.com Tue Aug 30 16:41:05 2016 From: moltenma at gmail.com (Marco Molteni) Date: Tue, 30 Aug 2016 22:41:05 +0200 Subject: [bv-dev] Proposal for supporting new Java 8 date/time types In-Reply-To: References: Message-ID: Hi Gunnar, I agree with the implementation of @Past and @Future with the possibility to customize the TZ. The date can be provided by an external client (e.g. via web service) and it should be possible to validate it against the timezone of the external client (e.g. time of payment to a local branch) or the local server TZ (e.g. international transaction). Personally I don't see the need to add other types to the validation, they can be easily converted in other Java types (Month -> Integer etc.) or require specific use cases (e.g. HijraEra). Most of the uses cases that I see ask only the validation of a date (e.g. @Past date for an event, @Future date today for a payment) or (less frequently) date and time. Cheers On Tue, Aug 30, 2016 at 2:39 PM, Gunnar Morling wrote: > Anyone with thoughts/input on supporting the JSR 310 types? > > 2016-08-25 12:10 GMT+02:00 Gunnar Morling : > >> Hi, >> >> I've pushed another proposal to the website [1], it's about adding >> @Past/@Future support for the date/time types added in Java 8 (java.time.* >> package, added by JSR 310). The proposal essentially standardizes the >> proprietary support we had in HV, plus some additions. >> >> Please let me know what you think, especially on the questions towards >> the end. Either put comments inline on the source on GitHub [2] or let's >> have a discussion here. >> >> I haven't been using JSR 310 extensively myself, so any feedback by those >> who have is more than welcome. >> >> Thanks, >> >> --Gunnar >> >> [1] http://beanvalidation.org/proposals/BVAL-496/ >> [2] https://github.com/beanvalidation/beanvalidation.org/ >> blob/production/proposals/BVAL-496.adoc >> >> > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/20869982/attachment.html From moltenma at gmail.com Tue Aug 30 16:44:37 2016 From: moltenma at gmail.com (Marco Molteni) Date: Tue, 30 Aug 2016 22:44:37 +0200 Subject: [bv-dev] Making built-in constraints repeatable In-Reply-To: References: Message-ID: Explicit agreement from me :) Thanks guys On Tue, Aug 30, 2016 at 2:34 PM, Gunnar Morling wrote: > Hi all, > > One of the things making life easier in Java 8 is repeatable annotations > [1], for instance allowing to specify several @Pattern constraints, without > the explicit usage of @Pattern.List. > > The transition is very smooth for BV built-in constraints, essentially we > just need to mark them with @Repeatable, using the existing inner @List > annotations as containers. Hence I didn't bother to create a separate > proposal document but instead Guillaume and me have prepared changes for > the API and the spec already. You can find the GitHub pull requests at [2] > and [3], respectively. > > Speaking of changes to the API sources, we also increased the Java version > to 8, bumped the project version to 2.0.0-SNAPSHOT and we've prepared a > change for BVAL-486 [4] which is about not going through the provider > resolver if a specific provider type is passed into bootstrapping via > Validation#byProvider(). This was a tad inconvenient when e.g. explicitly > bootstrapping the RI under OSGi, where you still had to provide a specific > provider resolver. > > Please let me know if you have any concerns or other remarks on any of > these by the end of the week. Silence will be taken as expression of > agreement :) > > Cheers, > > --Gunnar > > [1] https://docs.oracle.com/javase/tutorial/java/ > annotations/repeating.html > [2] https://github.com/beanvalidation/beanvalidation-api/pull/65 > [3] https://github.com/beanvalidation/beanvalidation-spec/pull/111 > [4] https://github.com/beanvalidation/beanvalidation-api/pull/66 > > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/83f95fbb/attachment.html From moltenma at gmail.com Tue Aug 30 17:01:25 2016 From: moltenma at gmail.com (Marco Molteni) Date: Tue, 30 Aug 2016 23:01:25 +0200 Subject: [bv-dev] Promote fail fast? In-Reply-To: <20160830084252.GM90254@hibernate.org> References: <20160830084252.GM90254@hibernate.org> Message-ID: Hi Gunnar, I will open a BVAL issue. Interesting the n option, but I didn't find any concrete use case neither. As you said, usually the result expected is true or false. Cheers On Tue, Aug 30, 2016 at 10:42 AM, Emmanuel Bernard wrote: > I don't think a n option would make sense. > One that might make sense is to keep validating a failing field with the > remaining constraints before stopping to at least have a comprehensive > view of the failure especially when constraints are composed. > > Emmanuel > > On Tue 2016-08-30 8:48, Gunnar Morling wrote: > > Hi Marco, > > > > Thanks for bringing up this proposal. I think it'd be a good addition. > Can > > you open a BVAL issue for it? > > > > A variation could be to not stop after the first failure but after the > > first n, with n being a configurable number. I can't see a compelling use > > case for this, though. Usually you just want a quick exit if an object is > > invalid, so a binary setting should do it. > > > > @Others, any thoughts from your side? > > > > Cheers, > > > > --Gunnar > > > > > > 2016-08-29 7:38 GMT+02:00 Marco Molteni : > > > > > Hi guys, > > > > > > What do you think about the 'promotion' of fail-fast (from hibernate > > > validator) to the BV API? > > > > > > I see frequently this 2 use cases (in the 9-5 projects) to support the > > > request ;) > > > > > > 1. batch: there are a lot of batch processes that have to validate the > > > input data (flat file -> bean -> validation) and return for each bean > only > > > a technical error if at least one field is not valid ('input refused'). > > > When there are millions (e.g. payments transactions) of beans to > validate > > > in a batch and 30-50 fields for each bean the fail-fast saves a lot of > time > > > (and the night is never long enough for all the batches required) ;) > > > > > > 2. REST response: in the validation of REST services often when 2 > systems > > > exchange data the answer in case of error is an HTTP 4xx without many > > > details. The fail-fast is a time and machine resources saving when your > > > application is accessed by (hundred of) thousand users through some > > > external web client (e.g. JS client). > > > > > > In the do-it-yourself implementations for the 2 uses cases at the first > > > error an IllegalArgumentException is thrown with the information of the > > > first error found. > > > > > > The full test of every field is very well suited for uses cases in > which > > > there is a human to machine communication (e.g. web forms). > > > > > > If your opinion is positive I can do more investigations if needed. > > > > > > Cheers > > > > > > Marco > > > > > > _______________________________________________ > > > beanvalidation-dev mailing list > > > beanvalidation-dev at lists.jboss.org > > > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > > > > > _______________________________________________ > > beanvalidation-dev mailing list > > beanvalidation-dev at lists.jboss.org > > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > > _______________________________________________ > beanvalidation-dev mailing list > beanvalidation-dev at lists.jboss.org > https://lists.jboss.org/mailman/listinfo/beanvalidation-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.jboss.org/pipermail/beanvalidation-dev/attachments/20160830/a5d2db27/attachment.html