Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Basic Kundera-HBase Test Cases #153

Closed
ravindranathakila opened this Issue Dec 17, 2012 · 34 comments

Comments

Projects
None yet
3 participants

Since we were failing to narrow down issues pertaining to Kundera, we took a bold step of de-linking our entities as a separate Github project The entities have resided and worked on ilikeplaces.com for over 3 years without issues. For testing JPA however, we had to ensure minimal dependencies on libraries such as log4j, slf4j.

https://github.com/ravindranathakila/Hobbits

We ensured that these entities have no dependencies whatsoever, on external libraries. We had to do this to ensure proper compliance for testing.
We however, do have two other support libraries which are required for the project to build(also separate library independent projects, on Github)

https://github.com/ravindranathakila/Scribble
https://github.com/ravindranathakila/Reaver

Now, we plan on growing over this code to repetitively test Kundera and provide whatever assitence we can to make Kundera a success. So far, we've got passed the persistence of entities. However, there are certain issues we are encountering. We are, for example, unable to read data from HBase where the client hangs infinitely.

I will endorse this issue with test failures we encounter.

Collaborator

mevivs commented Dec 17, 2012

Hi,
Let me know, what is required from our side. We will definitely work to get this working.
Also, just to share, we have identified certain performance issues with Kundera hbase. Basically it is related to persistence mechanism with kundera. We are planning to refactor and get this resolved in 2.3.

Looking forward for such issues.

Cheers,
-Vivek

Great! Awaiting the refactored version!

I'm not sure these error messages are actionable. But I'm posting in case you notice why they are failing.

Kundera1


Test set: TestSuite

Tests run: 19, Failures: 10, Errors: 0, Skipped: 0, Time elapsed: 180.409 sec <<< FAILURE!
Human(ai.ilikeplaces.entities.Read) Time elapsed: 0.074 sec <<< FAILURE!
com.impetus.kundera.KunderaException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317)
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194)
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184)
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152)
at com.impetus.kundera.graph.Node.find(Node.java:499)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241)
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185)
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312)
at ai.ilikeplaces.entities.Read.Human(Read.java:25)
Caused by: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169)
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670)
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381)
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125)
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473)
... 38 more

HumansAlbum(ai.ilikeplaces.entities.Read) Time elapsed: 0.003 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansAlbum(Read.java:55)

HumansAuthentication(ai.ilikeplaces.entities.Read) Time elapsed: 0.017 sec <<< FAILURE!
com.impetus.kundera.KunderaException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317)
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194)
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184)
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278)
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184)
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152)
at com.impetus.kundera.graph.Node.find(Node.java:499)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241)
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185)
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312)
at ai.ilikeplaces.entities.Read.HumansAuthentication(Read.java:29)
Caused by: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169)
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670)
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381)
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125)
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473)
... 40 more

HumansIdentity(ai.ilikeplaces.entities.Read) Time elapsed: 0.007 sec <<< FAILURE!
com.impetus.kundera.persistence.EntityReaderException: javax.persistence.PersistenceException: java.lang.RuntimeException: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:88)
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59)
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120)
at com.impetus.kundera.graph.Node.find(Node.java:499)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241)
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185)
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312)
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34)
Caused by: javax.persistence.PersistenceException: java.lang.RuntimeException: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException
at com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:781)
at com.impetus.client.hbase.admin.HBaseDataHandler.readData(HBaseDataHandler.java:227)
at com.impetus.client.hbase.HBaseClient.find(HBaseClient.java:138)
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:74)
... 36 more
Caused by: java.lang.RuntimeException: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException
at com.impetus.client.hbase.admin.HBaseDataHandler.populateEntityFromHbaseData(HBaseDataHandler.java:643)
at com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:756)
... 39 more
Caused by: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException
at com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:121)
at com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:38)
at com.impetus.client.hbase.utils.HBaseUtils.fromBytes(HBaseUtils.java:187)
at com.impetus.client.hbase.admin.HBaseDataHandler.populateEntityFromHbaseData(HBaseDataHandler.java:627)
... 40 more
Caused by: java.lang.NullPointerException
at com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:111)
... 43 more

HumansNet(ai.ilikeplaces.entities.Read) Time elapsed: 0.03 sec <<< FAILURE!
com.impetus.kundera.KunderaException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317)
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194)
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184)
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278)
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184)
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152)
at com.impetus.kundera.graph.Node.find(Node.java:499)
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241)
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185)
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312)
at ai.ilikeplaces.entities.Read.HumansNet(Read.java:44)
Caused by: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355749936294.7e9a9893c00fd0dfc56ee9d18b4b044b. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}
at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423)
at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402)
at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068)
at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364)
at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246)
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169)
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670)
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381)
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125)
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884)
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473)
... 40 more

HumansNetPeople(ai.ilikeplaces.entities.Read) Time elapsed: 0.009 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansNetPeople(Read.java:40)

HumansPrivateLocation(ai.ilikeplaces.entities.Read) Time elapsed: 0.004 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPrivateLocation(Read.java:50)

HumansPrivatePhoto(ai.ilikeplaces.entities.Read) Time elapsed: 0.004 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPrivatePhoto(Read.java:60)

HumansPublicPhoto(ai.ilikeplaces.entities.Read) Time elapsed: 0.004 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPublicPhoto(Read.java:65)

HumansWall(ai.ilikeplaces.entities.Read) Time elapsed: 0.007 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansWall(Read.java:70)

Collaborator

mevivs commented Dec 17, 2012

https://github.com/impetus-opensource/kundera-hbase-performance : This is where are building perf code.

Collaborator

mevivs commented Dec 17, 2012

As per Error,

Looks like for HumansPrivatePhoto entity column family "humanId" is missing.
Could you please point to "HumansPrivatePhoto" entity definition?

As per current implementation, Kundera expects Column family for each column name(This is where perf hit is).
Do you have ddl.auto.prepare => create in persistence.xml?

I always love to hear of refactoring! It always means code improvement and be-humbled code reviews that led to the decision.

Today, I was reading on Hibernate OGM. Maybe you can learn a bit from what they've found:

http://www.hibernate.org/subprojects/ogm.html

http://www.slideshare.net/openblend/openblend-2011sannegrinoveroogm

http://docs.jboss.org/hibernate/ogm/3.0/reference/en-US/html_single/#ogm-architecture-datapersisted

I have struggled almost for 6 months now to get JPA to work with HBase, so I'd be more than glad to help you guys out in case you need any assistance.

BTW, you should get JetBrains to give you an IntelliJ open source license if you are going for a major refactor. Will save you weeks of misery. If you're coming from eclipse, you can set your shortcuts to fit eclipse ones.

That would be here: https://github.com/ravindranathakila/Hobbits/blob/master/Java/src/main/java/ai/ilikeplaces/entities/HumansPrivatePhoto.java


package ai.ilikeplaces.entities;

import ai.ilikeplaces.entities.etc.EntityLifeCycleListener;
import ai.ilikeplaces.entities.etc.HumanIdFace;
import ai.scribble.License;

import javax.persistence.*;
import java.io.Serializable;
import java.util.List;

/**
 * @author Ravindranath Akila
 */

@License(content = "This code is licensed under GNU AFFERO GENERAL PUBLIC LICENSE Version 3")
@Table(name = "HumansPrivatePhoto", schema = "KunderaKeyspace@ilpMainSchema")
@Entity
@EntityListeners({EntityLifeCycleListener.class})
public class HumansPrivatePhoto implements HumanIdFace, Serializable {
// ------------------------------ FIELDS ------------------------------

    private static final long serialVersionUID = 1L;

    @Id
    @Column(name = "humanId")
    public String humanId;
    public static final String humanIdCOL = "humanId";

    @OneToOne(mappedBy = Human.humansPrivatePhotoCOL, cascade = CascadeType.REFRESH)
    //@PrimaryKeyJoinColumn
    public Human human;

    @OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.MERGE)
    @JoinColumn(name = humanIdCOL)
    public List<PrivatePhoto> privatePhotos;

// --------------------- GETTER / SETTER METHODS ---------------------

    public Human getHuman() {
        return human;
    }

    public void setHuman(final Human human) {
        this.human = human;
    }

    public String getHumanId() {
        return humanId;
    }

    public void setHumanId(final String humanId__) {
        this.humanId = humanId__;
    }

    public List<PrivatePhoto> getPrivatePhotos() {
        return privatePhotos;
    }

    public void setPrivatePhotos(List<PrivatePhoto> privatePhotos) {
        this.privatePhotos = privatePhotos;
    }


}

I'm using @OnetoOne mappings assuming @primarykeyjoincolumn won't work. However, I was unable to verify if support for @primarykeyjoincolumn is there. Is it supported?

Also, I wonder why, after creating the tables ground up, Kundera went for a new table creation round again. See these logs(persistence.xml pasted after):

2012-12-17 21:09:24,355 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansAuthorization
2012-12-17 21:09:25,453 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansAuthentication
2012-12-17 21:09:26,485 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Url
2012-12-17 21:09:27,511 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table tribeMemberstribes
2012-12-17 21:09:28,542 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Tribe
2012-12-17 21:09:29,704 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table PublicPhoto
2012-12-17 21:09:30,735 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansPublicPhoto
2012-12-17 21:09:31,770 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Msg
2012-12-17 21:09:32,803 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansPrivateLocation
2012-12-17 21:09:33,835 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansIdentity
2012-12-17 21:09:34,874 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Human
2012-12-17 21:09:35,907 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table PrivateEvent
2012-12-17 21:09:36,945 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table LongMsg
2012-12-17 21:09:37,979 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Location
2012-12-17 21:09:39,019 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Mute
2012-12-17 21:09:40,052 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Wall
2012-12-17 21:09:41,085 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansPrivateEvent
2012-12-17 21:09:42,122 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansNetPeople
2012-12-17 21:09:43,154 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateLocationViewersprivateLocationsViewed
2012-12-17 21:09:44,181 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateLocationOwnersprivateLocationsOwned
2012-12-17 21:09:45,213 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table PrivateLocation
2012-12-17 21:09:46,247 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansAlbum
2012-12-17 21:09:47,279 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Album
2012-12-17 21:09:48,329 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansTribe
2012-12-17 21:09:49,361 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansNet
2012-12-17 21:09:50,401 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table albumsalbumPhotos
2012-12-17 21:09:51,433 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table PrivatePhoto
2012-12-17 21:09:52,464 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansWall
2012-12-17 21:09:53,499 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table Map
2012-12-17 21:09:54,535 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateEventViewersprivateEventsViewed
2012-12-17 21:09:55,571 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateEventOwnersprivateEventsOwned
2012-12-17 21:09:56,608 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateEventRejectsprivateEventsRejected
2012-12-17 21:09:57,639 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table privateEventInvitesprivateEventsInvited
2012-12-17 21:09:58,676 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansPrivatePhoto
2012-12-17 21:09:59,723 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansUnseen
2012-12-17 21:10:00,749 [INFO ] [main] com.impetus.kundera.persistence.EntityManagerFactoryImpl  - EntityManagerFactory created for persistence unit : ilpMainSchema
2012-12-17 21:10:00,787 [INFO ] [main] com.impetus.kundera.KunderaPersistence  - Loading Application MetaData and Initializing Client(s) For Persistence Unit(s) ilpMainSchema
2012-12-17 21:10:00,788 [INFO ] [main] com.impetus.kundera.configure.PersistenceUnitConfiguration  - Loading Metadata from persistence.xml ...
2012-12-17 21:10:00,809 [WARN ] [main] com.impetus.kundera.loader.PersistenceXMLLoader  - Warning parsing XML: XML InputStream(-1) SchemaLocation: schemaLocation value = 'https://raw.github.com/impetus-opensource/Kundera/Kundera-2.0.4/kundera-core/src/test/resources/META-INF/persistence_2_0.xsd' must have even number of URI's.
2012-12-17 21:10:00,809 [ERROR] [main] com.impetus.kundera.loader.PersistenceXMLLoader  - Error parsing XML: XML InputStream(-1) cvc-complex-type.4: Attribute 'version' must appear on element 'persistence'.
2012-12-17 21:10:00,814 [INFO ] [main] com.impetus.kundera.configure.PersistenceUnitConfiguration  - Finishing persistence unit metadata configuration ...
2012-12-17 21:10:00,814 [INFO ] [main] com.impetus.kundera.configure.ClientFactoryConfiguraton  - Loading Client(s) For Persistence Unit(s) ilpMainSchema
2012-12-17 21:10:00,814 [INFO ] [main] com.impetus.kundera.loader.GenericClientFactory  - Loading client metadata for persistence unit : ilpMainSchema
2012-12-17 21:10:00,814 [INFO ] [main] com.impetus.kundera.loader.GenericClientFactory  - Initializing client for persistence unit : ilpMainSchema
2012-12-17 21:10:00,814 [WARN ] [main] com.impetus.client.hbase.config.HBasePropertyReader  - No property file found in class path, kundera will use default property
2012-12-17 21:10:00,870 [WARN ] [main] org.apache.hadoop.hbase.HBaseConfiguration  - instantiating HBaseConfiguration() is deprecated. Please use HBaseConfiguration#create() to construct a plain Configuration
2012-12-17 21:10:00,870 [INFO ] [main] com.impetus.kundera.loader.GenericClientFactory  - Constructing pool for persistence unit : ilpMainSchema
2012-12-17 21:10:00,871 [INFO ] [main] com.impetus.kundera.configure.SchemaConfiguration  - Configuring schema export for: ilpMainSchema
2012-12-17 21:10:00,921 [WARN ] [main] org.apache.hadoop.hbase.HBaseConfiguration  - instantiating HBaseConfiguration() is deprecated. Please use HBaseConfiguration#create() to construct a plain Configuration
2012-12-17 21:10:01,003 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAuthorization
2012-12-17 21:10:02,027 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAuthorization
2012-12-17 21:10:02,061 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthorization
2012-12-17 21:10:03,106 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAuthentication
2012-12-17 21:10:05,111 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAuthentication
2012-12-17 21:10:06,143 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthentication
2012-12-17 21:10:07,194 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Url
2012-12-17 21:10:09,200 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Url
2012-12-17 21:10:10,226 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Url
2012-12-17 21:10:11,269 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of tribeMemberstribes
2012-12-17 21:10:13,274 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled tribeMemberstribes
2012-12-17 21:10:14,299 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted tribeMemberstribes
2012-12-17 21:10:15,330 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Tribe
2012-12-17 21:10:17,337 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Tribe
2012-12-17 21:10:18,363 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Tribe
2012-12-17 21:10:19,398 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of PublicPhoto
2012-12-17 21:10:21,404 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled PublicPhoto
2012-12-17 21:10:22,425 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted PublicPhoto
2012-12-17 21:10:23,465 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansPublicPhoto
2012-12-17 21:10:25,470 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansPublicPhoto
2012-12-17 21:10:26,494 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansPublicPhoto
2012-12-17 21:10:27,538 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Msg
2012-12-17 21:10:29,543 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Msg
2012-12-17 21:10:30,566 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Msg
2012-12-17 21:10:31,604 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansPrivateLocation
2012-12-17 21:10:33,610 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansPrivateLocation
2012-12-17 21:10:34,638 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansPrivateLocation
2012-12-17 21:10:35,678 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansIdentity
2012-12-17 21:10:37,684 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansIdentity
2012-12-17 21:10:38,712 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansIdentity
2012-12-17 21:10:39,749 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Human
2012-12-17 21:10:41,754 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Human
2012-12-17 21:10:42,776 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Human
2012-12-17 21:10:43,816 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of PrivateEvent
2012-12-17 21:10:45,821 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled PrivateEvent
2012-12-17 21:10:46,843 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted PrivateEvent
2012-12-17 21:10:47,889 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of LongMsg
2012-12-17 21:10:49,894 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled LongMsg
2012-12-17 21:10:50,919 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted LongMsg
2012-12-17 21:10:51,956 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Location
2012-12-17 21:10:53,961 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Location
2012-12-17 21:10:54,982 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Location
2012-12-17 21:10:56,035 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Mute
2012-12-17 21:10:58,041 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Mute
2012-12-17 21:10:59,070 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Mute
2012-12-17 21:11:00,112 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Wall
2012-12-17 21:11:02,117 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Wall
2012-12-17 21:11:03,139 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Wall
2012-12-17 21:11:04,181 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansPrivateEvent
2012-12-17 21:11:06,187 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansPrivateEvent
2012-12-17 21:11:07,208 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansPrivateEvent
2012-12-17 21:11:08,245 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansNetPeople
2012-12-17 21:11:10,249 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansNetPeople
2012-12-17 21:11:11,270 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansNetPeople
2012-12-17 21:11:12,308 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateLocationViewersprivateLocationsViewed
2012-12-17 21:11:14,313 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateLocationViewersprivateLocationsViewed
2012-12-17 21:11:15,338 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateLocationViewersprivateLocationsViewed
2012-12-17 21:11:16,374 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateLocationOwnersprivateLocationsOwned
2012-12-17 21:11:18,379 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateLocationOwnersprivateLocationsOwned
2012-12-17 21:11:19,399 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateLocationOwnersprivateLocationsOwned
2012-12-17 21:11:20,429 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of PrivateLocation
2012-12-17 21:11:22,433 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled PrivateLocation
2012-12-17 21:11:23,454 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted PrivateLocation
2012-12-17 21:11:24,489 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAlbum
2012-12-17 21:11:26,493 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAlbum
2012-12-17 21:11:27,515 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAlbum
2012-12-17 21:11:28,562 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Album
2012-12-17 21:11:30,568 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Album
2012-12-17 21:11:31,593 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Album
2012-12-17 21:11:32,628 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansTribe
2012-12-17 21:11:34,633 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansTribe
2012-12-17 21:11:35,657 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansTribe
2012-12-17 21:11:36,695 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansNet
2012-12-17 21:11:38,699 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansNet
2012-12-17 21:11:39,722 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansNet
2012-12-17 21:11:40,759 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of albumsalbumPhotos
2012-12-17 21:11:42,765 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled albumsalbumPhotos
2012-12-17 21:11:43,787 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted albumsalbumPhotos
2012-12-17 21:11:44,824 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of PrivatePhoto
2012-12-17 21:11:46,829 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled PrivatePhoto
2012-12-17 21:11:47,849 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted PrivatePhoto
2012-12-17 21:11:48,890 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansWall
2012-12-17 21:11:50,895 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansWall
2012-12-17 21:11:51,920 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansWall
2012-12-17 21:11:52,960 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of Map
2012-12-17 21:11:54,964 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled Map
2012-12-17 21:11:55,988 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted Map
2012-12-17 21:11:57,024 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateEventViewersprivateEventsViewed
2012-12-17 21:11:59,029 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateEventViewersprivateEventsViewed
2012-12-17 21:12:00,051 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateEventViewersprivateEventsViewed
2012-12-17 21:12:01,082 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateEventOwnersprivateEventsOwned
2012-12-17 21:12:03,085 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateEventOwnersprivateEventsOwned
2012-12-17 21:12:04,107 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateEventOwnersprivateEventsOwned
2012-12-17 21:12:05,140 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateEventRejectsprivateEventsRejected
2012-12-17 21:12:07,144 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateEventRejectsprivateEventsRejected
2012-12-17 21:12:08,165 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateEventRejectsprivateEventsRejected
2012-12-17 21:12:09,203 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of privateEventInvitesprivateEventsInvited
2012-12-17 21:12:11,208 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled privateEventInvitesprivateEventsInvited
2012-12-17 21:12:12,229 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted privateEventInvitesprivateEventsInvited
2012-12-17 21:12:13,262 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansPrivatePhoto
2012-12-17 21:12:15,267 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansPrivatePhoto
2012-12-17 21:12:16,293 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansPrivatePhoto
2012-12-17 21:12:17,328 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansUnseen
2012-12-17 21:12:19,334 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansUnseen
2012-12-17 21:12:20,356 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansUnseen

persistence.xml

<?xml version="1.0" encoding="UTF-8" ?>
<persistence xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
             xsi:schemaLocation="https://raw.github.com/impetus-opensource/Kundera/Kundera-2.0.4/kundera-core/src/test/resources/META-INF/persistence_2_0.xsd"
             xmlns="http://java.sun.com/xml/ns/persistence">
    <persistence-unit name="ilpMainSchema" transaction-type="RESOURCE_LOCAL">
        <provider>com.impetus.kundera.KunderaPersistence</provider>
        <class>ai.ilikeplaces.entities.HumansAuthorization</class>
        <class>ai.ilikeplaces.entities.Wall</class>
        <class>ai.ilikeplaces.entities.PrivateEvent</class>
        <class>ai.ilikeplaces.entities.Map</class>
        <class>ai.ilikeplaces.entities.PrivatePhoto</class>
        <class>ai.ilikeplaces.entities.HumansAuthentication</class>
        <class>ai.ilikeplaces.entities.HumansPrivateEvent</class>
        <class>ai.ilikeplaces.entities.Mute</class>
        <class>ai.ilikeplaces.entities.Url</class>
        <class>ai.ilikeplaces.entities.HumansPrivateLocation</class>
        <class>ai.ilikeplaces.entities.PublicPhoto</class>
        <class>ai.ilikeplaces.entities.HumansNet</class>
        <class>ai.ilikeplaces.entities.Msg</class>
        <class>ai.ilikeplaces.entities.Human</class>
        <class>ai.ilikeplaces.entities.HumansTribe</class>
        <class>ai.ilikeplaces.entities.HumansNetPeople</class>
        <class>ai.ilikeplaces.entities.Tribe</class>
        <class>ai.ilikeplaces.entities.HumansWall</class>
        <class>ai.ilikeplaces.entities.Album</class>
        <class>ai.ilikeplaces.entities.PrivateLocation</class>
        <class>ai.ilikeplaces.entities.HumansIdentity</class>
        <class>ai.ilikeplaces.entities.HumansPrivatePhoto</class>
        <class>ai.ilikeplaces.entities.HumansAlbum</class>
        <class>ai.ilikeplaces.entities.LongMsg</class>
        <class>ai.ilikeplaces.entities.Location</class>
        <class>ai.ilikeplaces.entities.HumansPublicPhoto</class>
        <class>ai.ilikeplaces.entities.HumansUnseen</class>
        <exclude-unlisted-classes>true</exclude-unlisted-classes>
        <properties>
            <property name="kundera.nodes" value="localhost"/>
            <property name="kundera.port" value="60000"/>
            <property name="kundera.keyspace" value="KunderaKeyspace"/>
            <property name="kundera.dialect" value="hbase"/>
            <property name="kundera.client.lookup.class" value="com.impetus.client.hbase.HBaseClientFactory"/>
            <property name="kundera.cache.provider.class" value="com.impetus.kundera.cache.ehcache.EhCacheProvider"/>
            <property name="kundera.cache.config.resource" value="/ehcache-test.xml"/>
            <!--<property name="kundera.ddl.auto.prepare" value="validate"/>-->
            <property name="kundera.ddl.auto.prepare" value="create"/>
        </properties>
    </persistence-unit>
</persistence>

Before posting these test cases, I looked all over to see if I can download either JPA 1.0 or JPA 2.0 TCK, but found none. I guess our own test cases are all we've got! 👎

So to sum up the @column(name="<REQUIRED_NAME>") should be on all columns including primary key? How about fields defining relationships 1-1, 1-n, n-n ? Do they require the column names too? We can document this if so.

Collaborator

mevivs commented Dec 17, 2012

First to get this working,
Can you try to replace:

 @Id
    @Column(name = "humanId")
    public String humanId;

with

 @Id
    public String humanId;

?

Sure... give me 10 mins..

Collaborator

mevivs commented Dec 17, 2012

For Table creation, i cannot see another round of table creation.

For logs:

2012-12-17 21:10:00,921 [WARN ] [main] org.apache.hadoop.hbase.HBaseConfiguration  - instantiating HBaseConfiguration() is deprecated. Please use HBaseConfiguration#create() to construct a plain Configuration
2012-12-17 21:10:01,003 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAuthorization
2012-12-17 21:10:02,027 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAuthorization
2012-12-17 21:10:02,061 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthorization
2012-12-17 21:10:03,106 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAuthentication
2012-12-17 21:10:05,111 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAuthentication
2012-12-17 21:10:06,143 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthentication

This is basically clean up, not table creation. So might be in test cases table is getting deleted and that's why another round of creation is seen in logs!

You mean entries like

2012-12-17 21:10:06,143 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthentication

is not deleting the tables?

No, the test cases purely save or read. That's it.

As above:

2012-12-17 21:09:24,355 [INFO ] [main] com.impetus.client.hbase.schemamanager.HBaseSchemaManager  - creating table HumansAuthorization

and then seeing again in logs:

2012-12-17 21:10:01,003 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Started disable of HumansAuthorization
2012-12-17 21:10:02,027 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Disabled HumansAuthorization
2012-12-17 21:10:02,061 [INFO ] [main] org.apache.hadoop.hbase.client.HBaseAdmin  - Deleted HumansAuthorization

is not two rounds? if so I'm sorry. I've misunderstood the logs

Upon re-running the tests:

Kundera2

KunderaTests

ai.ilikeplaces.entities.Read:Human

org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.Human(Read.java:25) 
30 lines not shown
Caused by org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) 
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) 
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:513) 
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169) 
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670) 
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381) 
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125) 
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884) 
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.Human(Read.java:25) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansAlbum

null

ai.ilikeplaces.entities.Read.HumansAlbum(Read.java:55) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansAuthentication

org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansAuthentication(Read.java:29) 
30 lines not shown
Caused by org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) 
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) 
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:513) 
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169) 
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670) 
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381) 
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125) 
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884) 
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansAuthentication(Read.java:29) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansIdentity

javax.persistence.PersistenceException: java.lang.RuntimeException: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException

com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:88) 
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34) 
30 lines not shown
Caused by java.lang.RuntimeException: com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException

com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:781) 
at com.impetus.client.hbase.admin.HBaseDataHandler.readData(HBaseDataHandler.java:227) 
at com.impetus.client.hbase.HBaseClient.find(HBaseClient.java:138) 
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:74) 
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34) 
30 lines not shown
Caused by com.impetus.kundera.property.PropertyAccessException: java.lang.NullPointerException

com.impetus.client.hbase.admin.HBaseDataHandler.populateEntityFromHbaseData(HBaseDataHandler.java:643) 
at com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:756) 
at com.impetus.client.hbase.admin.HBaseDataHandler.readData(HBaseDataHandler.java:227) 
at com.impetus.client.hbase.HBaseClient.find(HBaseClient.java:138) 
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:74) 
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34) 
30 lines not shown
Caused by java.lang.NullPointerException

com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:121) 
at com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:38) 
at com.impetus.client.hbase.utils.HBaseUtils.fromBytes(HBaseUtils.java:187) 
at com.impetus.client.hbase.admin.HBaseDataHandler.populateEntityFromHbaseData(HBaseDataHandler.java:627) 
at com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:756) 
at com.impetus.client.hbase.admin.HBaseDataHandler.readData(HBaseDataHandler.java:227) 
at com.impetus.client.hbase.HBaseClient.find(HBaseClient.java:138) 
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:74) 
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34) 
30 lines not shown
Caused by null

com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:111) 
at com.impetus.kundera.property.accessor.DateAccessor.fromBytes(DateAccessor.java:38) 
at com.impetus.client.hbase.utils.HBaseUtils.fromBytes(HBaseUtils.java:187) 
at com.impetus.client.hbase.admin.HBaseDataHandler.populateEntityFromHbaseData(HBaseDataHandler.java:627) 
at com.impetus.client.hbase.admin.HBaseDataHandler.onRead(HBaseDataHandler.java:756) 
at com.impetus.client.hbase.admin.HBaseDataHandler.readData(HBaseDataHandler.java:227) 
at com.impetus.client.hbase.HBaseClient.find(HBaseClient.java:138) 
at com.impetus.kundera.persistence.AbstractEntityReader.findById(AbstractEntityReader.java:74) 
at com.impetus.client.hbase.HBaseEntityReader.findById(HBaseEntityReader.java:59) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:120) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansIdentity(Read.java:34) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansNet

org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:478) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansNet(Read.java:44) 
30 lines not shown
Caused by org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException: Column family humanId does not exist in region HumansPrivatePhoto,,1355753666960.00ff6a12afa062f832888890d4cd0c31. in table {NAME => 'HumansPrivatePhoto', FAMILIES => [{NAME => 'human', BLOOMFILTER => 'NONE', REPLICATION_SCOPE => '0', COMPRESSION => 'NONE', VERSIONS => '3', TTL => '2147483647', MIN_VERSIONS => '0', BLOCKSIZE => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]} at org.apache.hadoop.hbase.regionserver.HRegion.checkFamily(HRegion.java:3910) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1423) at org.apache.hadoop.hbase.regionserver.HRegion.getScanner(HRegion.java:1402) at org.apache.hadoop.hbase.regionserver.HRegionServer.openScanner(HRegionServer.java:2068) at sun.reflect.GeneratedMethodAccessor14.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Server.call(WritableRpcEngine.java:364) at org.apache.hadoop.hbase.ipc.HBaseServer$Handler.run(HBaseServer.java:1326)

sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) 
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) 
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:513) 
at org.apache.hadoop.hbase.RemoteExceptionHandler.decodeRemoteException(RemoteExceptionHandler.java:96) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.translateException(HConnectionManager.java:1652) 
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getRegionServerWithRetries(HConnectionManager.java:1328) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.nextScanner(HTable.java:1246) 
at org.apache.hadoop.hbase.client.HTable$ClientScanner.initialize(HTable.java:1169) 
at org.apache.hadoop.hbase.client.HTable.getScanner(HTable.java:670) 
at org.apache.hadoop.hbase.client.HTablePool$PooledHTable.getScanner(HTablePool.java:381) 
at com.impetus.client.hbase.service.HBaseReader.loadAll(HBaseReader.java:125) 
at com.impetus.client.hbase.admin.HBaseDataHandler.scanData(HBaseDataHandler.java:884) 
at com.impetus.client.hbase.HBaseClient.findByRelation(HBaseClient.java:473) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:317) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:194) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.persistence.AssociationBuilder.populateRelationViaQuery(AssociationBuilder.java:278) 
at com.impetus.kundera.persistence.AbstractEntityReader.recursivelyFindEntities(AbstractEntityReader.java:184) 
at com.impetus.kundera.lifecycle.states.ManagedState.handleFind(ManagedState.java:152) 
at com.impetus.kundera.graph.Node.find(Node.java:499) 
at com.impetus.kundera.persistence.PersistenceDelegator.find(PersistenceDelegator.java:241) 
at com.impetus.kundera.persistence.PersistenceDelegator.findById(PersistenceDelegator.java:185) 
at com.impetus.kundera.persistence.EntityManagerImpl.find(EntityManagerImpl.java:312) 
at ai.ilikeplaces.entities.Read.HumansNet(Read.java:44) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansNetPeople

null

ai.ilikeplaces.entities.Read.HumansNetPeople(Read.java:40) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansPrivateLocation

null

ai.ilikeplaces.entities.Read.HumansPrivateLocation(Read.java:50) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansPrivatePhoto

null

ai.ilikeplaces.entities.Read.HumansPrivatePhoto(Read.java:60) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansPublicPhoto

null

ai.ilikeplaces.entities.Read.HumansPublicPhoto(Read.java:65) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Read:HumansWall

null

ai.ilikeplaces.entities.Read.HumansWall(Read.java:70) 
30 lines not shown
back to summary

ai.ilikeplaces.entities.Create:Human

back to summary

ai.ilikeplaces.entities.Create:HumansAlbum

back to summary

ai.ilikeplaces.entities.Create:HumansAuthentication

back to summary

ai.ilikeplaces.entities.Create:HumansIdentity

back to summary

ai.ilikeplaces.entities.Create:HumansNet

back to summary

ai.ilikeplaces.entities.Create:HumansNetPeople

back to summary

ai.ilikeplaces.entities.Create:HumansPrivateLocation

back to summary

ai.ilikeplaces.entities.Create:HumansPrivatePhoto

back to summary

ai.ilikeplaces.entities.Create:HumansPublicPhoto

back to summary

This is the entity class:

package ai.ilikeplaces.entities;

import ai.ilikeplaces.entities.etc.EntityLifeCycleListener;
import ai.ilikeplaces.entities.etc.HumanIdFace;
import ai.scribble.License;

import javax.persistence.*;
import java.io.Serializable;
import java.util.List;

/**
 * @author Ravindranath Akila
 */

@License(content = "This code is licensed under GNU AFFERO GENERAL PUBLIC LICENSE Version 3")
@Table(name = "HumansPrivatePhoto", schema = "KunderaKeyspace@ilpMainSchema")
@Entity
@EntityListeners({EntityLifeCycleListener.class})
public class HumansPrivatePhoto implements HumanIdFace, Serializable {
// ------------------------------ FIELDS ------------------------------

    private static final long serialVersionUID = 1L;

    @Id
    public String humanId;
    public static final String humanIdCOL = "humanId";

    @OneToOne(mappedBy = Human.humansPrivatePhotoCOL, cascade = CascadeType.REFRESH)
    //@PrimaryKeyJoinColumn
    public Human human;

    @OneToMany(fetch = FetchType.EAGER, cascade = CascadeType.MERGE)
    @JoinColumn(name = humanIdCOL)
    public List<PrivatePhoto> privatePhotos;

// --------------------- GETTER / SETTER METHODS ---------------------

    public Human getHuman() {
        return human;
    }

    public void setHuman(final Human human) {
        this.human = human;
    }

    public String getHumanId() {
        return humanId;
    }

    public void setHumanId(final String humanId__) {
        this.humanId = humanId__;
    }

    public List<PrivatePhoto> getPrivatePhotos() {
        return privatePhotos;
    }

    public void setPrivatePhotos(List<PrivatePhoto> privatePhotos) {
        this.privatePhotos = privatePhotos;
    }


}

Removed @column on the primary key as you requested. Do let me know what else we could do to get things working.

You can ask me to tear down the sources to a very bare minimum to make it Kundera compatible. I can do them and test, then upload the results here. What I require is to find out where the issues come up. Right now, I'm quite lost how to get things compatible. After that, I will fork the project for a Kundera specific version so that we can keep testing Kundera on it.

If you would like, I can bundle and mail you the test code. I can assure you you will not hit any dependency or build problems.

Collaborator

mevivs commented Dec 17, 2012

Ok. Looks like some problem in defining relationship b/w Human and HumansPrivatePhoto with "shared by primary key". let me look into get this working

Thanks a lot! 👍

Collaborator

mevivs commented Dec 17, 2012

Can you try:

  1. Remove @column(name = "humanId") from @id attribute from Human
  2. In HumansPrivatePhoto entity, change
    @OneToOne(mappedBy = Human.humansPrivatePhotoCOL, cascade = CascadeType.REFRESH)
    //@PrimaryKeyJoinColumn
    public Human human

TO

    @OneToOne(mappedBy = "humansPrivatePhoto", cascade = CascadeType.REFRESH)
    //@PrimaryKeyJoinColumn
    public Human human

Also you can have at:

https://github.com/impetus-opensource/Kundera/blob/trunk/kundera-tests/src/test/java/com/impetus/kundera/tests/crossdatastore/useraddress/entities/HabitatBi1To1FK.java

and

https://github.com/impetus-opensource/Kundera/blob/trunk/kundera-tests/src/test/java/com/impetus/kundera/tests/crossdatastore/useraddress/entities/PersonnelBi1To1FK.java

For mapping reference.

All sort of association entities are within:

https://github.com/impetus-opensource/Kundera/blob/trunk/kundera-tests/src/test/java/com/impetus/kundera/tests/crossdatastore/useraddress/entities

Ok, I'll try them, fix and then get back to you with the improved test cases. Thanks a lot Vivek!

@ghost ghost assigned kkmishra Dec 17, 2012

Collaborator

mevivs commented Dec 19, 2012

Hi Ravindra,
Any luck with this? Let me know, if facing any issue

Cheers,
-Vivek

Hi Vivek, Yes I did online all static references as you advised but the
failures were the same. Anything else you see being done wrong here? Thanks
a lot.


Reply to this email directly or view it on GitHub.

Collaborator

mevivs commented Dec 19, 2012

Let me try at my end. wll let you know the result.

-Vivek

Thanks a lot! 👍

@mevivs mevivs added a commit that referenced this issue Dec 20, 2012

@mevivs mevivs Fix for issue #153 554eaa4
Collaborator

mevivs commented Dec 20, 2012

A fix has been checked in for this in current trunk branch. Can you please verify this?

Thanks KK for providing for fix.

-Vivek

Thanks! Is there anyway I can download the latest build jars? WIll it be possible to have them emailed at ravindranathakila@gmail.com if not?

Collaborator

mevivs commented Dec 25, 2012

Hi,
Performance fixes has been checked-in in current trunk branch as well. Changes summary:

  1. 1 column family per entity
  2. Read optimization

I have emailed you the snapshot jar on your email id as well.

-Vivek

Collaborator

mevivs commented Jan 22, 2013

Please verify, code and executables have been shared.

-Vivek

I ran the tests again against 2.3 SNAPSHOT (just checked out). I believe a few reads have been rectified over this build. However, there are other read failures. The entities I'm testing with are located here. They are identical (I've got not local modifications) except the Kundera version.

Screen Shot 2013-01-23 at 9 53 20 PM


Test set: TestSuite

Tests run: 19, Failures: 6, Errors: 0, Skipped: 0, Time elapsed: 180.74 sec <<< FAILURE!
HumansAlbum(ai.ilikeplaces.entities.Read) Time elapsed: 0.006 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansAlbum(Read.java:56)

HumansNetPeople(ai.ilikeplaces.entities.Read) Time elapsed: 0.003 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansNetPeople(Read.java:41)

HumansPrivateLocation(ai.ilikeplaces.entities.Read) Time elapsed: 0.003 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPrivateLocation(Read.java:51)

HumansPrivatePhoto(ai.ilikeplaces.entities.Read) Time elapsed: 0.002 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPrivatePhoto(Read.java:61)

HumansPublicPhoto(ai.ilikeplaces.entities.Read) Time elapsed: 0.003 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansPublicPhoto(Read.java:66)

HumansWall(ai.ilikeplaces.entities.Read) Time elapsed: 0.007 sec <<< FAILURE!
java.lang.NullPointerException
at ai.ilikeplaces.entities.Read.HumansWall(Read.java:71)

Most probably these are due to annotations and relationships in the entities.

Collaborator

mevivs commented Jan 24, 2013

Moving for 2.4 as more input required.

Collaborator

mevivs commented Jan 29, 2013

Hi,
I can't see that your entities like HumansAlbum are properly annotated, they are missing @table annotation.
Also, i can see that it got dependency for open-jpa as well. Request you to please share code with your CRUD code snippet, which is not working for you.

-Vivek

Collaborator

mevivs commented Feb 11, 2013

More specific inputs needed. I have gone through the attachment but details are very minimal.

-Vivek

Collaborator

mevivs commented Apr 25, 2013

Closing ans did not receive any input.

-Vivek

@mevivs mevivs closed this Apr 25, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment