Open WillusDong opened 1 year ago
Hi @WillusDong, This implementation supports only device designed by ipv4Address.publicAddress and single port.
Try something like this.
{
"duration": 86400,
"device": {
"ipv4Address": {
"publicAddress": "192.168.0.2"
}
},
"applicationServer": {
"ipv4Address": "192.168.0.1"
},
"devicePorts": {
"ports": [
5022
]
},
"applicationServerPorts": {
"ports": [
5010
]
},
"qosProfile": "vp251iMf1TJiFQq1jpzihd9E9K40.lHI89cTyIdtumWq2VB_cCM4KmUqYvUP8TJCzXab1PvqjaS-vIWwltxHsUjUN",
"webhook": {
"notificationUrl": "http://localhost:8080/qosChanged",
"notificationAuthToken": "L2xvY2FsaG9zdDoxMDAxMi9Bc1NDUy9ub3RpZnk"
}
}
Hello @patrice-conil,
Thanks for the quick turnaround, when I tried with this payload and the same configuratioin mentioned earlier, I got this errors - 'Default' client configuration is not initialized.
Any thoughts?
Hi @WillusDong, I think you didn't provide values for CLIENT_ID and CLIENT_SECRET in your env and these values are used to configure oidc client. Hope this helps
Thanks @patrice-conil,
If provided, with customized values as follows, the same error returns: export CLIENT_ID=appId; export CLIENT_SECRET=secret; java -jar ./build/camara-qod-0.9.0-runner.jar
Request
curl -X 'POST' \
'http://192.168.1.43:8080/qod/v0/sessions' \
-H 'accept: application/json' \
-H 'X-OAPI-Application-Id: appId' \
-H 'Content-Type: application/json' \
-d '{
"duration": 86400,
"device": {
"ipv4Address": {
"publicAddress": "192.168.0.2"
}
},
"applicationServer": {
"ipv4Address": "192.168.0.1"
},
"devicePorts": {
"ports": [
5022
]
},
"applicationServerPorts": {
"ports": [
5010
]
},
"qosProfile": "vp251iMf1TJiFQq1jpzihd9E9K40.lHI89cTyIdtumWq2VB_cCM4KmUqYvUP8TJCzXab1PvqjaS-vIWwltxHsUjUN",
"webhook": {
"notificationUrl": "http://localhost:8080/qosChanged",
"notificationAuthToken": "L2xvY2FsaG9zdDoxMDAxMi9Bc1NDUy9ub3RpZnk"
}
}'
LOG log_CLIENT.txt
Hi @WillusDong, I think your scef client config is wrong : https://localhost:8888/http://localhost:8888/apigm should be something like http://localhost:8888/apigm => default client is not initialized.
Still getting the same error with suggested change.
Would you provide complete settings that works with wiremock?
Thanks.
Hi @WillusDong, I pushed a new version more user friendly that need no additional config to run and auto-provision redis content. Could you see if it solve your problem?
Thanks @patrice-conil Will give it a try and keep you updated.
Sorry for the delay, The update makes the deployment much easier, I would just need to make sure that wiremock is listening on port 8888, redis server is listening on localhost:6370, and it works fine.
Thanks.
Hi @WillusDong, You have to download wiremock standalone jar and launch it by hand with something like
java -jar ~/Downloads/wiremock-jre8-standalone-2.35.0.jar --port 8888 --bind-address localhost -vv
from the project's wiremock folder (where __files and mappings reside) Enjoy
PoD PI2 is configured to run with wiremock provided in master branch, when create session request is made from swagger-ui, it fails and the application runs into memory issue - OutOfMemoryError: Java heap space.
Top output:
application.property
Profile config:
Request
LOG log.txt