[hibernate-dev] [OGM] Configuration parsing

Guillaume SCHEIBEL guillaume.scheibel at gmail.com
Tue Apr 23 06:27:43 EDT 2013


Hello,

I've just created a pull request:
https://github.com/hibernate/hibernate-ogm/pull/184


BTW, the jira is OGM-282 <https://hibernate.atlassian.net/browse/OGM-282>


Guillaume


2013/4/22 Guillaume SCHEIBEL <guillaume.scheibel at gmail.com>

> https://hibernate.atlassian.net/browse/OGM-282
>
>
> 2013/4/22 Guillaume SCHEIBEL <guillaume.scheibel at gmail.com>
>
>> I'm opening a Jira so we can track it easily
>>
>> Guillaume
>>
>>
>> 2013/4/22 Sanne Grinovero <sanne at hibernate.org>
>>
>>> Hi Guillaume,
>>> agreed, looks like a good idea! Feel free cleanup all the
>>> configuration code, we can discuss the details in the usual pull
>>> requests.
>>>
>>> Sanne
>>>
>>> On 19 April 2013 16:01, Guillaume SCHEIBEL <guillaume.scheibel at gmail.com>
>>> wrote:
>>> > Hello,
>>> >
>>> >
>>> > With the time we are implementing more and more configuration
>>> properties
>>> > (especially for the MongoDB module) which makes the *DatastoreProvider
>>> more
>>> > and more heavy. And some configuration checks (the port between 1 and
>>> 65535
>>> > for instance) are done several times instead being centralized at 1
>>> place.
>>> >
>>> > The other problem is because of the "all in the DatastoreProvider"
>>> > strategy, some configuration tests can only be done once the start()
>>> method
>>> > has been called and for a module like MongoDB, the start() method will
>>> try
>>> > to make a call and so the test takes ~30sec instead of being
>>> > almost instantaneous.
>>> >
>>> > My question is what do you think about pulling out the configuration
>>> part
>>> > of the datastoreprovider (which will basically only  be responsible of
>>> the
>>> > start() and stop()).
>>> > And put it into a configurationParser called from
>>> > OgmJdbcServicesInitiator.configure(). And the configuration will be
>>> > represented as an object (somehow like in ISPN) and this object will be
>>> > used by the datastoreprovider to retrieve the properties.
>>> >
>>> > I think it can help to improve both config readability and the test
>>> time.
>>> > Any thoughts ?
>>> >
>>> > Guillaume
>>> > _______________________________________________
>>> > hibernate-dev mailing list
>>> > hibernate-dev at lists.jboss.org
>>> > https://lists.jboss.org/mailman/listinfo/hibernate-dev
>>>
>>
>>
>


More information about the hibernate-dev mailing list