-
Notifications
You must be signed in to change notification settings - Fork 209
Getting started a development
#Setup development IDE This tutorial aims at showing you, how to setup a development IDE in order to start development process. For development work may start all microservices in the development environment, following below steps. Since we uses InteliJ IDEA, the all instructions are prepared using this software. However you can do it similarly in other IDE, i. e. Netbeans and Eclipse.
##Build the project At the first open the project in IntelliJ IDEA.
###Set Maven version InteliJ IDEA by default uses Maven in version 3.0.5. The Abixen Platform project requires version 3.1.0 or newest. Let's configure the Maven version in InteliJ IDEA. Open preferences window:
Go to Maven section and indicate location to Maven's directory on your system.
###Install Then, click the right mouse button on the install option and select Run maven build:
Maven should download all required dependencies, both java libraries and using Maven Frontend Plugin trigger the bower ones downloading process.
##Run particular microservices
###Run Eureka
In a browser go to address http://localhost:8761 and if you can see the Eureka's page, go to the next step. ###Run Configuration Server Go to the abixen-platform-core.yml in the abixen-platform-configuration microservice. Set a correct absolute path of the imageLibraryDirectory property. In the future this config will be improvement. In example like this:
imageLibraryDirectory: /Users/MariuszKumor/workspace/projects/github/abixen-platform/data/image-library/
Similarly as Eureka, start Abixen Platform Configuration microservice. Refresh the Eureka's page and check if the ABIXEN-PLATFORM-CONFIGURATION has been registered. (the section Instances currently registered with Eureka) If yes, go to the next step. ###Run Hystrix Dashboard This microservice is not required and may be omitted, taking into account the Hystrix Dashboard allows to monitor a network traffic between microservices.
Similarly as Eureka, start Abixen Platform Hystrix Dashboard microservice. Refresh the Eureka's page and check if the ABIXEN-PLATFORM-HYSTRIX-DASHBOARD has been registered. If yes, go to the next step. ###Run Gateway
Gateway requires Redis installed and running. On the below URL address there is a sample how to install Redis on Mac OS X http://jasdeep.ca/2012/05/installing-redis-on-mac-os-x And here there is a source of Redis for Windows https://github.com/MSOpenTech/redis/releases
Click the right mouse button on the spring-boot:run option and select create abixen-platform-gateway one:
In the opened window put VM option -Dspring.profiles.active=dev
Save changes, and run:
Refresh the Eureka's page and check if the ABIXEN-PLATFORM-GATEWAY has been registered. If yes, go to the next step.
###Run Modules
Go to similar steps as Abixen Platorm Gateway. Set JVM variables -Dspring.profiles.active=dev -DcreateDbSchema=true
Refresh the Eureka's page and check if the ABIXEN-PLATFORM-MODULES has been registered. If yes, go to the next step.
###Run Core
Go to similar steps as Abixen Platorm Gateway. Set JVM variables -Dspring.profiles.active=dev -DcreateDbSchema=true
Refresh the Eureka's page and check if the ABIXEN-PLATFORM-CORE has been registered. If yes, go to the next step. ###Run Web Client
Go to similar steps as Abixen Platorm Gateway. Set JVM variables -Dspring.profiles.active=dev
Refresh the Eureka's page and check if the ABIXEN-PLATFORM-WEB-CLIENT has been registered. If yes, in a browser go to the address http://localhost:8080 and sign in to the platform. There are three initial users:
- username admin and password password
- username user and password password
- username editor and password password
#Dealing with static resources The are static resources in the Web Client and the Modules microservices. A developer have to modify files in the web directory. Once some changes has been done, running the grunt task from the Maven Frontend Plugin, resources are processing and putting into static directory. Don't modify a content of the static directory - it is overwritten every time, once the grunt task is performed. Refresh a browser after the grunt task is finished.