1 Reply Latest reply on Jul 13, 2013 1:27 AM by Greybird-Oracle

    Schema sample execution error on Windows




      I finally installed Nosql, compiled example\schema, added ddl and when running the class get the error:


      D:\nosql\kv-2.0.39>java -jar lib/kvstore.jar ping -host xxx -port 5000

      Pinging components of store kvstore based upon topology sequence #14

      kvstore comprises 10 partitions and 1 Storage Nodes

      Storage Node [sn1] on xxx:5000    Datacenter: KVLite [dc1]    Status: RUNNING   Ver: 11gR2.2.0.39 2013-04-23 08:28:13

      UTC  Build id: b205fb13eb4e

              Rep Node [rg1-rn1]      Status: RUNNING,MASTER at sequence number: 57 haPort: 5006



      D:\nosql\kv-2.0.39>java -jar D:/nosql/kv-2.0.39/lib/kvclient.jar




      D:\nosql\kv-2.0.39>cd D:\nosql\kv-2.0.39\examples\schema\classes



      D:\nosql\kv-2.0.39\examples\schema\classes>java schema.SchemaExample -store kvstore -host localhost -port 5000


              at schema.Bindings.parseResource(Bindings.java:82)

              at schema.Bindings.<init>(Bindings.java:54)

              at schema.SchemaExample.<init>(SchemaExample.java:183)

              at schema.SchemaExample.main(SchemaExample.java:134)



      D:\nosql\kv-2.0.39\examples\schema\classes>java -version

      java version "1.7.0_10"

      Java(TM) SE Runtime Environment (build 1.7.0_10-b18)

      Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)



      It is Windows 8 64, community edition Nosql.




      Is it a setup issue or code error or something else?

      Please help me get past this Oracle Nosql example error.

        • 1. Re: Schema sample execution error on Windows

          It's trying to load the .avsc files that are in the D:\nosql\kv-2.0.39\examples\schema directory (the source code directory) as resources from your classpath  Here are instructions for making sure these files are in your classpath.  I'm adding the following text to SchemaExample.java:


          * <p>When running this program, the Java classpath must include the

          * kvclient.jar and the example 'classes' directory. The .avsc files must also

          * be found as resources in the classpath, which can be accomplished by adding

          * the 'examples' directory to the classpath or by copying the .avsc files to

          * the 'classes/schema' directory.</p>


          Sorry for the less-than-informative error from the example, we'll improve that.




          Message was edited by: greybird The location of the .avsc files must be in the classes/schema directory, or you must add examples to your classpath.  I had this wrong in my post.