Meeting today
by Steve Ebersole
I won't be able to make the irc meeting today
11 years
[OGM] RowKey vs. EntityKey
by Gunnar Morling
Hi,
This may be a noob question, but what is the difference between RowKey and
EntityKey in OGM?
Both seem to represent one row (by means of table name + key column names +
column values), albeit being implemented a bit differently. Could they be
merged into one class?
Thanks,
--Gunnar
11 years
[OGM] Supporting Cassandra
by Gunnar Morling
Hi,
There is a pull request for adding support for Cassandra to OGM [1] which
has been created quite a long time ago.
Does anyone have details about it, e.g. what would need to be done in order
to integrate it? I guess it will need some work due to recent changes in
OGM and we might also benefit from younger additions to Cassandra itself.
Also query support should be doable now.
I'd be interested in taking this over but first would like to make sure I
better understand what's the current status of this dialect.
Thanks,
--Gunnar
[1] https://github.com/hibernate/hibernate-ogm/pull/164
11 years
AnnotationBinder throws ArrayIndexOutOfBoundException
by Surendran D
Hello All,
I am implementing an Entity class as below
@Entity@Table(name=*"Employee"*)(a)IdClass(EmployeeEntityPK.*class*)*public
class *EmployeeEntity *extends *AbstractEntity {
//with no attributes only getter / setter
My AbstractEntity is a @MappedSuperClass with one @Id,@Column and other
@Columns defined
Also I have EmployeeEntityPK which has
@Id@Column(name = *"empId"*)*private *Integer *empId*;
When I deploy my application I get exception as
Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.RangeCheck(ArrayList.java:547) [rt.jar:1.6.0_17]
at java.util.ArrayList.get(ArrayList.java:322) [rt.jar:1.6.0_17]
at
org.hibernate.cfg.AnnotationBinder.getUniqueIdPropertyFromBaseClass(AnnotationBinder.java:2576)
at
org.hibernate.cfg.AnnotationBinder.isIdClassPkOfTheAssociatedEntity(AnnotationBinder.java:925)
at
org.hibernate.cfg.AnnotationBinder.mapAsIdClass(AnnotationBinder.java:824)
at org.hibernate.cfg.AnnotationBinder.bindClass(AnnotationBinder.java:671)
AnnotationBinder.getUniqueIdPropertyFromBaseClass has a check as follows
*if *( elementsToProcess.getIdPropertyCount() == 1 ) {
which checks if my Entity has only one ID attribute, if so then
getsUniqueId from base class.
In my case I dont have any ID attribute in my EmployeeEntity so the I get
ArrayIndexOutOfBoundException.
Ideally in getUniqueIdPropertyFromBaseClass, baseClassElements should be
processed from AbstractEntity. Why its processing elements from
EmployeeEntity? Is this expected behaviour
I have added my source code to
https://github.com/surendrand/hibernate-entity-mapping for further reference
11 years, 1 month
Thinking about Forge 2 plugins
by Emmanuel Bernard
We probably should think about what it would mean to help people get
started with our projects using Forge. The Eclipse integration looks
very impressive and very much how I wish I could work to add layers.
I'll add it to the team meeting agenda.
Emmanuel
Date: Mon, 21 Oct 2013 18:27:12 -0400 (EDT)
From: Lincoln Baxter <lbaxter(a)redhat.com>
To: The Core
Subject: The Forge 2 philosophy in 4 minutes
Check out the video describing Forge 2 and where we are headed:
http://www.youtube.com/watch?v=Dpou-FWWatI
Just a quick update on the Forge project. This video will show you what we've been working on for the past while: namely a new architecture to allow extreme embed-ability, and real code re-use between addons (using our Modular container, called Furnace) https://github.com/forge/furnace (based on JBoss Modules and Maven). It does not go into great detail into many of these things, but is more of a high-level overview of the goals and features.
So what does this mean for your project?
1) Primarily, this means that you'll be able to work with us to create tools for your project that run in all of our supported environments and IDEs. Ideally this tooling should be focused on getting users started with your projects quickly, so if you're interested in having a Forge plugin for your project, please send me an email off list, and we will get the process started. We are currently preparing for the launch of our new website, so it will probably still be a few months before we can do any intensive project addon development with teams.
2) What this means in reality is that you can deliver tools that will run in JBDS and the command-line (and eventually IntelliJ, and NetBeans, and Web IDE), without worrying about coordination with an actual product release. Your release cycle is completely independent of ours. (Unless you are waiting for a new feature that is not yet released.)
To learn more about Forge 2, please visit our github repository: https://github.com/forge/core#jboss-forge-20
Expect to hear more from us soon :) We want *YOU*... and your projects of course :)
--
Lincoln Baxter, III
JBoss, by Red Hat
lbaxter(a)redhat.com
"If you want something, you'll find a way; if you don't, you'll find an excuse."
11 years, 1 month
[OGM] Hibernate OGM @ Devoxx
by Guillaume SCHEIBEL
Hello,
After SoftShake (and few JUGs), I'm proud (and kind of exited) to announce
my Tool In Action titled "a hint of NoSQL into my Java EE" has been
approved.
See you there :)
Guillaume
11 years, 1 month
HHH-8670 another EntityManager.find() not returning null question
by Scott Marlow
HHH-8670 is about EntityManager.find() not returning null when a runtime
exception is caught when performing the find(). Returning null when a
ClassCastException (or any other runtime exception) occurs seems
confusing to me, but I suppose that we could log a DEBUG warning (like
we did for EntityNotFoundException).
Does anyone disagree with changing Hibernate ORM to return null when a
runtime exception is caught during the EntityManager.find() operation?
Scott
11 years, 1 month
[SEARCH] Result ignored if proxy isn't initialized
by Guillaume Smet
Hi,
We have a weird problem here with Search 4.3 and ORM 4.2.7.SP1. I
wonder if it rings a bell for anyone?
In yet to determined circumstances, an object is missing from the
search results.
This object is returned by the Lucene search but is not added in the
results because it isn't initialized.
In ObjectLoaderHelper.returnAlreadyLoadedObjectsInCorrectOrder(),
there is a test to check if the element is initialized before
including it in the results list.
The fact is that sometimes, the element is a Javassist proxy (we use
ehcache) and isn't initialized at all even if it exists in the
database. Thus it's not included in the results.
A few more comments:
- if we force the initialization with the IDE by inspecting the object
before the test, the element is included and everything works fine;
- if we use the SecondLevelCacheObjectsInitializer (by calling
fullTextQuery.initializeObjectsWith(ObjectLookupMethod.SECOND_LEVEL_CACHE,
DatabaseRetrievalMethod.QUERY);) instead of the Criteria one,
everything works fine too.
I'm wondering if this test is legit and if the assertion that the
object should be initialized here or doesn't exist in the database is
really true, especially when the object is cached and is a Javassist
proxy.
We have a workaround but I'm pretty sure there's a bug somewhere.
cc: Yoann which is working on the project where we met this bug today.
Thanks for your feedback.
--
Guillaume
11 years, 1 month