How to connect to database using cumulocity json, In java spring boot application


i want to connect postgres database in inorder to read some data, currently i am connecting to database using file.
But I need to connect to data base using cumulocity json file.

please provide me with the code or sample springboot project.

This does not make any sense for the following reasons:

  1. the is the properties file for the application
  2. cumulocity.json is a manifest file only used by the platform and does not contain any properties used by the application

Hi @Stefan_Witschel ,

i i want read the data which is declared in cumulocity.json file. in java springboot application

I have the following data in cumulocity.json file.

“settings”: [
“key”: “xyz”,
“defaultValue”: “xyzabc”

i want to read default value using the key. in java springboot microservice.

help me with this

They are persisted on initial deployment in the Tenant Options.

You can read them there as well on startup:

Just to clarify some misassumption: You don’t need to connect to any database, you just need to access the API which is part of the SDK.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.