question

SajithShetty-0444 avatar image
0 Votes"
SajithShetty-0444 asked SajithShetty-0444 commented

JAVA APIs to modify azure postgres parameters

Hi,

Our organisation is planning to migrate to azure Postgres from on-premise. Currently, we have a JAVA program that modifies the config parameters of Postgres. I understand that azure provides a CLI tool to modify or automate the modification of DB parameters. However are there any APIs which we can call from the JAVA program to modify the parameters?
Thanks in advance!

azure-database-postgresql
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

AnuragSharma-MSFT avatar image
0 Votes"
AnuragSharma-MSFT answered AnuragSharma-MSFT commented

Hi @SajithShetty-0444, welcome to Microsoft Q&A forum.

As I understand from your query, you want to change the config parameters using any JAVA API for Azure PostgreSQL.

We can config the parameters through the Azure Portal, Azure CLI and Rest API.

In your case you can call the rest API through the JAVA code and update the config. Below is the rest API call you can use:

Server Parameters - List Update Configurations

Configurations - Get

Please let us know if that helps or else we can discuss further.

· 5
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Thank you for the quick response! I will make use of the links provided.

Does this work for both Flexible and hyperscale?
Also is it possible to restart the database from an API? If yes, link please.
Thanks

0 Votes 0 ·

Thanks @SajithShetty-0444 for replying back.

There are separate REST API calls for both Single Server and Flexible Server.

Single Server REST operations

Flexible Server REST operations

Based on the server we can choose either of them.


If answer is helpful please click on 202266-image.png as it could help other members of the Microsoft Q&A community who have similar questions and are looking for solutions. Thank you for helping to improve Microsoft Q&A!



0 Votes 0 ·
image.png (3.2 KiB)

What about Hyperscale citus version?

0 Votes 0 ·
Show more comments