GithubHelp home page GithubHelp logo

malotian / moltin.java.adventure.works Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 161 KB

moltin.java.adventure.works

License: MIT License

Java 100.00%
moltin adventureworks ecommerce ecommerce-store dataset populate

moltin.java.adventure.works's Introduction

overview

java component to populate moltin store with adventure works data.

pre-requisites

1- java jdk 1.7 or above. to download refer to- http://www.oracle.com/technetwork/java/javase/downloads/index.html

2- gradle build tool to download refer to- https://gradle.org/install/

after downloading both, add java and gradle in environment variable. refer to https://www.java.com/en/download/help/path.xml on how to add path in windows and unix machine.

prepare adventure.works data

download & extarct Adventure Works data. replace following line in product.csv

814 ML Mountain Frame - Black, 38 FR-M63B-38 1 1 Black 500 375 185.8193 348.76 38 CM LB 2.73 2 M M U 12 15 2012-05-30 00:00:00 2013-05-29 00:00:00 {0D879312-A7D3-441D-9D23-B6550BAB3814} 2014-02-08 10:01:36.827000000

with

814 ML Mountain Frame - Black, 38 FR-M63B-38 1 1 Black 500 375 185.8193 348.76 38 CM LB 2.73 2 M M U 12 14 2012-05-30 00:00:00 2013-05-29 00:00:00 {0D879312-A7D3-441D-9D23-B6550BAB3814} 2014-02-08 10:01:36.827000000

Note: above line will fix data issue data.

create jar

downlod/checkout source code into some directory. for example- moltin.java.adventure.works open terminal, change directory to moltin.java.adventure.works

gradle build

after successful build, go to moltin.java.adventure.works/build/libs and copy moltin.java.adventure.works-all.jar to directory from where you want to run java component.

extract sample/template configuration files from jar itself

open terminal, change your directory to location where you copied moltin.java.adventure.works-all.jar

issue comamnds

jar xf moltin.java.adventure.works-all.jar sample.application.properties
jar xf moltin.java.adventure.works-all.jar sample.log4j.properties

sample.application.properties and sample.log4j.properties will be created in current directory

setup configuration files

issue commands

mv sample.application.properties application.properties
mv sample.log4j.properties log4j.properties`

edit configuration files

  1. application.properties - refer sample.application.properties.
  2. log4j.properties - refer sample.log4j.properties (standard - https://logging.apache.org/log4j)

application.properties

##########start - application.properties#############

####### moltiin api - client id

moltin.api.client.id=MyKjhjJZNUnnVHFNPMeiifK7Ja9uEgGMStsSReLkJb

####### moltiin api - secret/password

moltin.api.client.secret=8WQtgGKX41YKyK6mt4LSe95eirufujcc8lux4dzzuf

####### location of downloaded adventure works data (path of the folder containing csv files) ####### make sure path doesn't contain spaces

adventure.works.data.location=d:/downloads/adventure.works.data

##########end - application.properties#############

run moltin.java.adventure.works

change your directory to moltin.java.adventure.works-home-dir where moltin.java.adventure.works-app-jar is located. and issue a command

 java -DMOLTIN_JAVA_ADVENTURE_WORKS_HOME=<moltin.java.adventure.works-home-dir> -jar moltin.java.adventure.works-all.jar 

in this command jvm argument moltin.java.adventure.works.home specifies directory containing application.properties.

moltin.java.adventure.works's People

Contributors

malotian avatar

Watchers

 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.