gora-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lewis John Mcgibbney <lewis.mcgibb...@gmail.com>
Subject Re: Obtaining Datastore Mapping's during testing time.
Date Sat, 17 Mar 2012 13:37:56 GMT
I've finally understood what is still going wrong here (hopefully). If you
have a look at  TestHBaseStore#createEmployeeDataStore [0],
#createWebPageDataStore [0],

  @Override
  protected DataStore<String, Employee> createEmployeeDataStore()
      throws IOException {
    return DataStoreFactory.createDataStore(HBaseStore.class, String.class,
        Employee.class, conf);
  }

  @Override
  protected DataStore<String, WebPage> createWebPageDataStore()
      throws IOException {
    return DataStoreFactory.createDataStore(HBaseStore.class, String.class,
        WebPage.class, conf);
  }


and TestSqlStore#createEmployeeDataStore [1] and #createWebPageDataStore
[1]

  @Override
  protected DataStore<String, Employee> createEmployeeDataStore()
throws IOException {
    SqlStore<String, Employee> store = new SqlStore<String, Employee>();
    store.initialize(String.class, Employee.class, DataStoreFactory.properties);
    return store;
  }

  @Override
  protected DataStore<String, WebPage> createWebPageDataStore() throws
IOException {
    SqlStore<String, WebPage> store = new SqlStore<String, WebPage>();
    store.initialize(String.class, WebPage.class, DataStoreFactory.properties);
    return store;
  }

they are being constructed in different ways. Right now although I have the
embedded Cassandra cluster being initiated, I'm getting lengthy stacktraces
indicating the the configuration is not correct when attempting to create
the appopriate DataStore (in this case CassandraStore).

If anyone has any suggestions about how I should be constructing the above
TestCassandraStore#createEmployeeDataStore classes then I would be really
happy to hear it... until then it's back to the drawing board I guess.

[0]
http://svn.apache.org/repos/asf/gora/trunk/gora-hbase/src/test/java/org/apache/gora/hbase/store/TestHBaseStore.java
[1]
http://svn.apache.org/repos/asf/gora/trunk/gora-sql/src/test/java/org/apache/gora/sql/store/TestSqlStore.java

On Sat, Mar 10, 2012 at 12:10 PM, Lewis John Mcgibbney <
lewis.mcgibbney@gmail.com> wrote:

> Hi Enis
>
> On Sat, Mar 10, 2012 at 2:04 AM, Enis Söztutar <enis@apache.org> wrote:
>
>> Did you tried putting the test conf under gora-cassandra/src/test/conf/ ?
>> See the files in gora-hbase/src/test/conf/.
>>
>> Yeah I mean my test mappings and the cassandra.yaml (equivalent of HBase
> hbase-site.xml) is underneath the conf directory (actually I'm going to
> remove gora.properties from this folder as it currently does not play any
> role). I just seem to be having a problem actually obtaining the mappings
> from anywhere, and also I currently don't know/can't find the correct code
> to initiate the Hadoop Configuration. I'm going to attach my most recent
> sure-fire report to the Jira issue as well so people can see the output.
>
> The classpath and test classpath is cofigured in build-common.xml:
>>
>
> Does maven pick these properties up? I thought this was for Ant only? I
> have not used Ant with Gora for a while now, and I'm aware that the Ant
> build is broken and as far as I'm aware unmaintained now.
>
> Thanks Enis
>
> Lewis
>



-- 
*Lewis*

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message