blob: 945000796ec8ceb55cd80ff4e1e1c7b62d3a4a74 [file] [log] [blame]
Piotr Jaszczyk67689402018-06-14 09:48:46 +02001#!/bin/bash
2
3# Usage: source ./development.sh and use functions defined here
4# https://httpie.org/ is required for API calls
5
6export MAVEN_OPTS="-T1C"
7
8function veshv_full_rebuild() {
9 mvn clean install -Panalysis ${MAVEN_OPTS}
10}
11
12function veshv_rebuild() {
13 mvn clean install ${MAVEN_OPTS}
14}
15
16function veshv_build() {
17 mvn install ${MAVEN_OPTS}
18}
19
20function veshv_fast_build() {
21 mvn install -DskipTests ${MAVEN_OPTS}
22}
23
24function veshv_docker_start() {
25 docker-compose down
26 docker-compose rm -f
27 docker-compose up
28}
29
30function veshv_docker_clean() {
31 docker volume prune
32}
33
34function veshv_build_and_start() {
35 veshv_fast_build && veshv_docker_start
36}
37
38function veshv_fresh_restart() {
39 docker-compose down
40 docker-compose rm -f
41 veshv_docker_clean
42 veshv_fast_build && docker-compose up
43}
44
45function veshv_simul_dcaeapp_count() {
46 http --json GET http://localhost:8100/messages/count
47}
48
49function veshv_simul_dcaeapp_last_key() {
50 http --json GET http://localhost:8100/messages/last/key
51}
52
53function veshv_simul_dcaeapp_last_value() {
54 http --json GET http://localhost:8100/messages/last/value
55}
56
57function veshv_simul_client() {
58 # feed me with json file using "<"
59 http --json POST http://localhost:8000/simulator/sync
60}
61
62function veshv_simul_client_async() {
63 # feed me with json file using "<"
64 http --json POST http://localhost:8000/simulator/async
65}
66