Skip to content

Commit f4c27dd

Browse files
inventory-quarkus (#238)
* dotnet docker work and password/url fix * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * remove sqlnet.ora edit work * recovery test work * recovery test work * recovery test work * recovery test work * replace postgres configmap with secret * replace postgres configmap with secret * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * TEQ setup and tracing * mongo, postgres, kafka crash tests * mongo, postgres, kafka crash tests * grafana work * grafana work * grafana work * grafana work * grafana work * grafana work * observability work * observability work * observability work * observability work * observability work * observability work * observability work * observability work * observability work * observability work * observability work * dotnet work * dotnet work * dotnet work * dotnet work * dotnet work * observability, dotnet, go, etc. work - move kafka etc. build to nonjava * observability, dotnet, go, etc. work - move kafka etc. build to nonjava * observability, dotnet, go, etc. work - move kafka etc. build to nonjava * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * enable teq * observability * enable teq * enable teq * enable teq * enable teq * enable teq * observability work * observability work * enable teq * enable teq * enable teq * observ * enable teq * observability dash * observability * osbservability * enable teq * enable teq * enable teq * obs * obs * enable teq * obs * enable teq * observ * obs * converged wording change * fix k6 command * correct workshop link * update workshop link * modifiy python impl to conn.autocommit = False * enable teq * various including security fix in inventory-nodejs * various including security fix in inventory-nodejs * various including security fix in inventory-nodejs * enable teq * inventory-micronaut * inventory-micronaut * inventory-quarkus
1 parent 09d9bd7 commit f4c27dd

26 files changed

+1707
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
*
2+
!target/*-runner
3+
!target/*-runner.jar
4+
!target/lib/*
5+
!target/quarkus-app/*

grabdish/inventory-quarkus/build.sh

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/bin/bash
2+
## Copyright (c) 2021 Oracle and/or its affiliates.
3+
## Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl/
4+
5+
6+
IMAGE_NAME=inventory-quarkus
7+
IMAGE_VERSION=0.1
8+
9+
10+
if [ -z "$DOCKER_REGISTRY" ]; then
11+
echo "DOCKER_REGISTRY not set. Will get it with state_get"
12+
export DOCKER_REGISTRY=$(state_get DOCKER_REGISTRY)
13+
fi
14+
15+
if [ -z "$DOCKER_REGISTRY" ]; then
16+
echo "Error: DOCKER_REGISTRY env variable needs to be set!"
17+
exit 1
18+
fi
19+
20+
21+
export IMAGE=${DOCKER_REGISTRY}/${IMAGE_NAME}:${IMAGE_VERSION}
22+
23+
./mvnw clean package -Dquarkus.container-image.build=true -Dquarkus.container-image.push=true -Dquarkus.container-image.group="${DOCKER_REGISTRY}" -Dquarkus.container-image.name=${IMAGE_NAME} -Dquarkus.container-image.tag=${IMAGE_VERSION}
24+
25+
#docker push $IMAGE
26+
#if [ $? -eq 0 ]; then
27+
# docker rmi ${IMAGE}
28+
#fi

grabdish/inventory-quarkus/deploy.sh

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
#!/bin/bash
2+
## Copyright (c) 2021 Oracle and/or its affiliates.
3+
## Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl/
4+
5+
SCRIPT_DIR=$(dirname $0)
6+
7+
if [ -z "$DOCKER_REGISTRY" ]; then
8+
echo "DOCKER_REGISTRY not set. Will get it with state_get"
9+
export DOCKER_REGISTRY=$(state_get DOCKER_REGISTRY)
10+
fi
11+
12+
if [ -z "$DOCKER_REGISTRY" ]; then
13+
echo "Error: DOCKER_REGISTRY env variable needs to be set!"
14+
exit 1
15+
fi
16+
17+
if [ -z "$INVENTORY_PDB_NAME" ]; then
18+
echo "INVENTORY_PDB_NAME not set. Will get it with state_get"
19+
export INVENTORY_PDB_NAME=$(state_get INVENTORY_DB_NAME)
20+
fi
21+
22+
if [ -z "$INVENTORY_PDB_NAME" ]; then
23+
echo "Error: INVENTORY_PDB_NAME env variable needs to be set!"
24+
exit 1
25+
fi
26+
27+
echo create inventory-quarkus deployment and service...
28+
29+
export CURRENTTIME=$( date '+%F_%H:%M:%S' )
30+
echo CURRENTTIME is $CURRENTTIME ...this will be appended to generated deployment yaml
31+
cp inventory-quarkus-deployment.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
32+
33+
sed -e "s|%DOCKER_REGISTRY%|${DOCKER_REGISTRY}|g" inventory-quarkus-deployment-$CURRENTTIME.yaml > /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml
34+
mv -- /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
35+
sed -e "s|%DOCKER_REGISTRY%|${DOCKER_REGISTRY}|g" inventory-quarkus-deployment-$CURRENTTIME.yaml > /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml
36+
mv -- /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
37+
sed -e "s|%INVENTORY_PDB_NAME%|${INVENTORY_PDB_NAME}|g" inventory-quarkus-deployment-$CURRENTTIME.yaml > /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml
38+
mv -- /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
39+
sed -e "s|%OCI_REGION%|${OCI_REGION}|g" inventory-quarkus-deployment-${CURRENTTIME}.yaml > /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml
40+
mv -- /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
41+
sed -e "s|%VAULT_SECRET_OCID%|${VAULT_SECRET_OCID}|g" inventory-quarkus-deployment-${CURRENTTIME}.yaml > /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml
42+
mv -- /tmp/inventory-quarkus-deployment-$CURRENTTIME.yaml inventory-quarkus-deployment-$CURRENTTIME.yaml
43+
44+
if [ -z "$1" ]; then
45+
kubectl apply -f $SCRIPT_DIR/inventory-quarkus-deployment-$CURRENTTIME.yaml -n msdataworkshop
46+
else
47+
kubectl apply -f <(istioctl kube-inject -f $SCRIPT_DIR/inventory-quarkus-deployment-$CURRENTTIME.yaml) -n msdataworkshop
48+
fi
49+
50+
kubectl create -f inventory-service.yaml -n msdataworkshop
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
## Copyright (c) 2021 Oracle and/or its affiliates.
2+
## Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl/
3+
apiVersion: apps/v1
4+
kind: Deployment
5+
metadata:
6+
name: inventory-quarkus
7+
spec:
8+
replicas: 1
9+
selector:
10+
matchLabels:
11+
app: inventory
12+
template:
13+
metadata:
14+
labels:
15+
app: inventory
16+
version: quarkus
17+
spec:
18+
containers:
19+
- name: inventory
20+
image: %DOCKER_REGISTRY%/inventory-quarkus:0.1
21+
imagePullPolicy: Always
22+
env:
23+
- name: oracle.ucp.jdbc.PoolDataSource.inventorypdb.user
24+
value: "inventoryuser"
25+
- name: oracle.ucp.jdbc.PoolDataSource.inventorypdb.URL
26+
value: "jdbc:oracle:thin:@%INVENTORY_PDB_NAME%_tp?TNS_ADMIN=/msdataworkshop/creds"
27+
- name: orderqueuename
28+
value: "ORDERQUEUE"
29+
- name: inventoryqueuename
30+
value: "inventoryqueue"
31+
- name: OCI_REGION
32+
value: "%OCI_REGION%"
33+
- name: VAULT_SECRET_OCID
34+
value: "%VAULT_SECRET_OCID%"
35+
- name: dbpassword
36+
valueFrom:
37+
secretKeyRef:
38+
name: dbuser
39+
key: dbpassword
40+
optional: true #not needed/used if using VAULT_SECRET_OCID exists
41+
volumeMounts:
42+
- name: creds
43+
mountPath: /msdataworkshop/creds
44+
ports:
45+
- containerPort: 8080
46+
restartPolicy: Always
47+
volumes:
48+
- name: creds
49+
secret:
50+
secretName: db-wallet-secret
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
## Copyright (c) 2021 Oracle and/or its affiliates.
2+
## Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl/
3+
apiVersion: v1
4+
kind: Service
5+
metadata:
6+
name: inventory
7+
labels:
8+
app: inventory
9+
spec:
10+
type: NodePort
11+
ports:
12+
- port: 8080
13+
name: metrics
14+
targetPort: 8080
15+
selector:
16+
app: inventory

0 commit comments

Comments
 (0)