datanucleus / datanucleus-hbase Goto Github PK
View Code? Open in Web Editor NEWDataNucleus support for persistence to HBase datastores
DataNucleus support for persistence to HBase datastores
All HBase client docs on the internet are for v1.x, but it doesn't seem to work with Java 11+. See https://hbase.apache.org/book.html#java Seems that, as of Aug 2021, they still don't have full support for Java 11.
Need to decipher what needs changing.
See http://hbase.apache.org/2.2/apidocs/overview-summary.html
As a starter
HBaseAdmin -> Admin
HTableDescriptor -> TableDescriptor
HColumnDescriptor -> ColumnFamilyDescriptor
When we make use of a persistable class in the HBase plugin we currently go direct to "manageClasses", whereas we should simply check for StoreData, and only then go to HBase to check it.
We need to support where the PK is formed with a persistable object. Currently it tries to serialise the related object which is wrong
Should lookup using the converted value not the raw field value
Refer to core issue 19
Refer to datanucleus/datanucleus-core#134
When we execute a query and use FetchFieldManager, we have to use the constructor for an ExecutionContext (i.e ObjectProvider not yet known). This means that we cannot easily wrap any SCO fields in FetchFieldManager. Consequently we need to call
ObjectProvider.replaceAllLoadedSCOFieldsWithWrappers()
just after the FetchFieldManager process.
When we retrieve a List from HBase we retrieve it in the exact same order as persisted. That is, it is stored as a Collection in the owner object. If a user puts some @orderby annotation they may want the list reordering.
This applies to ALL non-RDBMS datastores, so creating some generic code would make sense and reorder them in-memory, maybe using a Comparator.
So if the table is in a particular namepace other then default. It looks for a cololmn family prepending the namespace and hence throws exception with org.apache.hadoop.hbase.regionserver.NoSuchColumnFamilyException
Should use the class.isAssignableFrom(...) rather than mmd.hasCollection
See PersistenceNucleusContext.
The current HBase is 1.1.2 - but every version from 0.96 on cannot be used with DataNucleus.
We currently do not support embedded id classes.
When a user is utilising JDO/JPA APIs there are options to lock the objects being worked on, and then unlock them when they are updated. With RDBMS we support this via "SELECT ... FOR UPDATE" (where supported by the datastore). With HBase we could make calls to
HTable.lockRow(byte[]);
HTable.unlockRow(byte[]);
We currently build against
org.apache.hbase
hbase-client
1.1.2
Bumping this to the latest 1.x release (1.6.0) should fix it.
Trying to auto-create tables causes an error, because the table is initially created without any column family (they're added after the table creation). HBase does not allow this (anymore).
http://www.datanucleus.org/servlet/forum/viewthread_thread,7842
Refer to core issue 128 regarding database creation/deletion.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.