Modules for WildFly -> wrong Infinispan being injected?
by Sanne Grinovero
I'm attempting to update Hibernate Search to use the latest Infinispan
7.0.0.Alpha4.
One of the notable changes in this Infinispan version is that the class
org.infinispan.configuration.parsing.Parser60
was dropped, having now only a Parser70 implementation (which forces
you to rewrite all configuration files in a new format).
In my direct dependencies I'm listing exclusively Infinispan modules
having slot=7.0, so to load Infinispan dependencies from the custom
modules provided by the latest Infinispan tag.
Still I'm getting this exception when running our Arquillian integration tests:
Caused by: java.util.ServiceConfigurationError:
org.infinispan.configuration.parsing.ConfigurationParser: Provider
org.infinispan.configuration.parsing.Parser60 not a subtype
at java.util.ServiceLoader.fail(ServiceLoader.java:231) [rt.jar:1.7.0_51]
at java.util.ServiceLoader.access$300(ServiceLoader.java:181)
[rt.jar:1.7.0_51]
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:369)
[rt.jar:1.7.0_51]
at java.util.ServiceLoader$1.next(ServiceLoader.java:445) [rt.jar:1.7.0_51]
at org.infinispan.commons.util.ServiceFinder.addServices(ServiceFinder.java:60)
at org.infinispan.commons.util.ServiceFinder.load(ServiceFinder.java:42)
at org.infinispan.configuration.parsing.ParserRegistry.<init>(ParserRegistry.java:52)
at org.hibernate.search.infinispan.impl.InfinispanConfigurationParser.<init>(InfinispanConfigurationParser.java:37)
[hibernate-search-infinispan-5.0.0-SNAPSHOT.jar:5.0.0-SNAPSHOT]
at org.hibernate.search.infinispan.DefaultCacheManagerService.start(DefaultCacheManagerService.java:86)
[hibernate-search-infinispan-5.0.0-SNAPSHOT.jar:5.0.0-SNAPSHOT]
at org.hibernate.search.engine.service.impl.StandardServiceManager$ServiceWrapper.startService(StandardServiceManager.java:255)
[hibernate-search-engine-5.0.0-SNAPSHOT.jar:5.0.0-SNAPSHOT]
Parser60 is nowhere to be found across the dependencies I'm explicitly
listing; I'm guessing it's being injected on the classpath via the
dependency to Hibernate:main ?
Infinispan has similar integration tests for the modules, and this
wasn't catched there so I assume the difference of "being an Hibernate
application" could be something to explore.
I think this is probably not a new issue, but could have been hidden
previously: until previous Alpha releases of Infinispan a Parser60 was
actually being included, so I think in that case the explicit
dependency would have taken priority - by design or by luck. Also,
previous Infinispan releases had a less dramatic approach and would
include older parser implementations to keep backwards compatibility.
I'm confused at this point; I don't think it's expected for an
Hibernate user to get Infinispan classes on its classpath; I
understand Hibernate might need to load 2nd level cache, but this
should be an internal detail not exposed to modules consuming the ORM,
right?
I don't think I have ways to put exclusions in place, so I'm stuck;
hopefully I'm doing something wrong in my branch HSEARCH-1594 .. I'll
check again tomorrow but if someone is willing to have a look at what
I'm doing that would be great.
Sanne
9 years, 12 months
[Search] push-force on master
by Sanne Grinovero
Hi all,
I've just used a push --force on master of Hibernate Search, hopefully
no damage as I undid a commit of just 15 minutes.
Sorry for any trouble, teaching merge procedures ;)
9 years, 12 months
Re: [hibernate-dev] question on matrix testing
by Mahesh Gadgil
Didn't drop it on purpose. Sybase products, IQ and SQL Anywhere support the CURRENT_TIMESTAMP but ASE doesn't. I am not the person to answer the question of why. Would you recommend skipping this test for ASE or there is some workaround I am not aware of?
ThanksMahesh
Date: Wed, 14 May 2014 09:32:08 -0500
Subject: Re: [hibernate-dev] question on matrix testing
From: steve(a)hibernate.org
To: maheshgadgil(a)hotmail.com
Why do you keep dropping hibernate-dev from the recipients?
What I find odd is that Sybase does not support one of the few functions that the SQL spec explicitly names.
On Tue, May 13, 2014 at 2:00 PM, Mahesh Gadgil <maheshgadgil(a)hotmail.com> wrote:
On item 3.Current_timestamp is not supported on ASE. Here is what happens for that particular test.
16:32:56,424 ERROR SchemaExport:425 - HHH000389: Unsuccessful: create table T_ENT_GEN_DEF (id int not null, alwaysDate datetime default CURRENT_TIMESTAMP not null, createdDate datetime default CURRENT_TIMESTAMP not null, lastName varchar(255) null, name varchar(255) null, updated datetime null, vmCreatedCalendar datetime null, vmCreatedDate datetime null, vmCreatedSqlDate date null, vmCreatedSqlTime time null, vmCreatedSqlTimestamp datetime null, primary key (id)) lock datarows
16:32:56,424 ERROR SchemaExport:426 - The name 'CURRENT_TIMESTAMP' is illegal in this context. Only constants, constant expressions, or variables allowed here. Column names are illegal.
There are CURRENT_BIGTIME and CURRENT_BIGDATETIME functions but they need to be used with '()'. So this would work.create table T_ENT_GEN_DEF (id int not null, alwaysDate datetime default CURRENT_BIGTIME() not null ........
ThanksMahesh
Date: Tue, 13 May 2014 12:33:04 -0500
Subject: Re: [hibernate-dev] question on matrix testing
From: steve(a)hibernate.org
To: maheshgadgil(a)hotmail.com
CC: hibernate-dev(a)lists.jboss.org
On Tue, May 13, 2014 at 10:39 AM, Mahesh Gadgil <maheshgadgil(a)hotmail.com> wrote:
I am running hibernate tests on SAP SYBASE ASE database currently. I am looking to get advice on what the best solution is to these problems.I know some tests that could not be run on ASE, have been skipped using SkipForDialect annotation in the past.The issues I am listing are for the remaining tests.
1. Some tests like below create a "User" table, which is not allowed by ASE. This can be fixed (thanks Brett Meyer) by adding @Table annotation and renaming the table by adding and escaping double quotes as "\"User\"" and setting 'set quoted_identifier on' option on ASE. If this change makes into the source code, would this impact testing of other databases?
org.hibernate.test.cache.CollectionCacheEvictionTest
Yes, we should make this change upstream
2. Many tests like below create column names in smaller case but use names with uppercase in the sql that's generated. These tests fail on ASE because of its default setting of 'case sensitive'. This is easily fixed by setting ASE to ignore 'case' altogether. However I believe we need to be consistent with our naming conventions to avoid such problems. org.hibernate.test.annotations.entity.BasicHibernateAnnotationsTest ----- CATEGORY column
TBH I think that having case-sensitive (non-delimited) identifiers is silly. I don't plan on changing these in the tests. I'd expect you to alter the db to not use case-sensitive identifiers.
3. Some tests like below use defaults for datetime columns as CURRENT_TIMESTAMP. This needs to be replaced with getdate() for ASE. Is there a way, this can be made db independent or dynamic?
org.hibernate.test.generated.DefaultGeneratedValueTest
current_timestamp is one of the few functions explicitly called out for support in the SQL standard. SAP SYBASE ASE does not support that?
9 years, 12 months
Re: [hibernate-dev] [OGM] types and sequence generator in dialect package
by Emmanuel Bernard
adding the mailing list back.
Other datastores use the same approach as you so we need to eb
consistent
On Wed 2014-05-14 11:22, Davide D'Alto wrote:
> Neo4jSequenceGenerator and Neo4jTypeConverter were the result of some code
> that I've extracted from the dialect.
> Initially I didn't expect them to be used somewhere else outside the
> dialect.
>
> Sounds good to me to move them to a separate package.
>
>
> On Wed, May 14, 2014 at 8:08 AM, Emmanuel Bernard <emmanuel(a)hibernate.org>wrote:
>
> > It does not make a huge difference as these are in impl packages but I
> > wonder if somebody has a specific reasoning for putting types
> > (converters) and sequence generators inside the dialect package?
> >
> > Granted they are wired in the dialect but in practice they are used by
> > the code base at large. I think naturally I would ahve put them under
> >
> > o.h.o.datastore.somenosql.type / generator or idgenerator
> > _______________________________________________
> > hibernate-dev mailing list
> > hibernate-dev(a)lists.jboss.org
> > https://lists.jboss.org/mailman/listinfo/hibernate-dev
> >
9 years, 12 months
[OGM] types and sequence generator in dialect package
by Emmanuel Bernard
It does not make a huge difference as these are in impl packages but I
wonder if somebody has a specific reasoning for putting types
(converters) and sequence generators inside the dialect package?
Granted they are wired in the dialect but in practice they are used by
the code base at large. I think naturally I would ahve put them under
o.h.o.datastore.somenosql.type / generator or idgenerator
9 years, 12 months
question on matrix testing
by Mahesh Gadgil
I am running hibernate tests on SAP SYBASE ASE database currently. I am looking to get advice on what the best solution is to these problems.I know some tests that could not be run on ASE, have been skipped using SkipForDialect annotation in the past.The issues I am listing are for the remaining tests.
1. Some tests like below create a "User" table, which is not allowed by ASE. This can be fixed (thanks Brett Meyer) by adding @Table annotation and renaming the table by adding and escaping double quotes as "\"User\"" and setting 'set quoted_identifier on' option on ASE. If this change makes into the source code, would this impact testing of other databases?
org.hibernate.test.cache.CollectionCacheEvictionTest
2. Many tests like below create column names in smaller case but use names with uppercase in the sql that's generated. These tests fail on ASE because of its default setting of 'case sensitive'. This is easily fixed by setting ASE to ignore 'case' altogether. However I believe we need to be consistent with our naming conventions to avoid such problems. org.hibernate.test.annotations.entity.BasicHibernateAnnotationsTest ----- CATEGORY column
3. Some tests like below use defaults for datetime columns as CURRENT_TIMESTAMP. This needs to be replaced with getdate() for ASE. Is there a way, this can be made db independent or dynamic?
org.hibernate.test.generated.DefaultGeneratedValueTest
The changes I make to source code to fix these issues on my machine would be overwritten every time I refresh the code from repository. So, I was wondering if there is a solution that resolves these issues for ASE but not impact testing on other databases.
Thanks
Mahesh
10 years