Knut Wannheden | 1 Feb 2007 09:46
Picon

Re: mutability in hivemind 2 registry construction api

Hi Achim,

On 1/25/07, Achim Hügen <achim.huegen <at> gmx.de> wrote:
> I agree that it is desirable to reduce mutability.
>
> Most of the collections returned from any definition
> class could be made immutable.
> A call to Collections.unmodifiableCollection() would solve this.
>
> Regarding the addXxx methods I find it very helpful to use
> the definition classes for construction and extension resolving.
> Otherwise one would need an additional structure that represents
> the assocations between extension points and extensions and which
> is used during construction for resolving and constraint checking.
> To my mind it feels like the most natural fit to add and retrieve
> the associated objects directly from their source.
>

When *defining* a module using Java code I agree that using the
addXxx() methods may feel more natural so it might make sense to have
those in implementation classes. But I don't agree with that this is
required for the extension resolving. You say that an additional
structure would be required. As I see it this additional structure is
already present, it's HiveMind internal counterpart to the definition
structure. I.e. the objects Module, ServicePoint, etc. created during
the registry construction. And that's also how it worked in HiveMind
1.

> These add methods are defined in the public interfaces.
> RegistryDefinition#addModule
(Continue reading)

Massimo Lusetti | 8 Feb 2007 15:23
Picon
Gravatar

Tapestr5 IoC object provider

I'll write codes inline.
As said this is rally all the needed code to be able to inject
HiveMind services in a Tapestry5 page/component/service, just add this
code to your module builder class and use the 'hivemind' prefix for
reaching your HiveMind services, it will just works.

    <at> Contribute("tapestry.ioc.MasterObjectProvider")
    public static void contributeHiveMindToMasterObjectProvider(
            MappedConfiguration<String, ObjectProvider> configuration,
             <at> InjectService("HiveMind")
            ObjectProvider hivemind)
    {
        configuration.add("hivemind", hivemind);
    }

    public static ObjectProvider buildHiveMind(Log log)
    {
        return new HiveMindObjectProvider(log);
    }

This is the HiveMindObjectProvider:

/**
 * This is Copyright Massimo Lusetti mlusetti <at> gmail.com
 * released under the BSD License.
 */
package it.datacode.t5app.services;

import org.apache.commons.logging.Log;
import org.apache.hivemind.ApplicationRuntimeException;
(Continue reading)

James Carman | 8 Feb 2007 17:02

Re: Tapestr5 IoC object provider

Does anyone have time to look into this?  Massimo wrote to the
Tapestry group saying that he has come up with a way to expose
HiveMind services to Tapestry5 IoC.  I don't know if this belongs as a
HiveMind subproject or a Tapestry one, but it's cool that there are
some folks out there who like HiveMind enough to make sure you can use
it with the new Tapestry container. :-)

On 2/8/07, Massimo Lusetti <mlusetti <at> gmail.com> wrote:
> I'll write codes inline.
> As said this is rally all the needed code to be able to inject
> HiveMind services in a Tapestry5 page/component/service, just add this
> code to your module builder class and use the 'hivemind' prefix for
> reaching your HiveMind services, it will just works.
>
>     <at> Contribute("tapestry.ioc.MasterObjectProvider")
>     public static void contributeHiveMindToMasterObjectProvider(
>             MappedConfiguration<String, ObjectProvider> configuration,
>              <at> InjectService("HiveMind")
>             ObjectProvider hivemind)
>     {
>         configuration.add("hivemind", hivemind);
>     }
>
>
>     public static ObjectProvider buildHiveMind(Log log)
>     {
>         return new HiveMindObjectProvider(log);
>     }
>
>
(Continue reading)

Achim Hügen | 9 Feb 2007 11:19
Picon
Picon

Re: mutability in hivemind 2 registry construction api

Knut,

Knut Wannheden schrieb:
> Hi Achim,
>
> On 1/25/07, Achim Hügen <achim.huegen <at> gmx.de> wrote:
>> I agree that it is desirable to reduce mutability.
>>
>> Most of the collections returned from any definition
>> class could be made immutable.
>> A call to Collections.unmodifiableCollection() would solve this.
>>
>> Regarding the addXxx methods I find it very helpful to use
>> the definition classes for construction and extension resolving.
>> Otherwise one would need an additional structure that represents
>> the assocations between extension points and extensions and which
>> is used during construction for resolving and constraint checking.
>> To my mind it feels like the most natural fit to add and retrieve
>> the associated objects directly from their source.
>>
>
> When *defining* a module using Java code I agree that using the
> addXxx() methods may feel more natural so it might make sense to have
> those in implementation classes. But I don't agree with that this is
> required for the extension resolving. You say that an additional
> structure would be required. As I see it this additional structure is
> already present, it's HiveMind internal counterpart to the definition
> structure. I.e. the objects Module, ServicePoint, etc. created during
> the registry construction. And that's also how it worked in HiveMind
The problem is that those objects are generic (and should stay generic)
(Continue reading)

Achim Hügen | 9 Feb 2007 16:24
Picon
Picon

Re: Version 1.1.1 jars & Ibiblio

That's what I have learned so far regarding this topic:

- obtain clover license and copy to ANT_HOME/lib
- install forrest 0.7 and set FORREST_HOME

- Change the version number in project.properties
- update src/documentation/content/xdocs/index.xml
  (e.g. "This documentation describes HiveMind 1.1 , which is currently 
in an late beta state.")
  (https://svn.apache.org/repos/private/committers/donated-licenses/clover/)
- run: ant dist
- run: ant dist-build
- sign the release files using GPG ?
- upload website and dist files to people.apache.org
- post announcement?

Is something missing?
Achim

James Carman schrieb:
> I like that idea, but we would probably have to make it a new release
> (which we need to do anyway), since it would contain different "bits".
> Maybe we should just cut 1.1.2 and get it out the door (we voted on
> it a long time ago if I remember correctly).  I just need to get some
> help with it, as I have never cut a release before.
>
> On 1/30/07, Marcus.Schulte <at> bmw.ch <Marcus.Schulte <at> bmw.ch> wrote:
>> +1
>>
>> I would really love to see this done.
(Continue reading)

Achim Hügen | 9 Feb 2007 16:46
Picon
Picon

Re: Version 1.1.1 jars & Ibiblio

Oops, the clover license link was misplaced:
(https://svn.apache.org/repos/private/committers/donated-licenses/clover/)

Achim

Achim Hügen schrieb:
> That's what I have learned so far regarding this topic:
>
> - obtain clover license and copy to ANT_HOME/lib
> - install forrest 0.7 and set FORREST_HOME
>
> - Change the version number in project.properties
> - update src/documentation/content/xdocs/index.xml
>  (e.g. "This documentation describes HiveMind 1.1 , which is currently 
> in an late beta state.")
>  (https://svn.apache.org/repos/private/committers/donated-licenses/clover/) 
>
> - run: ant dist
> - run: ant dist-build
> - sign the release files using GPG ?
> - upload website and dist files to people.apache.org
> - post announcement?
>
> Is something missing?
> Achim
>
> James Carman schrieb:
>> I like that idea, but we would probably have to make it a new release
>> (which we need to do anyway), since it would contain different "bits".
>> Maybe we should just cut 1.1.2 and get it out the door (we voted on
(Continue reading)

Massimo Lusetti | 9 Feb 2007 17:50
Picon
Gravatar

Re: Tapestr5 IoC object provider

On 2/8/07, James Carman <james <at> carmanconsulting.com> wrote:

> Does anyone have time to look into this?  Massimo wrote to the
> Tapestry group saying that he has come up with a way to expose
> HiveMind services to Tapestry5 IoC.  I don't know if this belongs as a
> HiveMind subproject or a Tapestry one, but it's cool that there are
> some folks out there who like HiveMind enough to make sure you can use
> it with the new Tapestry container. :-)

Actually i don't know if this belongs to hivemind or tapestry anyway i
decided to pack the whole as a maven2 project/jar, the produced jar
simply need to be dropped into classpath to be used, in a typical
hivemind way.

So if anyone is interested, as usual, drop me a note, and remember
this still alpha technology ;)

--

-- 
Massimo
http://meridio.blogspot.com

James Carman | 9 Feb 2007 18:01

Re: Tapestr5 IoC object provider

Ok, great!  If you want, we could probably put it out on Tapestry <at> JavaForge.

On 2/9/07, Massimo Lusetti <mlusetti <at> gmail.com> wrote:
> On 2/8/07, James Carman <james <at> carmanconsulting.com> wrote:
>
> > Does anyone have time to look into this?  Massimo wrote to the
> > Tapestry group saying that he has come up with a way to expose
> > HiveMind services to Tapestry5 IoC.  I don't know if this belongs as a
> > HiveMind subproject or a Tapestry one, but it's cool that there are
> > some folks out there who like HiveMind enough to make sure you can use
> > it with the new Tapestry container. :-)
>
> Actually i don't know if this belongs to hivemind or tapestry anyway i
> decided to pack the whole as a maven2 project/jar, the produced jar
> simply need to be dropped into classpath to be used, in a typical
> hivemind way.
>
> So if anyone is interested, as usual, drop me a note, and remember
> this still alpha technology ;)
>
> --
> Massimo
> http://meridio.blogspot.com
>
>

Massimo Lusetti | 9 Feb 2007 18:02
Picon
Gravatar

Re: Tapestr5 IoC object provider

On 2/9/07, James Carman <james <at> carmanconsulting.com> wrote:

> Ok, great!  If you want, we could probably put it out on Tapestry <at> JavaForge.

Yep, it would be nice.

--

-- 
Massimo
http://meridio.blogspot.com

James Carman | 9 Feb 2007 23:58

Re: Version 1.1.1 jars & Ibiblio

What about how to do it in Maven2?  I think we just call mvn assemble?

On 2/9/07, Achim Hügen <achim.huegen <at> gmx.de> wrote:
> Oops, the clover license link was misplaced:
> (https://svn.apache.org/repos/private/committers/donated-licenses/clover/)
>
> Achim
>
>
> Achim Hügen schrieb:
> > That's what I have learned so far regarding this topic:
> >
> > - obtain clover license and copy to ANT_HOME/lib
> > - install forrest 0.7 and set FORREST_HOME
> >
> > - Change the version number in project.properties
> > - update src/documentation/content/xdocs/index.xml
> >  (e.g. "This documentation describes HiveMind 1.1 , which is currently
> > in an late beta state.")
> >  (https://svn.apache.org/repos/private/committers/donated-licenses/clover/)
> >
> > - run: ant dist
> > - run: ant dist-build
> > - sign the release files using GPG ?
> > - upload website and dist files to people.apache.org
> > - post announcement?
> >
> > Is something missing?
> > Achim
> >
(Continue reading)


Gmane