Git Product home page Git Product logo

tjpoc's Introduction

Prepare

- Install and run mongo at localhost:27017
- Import data into histxn.tx
- git clone https://github.com/tjworks/tjpoc 	
- cd tjpoc

Build & Test Instruction(optional):

- Install JDK, Maven	
- mvn clean compile assembly:single
- mvn test 

Demo from command line:

./run.sh -p key=value -p key=value

Parameters for run.sh

Query paramegers

- account
- from_date
- to_date
- trace 
- min_amount
- max_amount
- ccy

Mongo connection params

- url  #  MongoDB connection URL, default: mongodb://localhost:27017
- db   #  default to histxn
- collection  # default to tx

Sample run

  ./run.sh -p account=11000253321701 -p from_date=2015-07-01 -p to_date=2015-07-01  
 ./run.sh -p account=11000253321701 -p from_date=2015-07-01 -p to_date=2015-07-01  -p trace=159960
  ./run.sh -p account=11000253321701 -p from_date=2015-07-01 -p to_date=2015-07-01  -p min_amount=304 -p max_amount=2000
./run.sh -p account=272100088551 -p from_date=2015-07-01 -p to_date=2015-08-30  -p min_amount=100000 -p max_amount=200000

Loadrunner Integration

  • Add jar file(under target/ folder) to the load runner path
	import com.mongodb.pinganpoc.MongoPoc;
	...
	public void init(){

		MongoPoc.init("mongodb://localhost:27017", "histxn", "tx");

	}
  	public void action(){
  		...
  		String res = MongoPoc.runQuery(
            new Long("272100088551"), 		// account
            "2015-07-01",					// from date
            "2015-07-01",					// to date
            "RMB",							// ccy
            new Double(100000),				// min amount
            new Double(200000), 			// max amount
            null							// host trace
        );   
  		...
  	} 

Please refer to https://github.com/tjworks/tjpoc/blob/master/src/test/java/com/mongodb/pinganpoc/MongoPocTest.java for more example usage from Java.

tjpoc's People

Contributors

tjworks avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.