Updated this fix by failing if url is null with a message saying to either
change the scanner or add the file to exclusions.
Can anyone review it please before next release (2.0.18)?

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le sam. 13 juin 2020 à 12:01, Gurkan Erdogdu <cgurkanerdo...@gmail.com> a
écrit :

> >
> > This is wrong, what does make you think that? I know you left for a very
> > long time and missed quite a lot of things
>
> I have been following most of the mailing lists even if I am not able to
> contribute.
>
>
> but typically most of xbean is
> > not decided by these 3 people but was decided way earlier and we get like
> > 5-6 people interacting regularly intercommunities (thinking to ee but
> > osgi/karaf and standlaone too). Not huge but clearly not a one man
> project.
> >
> I am not just talking about something special to XBean. General
> observation.
>
> Side note here is that it is not the right list to discuss that and not the
> > right thread too probably (we shouldnt mix topics in threads IMHO).
>
> Thank you for the advice.
>
> I do not want to continue the discussion. You are always having to say
> something.
> Good luck to you on these projects even in OWB.
> Cheers
> Gurkan
>
>
> On Sat, Jun 13, 2020 at 12:39 PM Romain Manni-Bucau <rmannibu...@gmail.com
> >
> wrote:
>
> > Le sam. 13 juin 2020 à 10:54, Gurkan Erdogdu <cgurkanerdo...@gmail.com>
> a
> > écrit :
> >
> > > If you want to revert , you can...
> > > But Xbean method returns null and throwing NPE is not a good way to
> go...
> > >
> >
> > Contract makes it respected. If you run in another env you setup another
> > impl.
> > Side note being ignoring silently an error is worse IMO.
> >
> >
> >
> > > From my understanding looking to those projects and even OWB, most of
> the
> > > decisions in these projects are only decided by one or two
> > persons(probably
> > > internally) but not with the community, this is not the Apache way of
> > > managing projects.
> > >
> >
> > This is wrong, what does make you think that? I know you left for a very
> > long time and missed quite a lot of things but typically most of xbean is
> > not decided by these 3 people but was decided way earlier and we get like
> > 5-6 people interacting regularly intercommunities (thinking to ee but
> > osgi/karaf and standlaone too). Not huge but clearly not a one man
> project.
> >
> > Side note here is that it is not the right list to discuss that and not
> the
> > right thread too probably (we shouldnt mix topics in threads IMHO).
> >
> >
> > > It is impossible for me to contribute such projects which are handled
> > this
> > > way...
> > >
> > > Cheers
> > >
> > > Gurkan
> > >
> > > On 13 Jun 2020 Sat at 09:18 Romain Manni-Bucau <rmannibu...@gmail.com>
> > > wrote:
> > >
> > > > Don't want to look mad or bad but I personally have a hard time to
> > > convert
> > > > such statement to action Gurkan.
> > > > Basically most of this code is not that complex so self explanatory
> for
> > > me
> > > > - but also true I never read comments when contributing to project
> I'm
> > > not
> > > > committer in cause they generally brings you in a wrong direction
> IMHO.
> > > > Are you missing some architecture design doc maybe?
> > > >
> > > > Side note: back on this commit, if it is linked to the ticket I
> > > commented,
> > > > it should be reverted right?
> > > >
> > > > Romain Manni-Bucau
> > > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > > <https://rmannibucau.metawerx.net/> | Old Blog
> > > > <http://rmannibucau.wordpress.com> | Github <
> > > > https://github.com/rmannibucau> |
> > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> > > > <
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > >
> > > >
> > > >
> > > > Le ven. 12 juin 2020 à 21:45, Gurkan Erdogdu <
> cgurkanerdo...@gmail.com
> > >
> > > a
> > > > écrit :
> > > >
> > > > > Hi
> > > > > I am looking at projects in Apache Geronimo and OWB side such as
> > XBean,
> > > > > Meecrowave, Microprofile, Arthur etc. to contribute more.
> > > > > I have observed that most of the source code has very small code
> > > comments
> > > > > and most of them are driven by a very small group of contributors.
> > > > > It is really hard to contribute to these projects without some bit
> of
> > > > > understanding of the source code. The important key idea behind the
> > > > Apache
> > > > > Projects are community and projects need to be driven by the
> > community.
> > > > To
> > > > > extend the community around projects, we need to more care about
> the
> > > > > source codes, documentation, guides etc.
> > > > > I know that this type of stuff is time consuming but also
> important.
> > > > > I just want to share my observations around these very cool
> projects.
> > > > > Regards.
> > > > > Gurkan
> > > > >
> > > > >
> > > > >
> > > > > On Wed, Jun 10, 2020 at 9:58 AM Romain Manni-Bucau <
> > > > rmannibu...@gmail.com>
> > > > > wrote:
> > > > >
> > > > > > Hmm,
> > > > > >
> > > > > > Have to admit I always use maven to run TCK and I use Intellij so
> > not
> > > > > that
> > > > > > sure.
> > > > > > Maybe something you can give a try is to only open tck module and
> > > close
> > > > > > other modules to ensure eclipse m2 resolves it through the m2
> repo
> > > but
> > > > > > without any guarantee :s.
> > > > > >
> > > > > > Romain Manni-Bucau
> > > > > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > > > > <https://rmannibucau.metawerx.net/> | Old Blog
> > > > > > <http://rmannibucau.wordpress.com> | Github <
> > > > > > https://github.com/rmannibucau> |
> > > > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> > > > > > <
> > > > > >
> > > > >
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > > > >
> > > > > >
> > > > > >
> > > > > > Le mer. 10 juin 2020 à 08:38, Gurkan Erdogdu <
> > > cgurkanerdo...@gmail.com
> > > > >
> > > > > a
> > > > > > écrit :
> > > > > >
> > > > > > > Hi Romain
> > > > > > > I will look into geronimo-xbean.
> > > > > > > In the mean time, I have a question:
> > > > > > > I try to run TestNG plugin in Eclipse but because of javax ->
> > > jakarta
> > > > > > maven
> > > > > > > shading, I am not able to launch the tests via this plugin. It
> > > throws
> > > > > > > errors like
> > > > > > >
> > > > > > > INFO: CDI-TCK Specification version: null
> > > > > > > java.lang.NoClassDefFoundError: javax/el/ExpressionFactory
> > > > > > >
> > > > > > > Do you have any experience on this? I like to use this plugin
> to
> > > see
> > > > > > > visually the tests....
> > > > > > > Regards.
> > > > > > > Gurkan
> > > > > > >
> > > > > > >
> > > > > > > On Wed, Jun 10, 2020 at 9:09 AM Romain Manni-Bucau <
> > > > > > rmannibu...@gmail.com>
> > > > > > > wrote:
> > > > > > >
> > > > > > > > Hi Gurkan,
> > > > > > > >
> > > > > > > > Any way to test it and maybe harness it in geronimo xbean?
> > > > > > > > Typically it can only happen if the URL is wrongly formatted
> > > (means
> > > > > we
> > > > > > > > should port a fix in xbean too) or the protocol is not
> > supported
> > > > > > (likely
> > > > > > > > means a missing exclusion or new protocol handling in xbean).
> > > > > > > > I saw some issues with .so in the past in tests but never
> > managed
> > > > to
> > > > > > > > reproduce it  and I know jrt brings a new protocol but
> thought
> > we
> > > > > > > excluded
> > > > > > > > it by default so if can confirm this case and if you have a
> few
> > > > > > pointers
> > > > > > > it
> > > > > > > > would be great, I would be happy to do the work in xbean
> about
> > > it.
> > > > > > > >
> > > > > > > > Romain Manni-Bucau
> > > > > > > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > > > > > > <https://rmannibucau.metawerx.net/> | Old Blog
> > > > > > > > <http://rmannibucau.wordpress.com> | Github <
> > > > > > > > https://github.com/rmannibucau> |
> > > > > > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
> > > > > > > > <
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://www.packtpub.com/application-development/java-ee-8-high-performance
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > ---------- Forwarded message ---------
> > > > > > > > De : <gerdo...@apache.org>
> > > > > > > > Date: mer. 10 juin 2020 à 07:11
> > > > > > > > Subject: [openwebbeans] branch master updated: OWB-1328 NPE
> in
> > > > > > > > AbstractMetaDataFactory
> > > > > > > > To: comm...@openwebbeans.apache.org <
> > > > comm...@openwebbeans.apache.org
> > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > This is an automated email from the ASF dual-hosted git
> > > repository.
> > > > > > > >
> > > > > > > > gerdogdu pushed a commit to branch master
> > > > > > > > in repository
> > > https://gitbox.apache.org/repos/asf/openwebbeans.git
> > > > > > > >
> > > > > > > >
> > > > > > > > The following commit(s) were added to refs/heads/master by
> this
> > > > push:
> > > > > > > >      new b812c6f  OWB-1328 NPE in AbstractMetaDataFactory
> > > > > > > >      new ff4c809  Merge branch 'master' of
> > > > > > > > https://github.com/apache/openwebbeans
> > > > > > > > b812c6f <https://github.com/apache/openwebbeansb812c6f> is
> > > > described
> > > > > > > below
> > > > > > > >
> > > > > > > > commit b812c6ff7db69723d692efa1efd4dca00fd73c2a
> > > > > > > > Author: Gurkan Erdogdu <cgurkanerdo...@gmail.com>
> > > > > > > > AuthorDate: Wed Jun 10 08:10:54 2020 +0300
> > > > > > > >
> > > > > > > >     OWB-1328 NPE in AbstractMetaDataFactory
> > > > > > > > ---
> > > > > > > >  .../corespi/scanner/AbstractMetaDataDiscovery.java        |
> 15
> > > > > > > > ++++++++++-----
> > > > > > > >  1 file changed, 10 insertions(+), 5 deletions(-)
> > > > > > > >
> > > > > > > > diff --git
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> a/webbeans-impl/src/main/java/org/apache/webbeans/corespi/scanner/AbstractMetaDataDiscovery.java
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> b/webbeans-impl/src/main/java/org/apache/webbeans/corespi/scanner/AbstractMetaDataDiscovery.java
> > > > > > > > index 44febe9..c011670 100644
> > > > > > > > ---
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> a/webbeans-impl/src/main/java/org/apache/webbeans/corespi/scanner/AbstractMetaDataDiscovery.java
> > > > > > > > +++
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> b/webbeans-impl/src/main/java/org/apache/webbeans/corespi/scanner/AbstractMetaDataDiscovery.java
> > > > > > > > @@ -43,6 +43,8 @@ import org.apache.xbean.finder.util.Files;
> > > > > > > >
> > > > > > > >  import javax.decorator.Decorator;
> > > > > > > >  import javax.interceptor.Interceptor;
> > > > > > > > +
> > > > > > > > +import java.io.File;
> > > > > > > >  import java.io.IOException;
> > > > > > > >  import java.lang.annotation.Annotation;
> > > > > > > >  import java.net.URL;
> > > > > > > > @@ -283,11 +285,14 @@ public abstract class
> > > > AbstractMetaDataDiscovery
> > > > > > > > implements BdaScannerService
> > > > > > > >              else
> > > > > > > >              {
> > > > > > > >                  // we could check for
> > > > > > > > META-INF/maven/org.apache.geronimo.specs presence there but
> > this
> > > is
> > > > > > > faster
> > > > > > > > -                final String filename =
> > > > Files.toFile(url).getName();
> > > > > > > > -                if (filename.startsWith("geronimo-") &&
> > > > > > > > filename.contains("_spec"))
> > > > > > > > -                {
> > > > > > > > -                    it.remove();
> > > > > > > > -                }
> > > > > > > > +                File file = Files.toFile(url);
> > > > > > > > +                if(file!= null && file.exists()) {
> > > > > > > > +                    final String filename = file.getName();
> > > > > > > > +                    if (filename.startsWith("geronimo-") &&
> > > > > > > > filename.contains("_spec"))
> > > > > > > > +                    {
> > > > > > > > +                        it.remove();
> > > > > > > > +                    }
> > > > > > > > +                }
> > > > > > > >              }
> > > > > > > >          }
> > > > > > > >      }
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Gurkan Erdogdu
> > > > > > > http://gurkanerdogdu.blogspot.com
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Gurkan Erdogdu
> > > > > http://gurkanerdogdu.blogspot.com
> > > > >
> > > >
> > > --
> > > Gurkan Erdogdu
> > > http://gurkanerdogdu.blogspot.com
> > >
> >
>
>
> --
> Gurkan Erdogdu
> http://gurkanerdogdu.blogspot.com
>

Reply via email to