You can download the correct version of Cassandra for your OS from the DataStax website. A zipped version of my project is attached below. <dependency> <groupId>com.datastax.cassandra</groupId> <artifactId>cassandra-driver-core</artifactId> <version>1.0.3</version> </dependency> <dependency> <groupId>com.datastax.cassandra</groupId> <artifactId>cassandra-driver-core</artifactId> <version>1.0.3-dse</version> </dependency> Server setupSimply start cassandra.bat under apache-cassandra/bin to start the server. Once you have started the server, you can use the connectivity test to check if you are able to connect to it. Schema and Table setup (and tear down)Once connectivity has been established successfully, you need to create the market data schema and tables before inserting market data. There is a method to drop the schema (I real life you might "ALTER", but here DROP sufficed)Similarly, for the trade data schema, use testCreateSchema to create the schema and tables and use the testDropSchema to tear it down For populating the market data use one of these methods
For populating the trade data use either of these
Once you have run testInsetTestMarketData and testInsertTestTradeData (as the bare minimum), you should be able to run the test pricer to verify that the whole setup works. The method is testPricingTestData and checks that the NPV is as expected.
SELECT data from marketdata.markets where assetClass=? allow filtering The caveat being, not all data is guaranteed to be returned (which made Cassandra the least favorite of the system I analyzed, not to mention the performance issues encountered when query across the full One million population set) |