Hello André

2014-02-16 12:32 GMT+01:00 André Diermann <andre.dierm...@gmail.com>:

> Hello Benedikt,
>
> I investigated the AccessibleObjectsRegistry class. I found some potential
> improvements. I submitted by suggestions on how to improve those to Jira
> [1]. Since this is my first commit ever to ASF I am afraid I did something
> wrong. Please tell me, if I messed something up. O:)
>

No need to be afraid. It's hard to get a patch right on the first try.


>
> What do you think?
>

See my comments in JIRA.


>
> In addition to that I was also wondering if the static reference to the
> ConstructorsRegistry as well as the MethodsRegistry could be improved
> either. But I don't have a comprehensive overview of the component
> architecture so far... do you agree that this static stuff might be
> conflicting somehow?
>

This goes into the direction Paul has already commented. I'm pretty sure
the singleton design we currently have will cause trouble some time. So my
idea is the following:

The BeanUtils class should serve as an entry point into the API which
provides a preconfigured BeanUtils instance. That instance has a
preconfigured cache, some converters and the like. All the stuff that
BeanUtils 1 currently does. All that stuff get's initialized when the
BeanUtils class is loaded (in a static block).

If think that this will be good enough for 95% of the use cases. For the
rest we should create a nice API that let's you build up your custom
BeanUtils instance. This sounds like a job for the builder pattern [1]. We
have examples of how this could look like in cli [1] and graph [2].

Regards,
Benedikt

[1] http://en.wikipedia.org/wiki/Builder_pattern
[2] http://commons.apache.org/proper/commons-cli/apidocs/index.html
[3]
http://svn.apache.org/viewvc/commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/CommonsGraph.java?view=markup


>
> [1] https://issues.apache.org/jira/browse/SANDBOX-462
>
> Regards,
> André
>
>
> 2014-02-12 21:43 GMT+01:00 Benedikt Ritter <brit...@apache.org>:
>
> > Hell André
> >
> >
> > 2014-02-11 20:01 GMT+01:00 André Diermann <andre.dierm...@gmail.com>:
> >
> > > Hi Benedikt,
> > >
> > > many thanks for your kind introduction. :-) I also think jumping into
> the
> > > code will do most, that's where I start for now. What I have seen so
> far
> > > looks quite promising, especially the test coverage, hence it's maybe
> > hard
> > > for me to find big improvements. ...
> >
> >
> > You don't have to come up with major improvements to contribute. If there
> > is anything that catches your eyes, even if it just a local variable
> with a
> > bad name, don't hesitate to patch that. One area that really needs some
> > attention is the AccessibleObjectsRegistry. We copied it from the old
> > BeanUtils and the core there is really complicated. So maybe you find
> ways
> > to make that easier to understand.
> >
> >
> > > you mentioned a requirement for BU2 is
> > > to provide an equal set of features as the standard BU. I think
> searching
> > > for corresponding features gaps during my "exercise" might be
> beneficial
> > > somehow - or are they already captured somewhere?
> > >
> >
> > Currently those features are only captured in my head :-) You can use our
> > wiki [1] to document the stuff that has to go into BeanUtils or even
> better
> > create tickets in Jira.
> >
> > Regards,
> > Benedikt
> >
> > [1] http://wiki.apache.org/commons/FrontPage
> >
> >
> > >
> > > Thank you so far.
> > >
> > > Regards,
> > > André
> > >
> > >
> > > 2014-02-11 16:58 GMT+01:00 Benedikt Ritter <brit...@apache.org>:
> > >
> > > > Hello André,
> > > >
> > > > nice that you're interested in BU2, welcome to this list.
> > > >
> > > >
> > > > 2014-02-11 12:26 GMT+01:00 André Diermann <andre.dierm...@gmail.com
> >:
> > > >
> > > > > Hi,
> > > > >
> > > > > I stumbled upon the BeanUtils2 project which looks quite
> interessing
> > to
> > > > me.
> > > > > Do you have any future plans? (When) Will it replace the BeanUtils
> > > > > component?
> > > > >
> > > >
> > > > We don't have a fixed development schedule. We're all working on
> > projects
> > > > in our free time, so we release stuff, when "it's done". WRT
> > BeanUtils2,
> > > we
> > > > currently have a stable state in trunk, which implements a subset of
> > the
> > > > functionality provided by BeanUtils. BeanUtils2 should have all
> > > > capabilities of BeanUtils before it can be released as a replacement.
> > > I've
> > > > fought about releasing trunk as 0.1, but I feared the binary
> > > compatibility
> > > > discussions that this approach would lead to :-)
> > > >
> > > > So hear are the things that would have to go into BU2 before it can
> be
> > > > released as a replacement for BeanUtils:
> > > >
> > > > - evaluation of property paths: BeanUtils.setProperty(myBean,
> > > > "adress.street", "5th Ave");
> > > > - Conversation between data types
> > > > - The caching has to be reworked, because it relies on static fields
> > that
> > > > always cause trouble in multi class loader environments
> > > > - possibilities to configure custom BeanUtils instances
> > > >
> > > >
> > > > >
> > > > > I'm highly interested in contributing to this project. Please let
> me
> > > > know,
> > > > > if you plan to continue work on that project and how I might help
> > you.
> > > > >
> > > >
> > > > I'm working mainly on [lang], but I can review patches. Patches are
> > > > contributed through our JIRA. Just open an issue and attach a svn
> diff
> > > file
> > > > to it. Please make sure that you have filed an ICLA [1]. You should
> > also
> > > > read the material on our websites [2,3,4].
> > > >
> > > > If you really want to join development of BU2, I'd recommend that you
> > > have
> > > > a look at trunk and play around with it a bit. Is there something you
> > can
> > > > improve? Are there test cases missing? This are always good exercises
> > for
> > > > getting started.
> > > >
> > > > After that we should discuss the topics I've mentioned above.
> > > >
> > > > HTH,
> > > > Benedikt
> > > >
> > > > [1] http://www.apache.org/licenses/
> > > > [2] http://commons.apache.org/volunteering.html
> > > > [3] http://commons.apache.org/patches.html
> > > > [4] https://www.apache.org/foundation/how-it-works.html
> > > >
> > > >
> > > > >
> > > > > Thanks in advance.
> > > > >
> > > > > Regards,
> > > > > André
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > http://people.apache.org/~britter/
> > > > http://www.systemoutprintln.de/
> > > > http://twitter.com/BenediktRitter
> > > > http://github.com/britter
> > > >
> > >
> >
> >
> >
> > --
> > http://people.apache.org/~britter/
> > http://www.systemoutprintln.de/
> > http://twitter.com/BenediktRitter
> > http://github.com/britter
> >
>



-- 
http://people.apache.org/~britter/
http://www.systemoutprintln.de/
http://twitter.com/BenediktRitter
http://github.com/britter

Reply via email to