Skip to content
This repository has been archived by the owner on Jan 29, 2024. It is now read-only.

Commit

Permalink
formatting updates (#2404)
Browse files Browse the repository at this point in the history
  • Loading branch information
ArthurFlag authored Dec 28, 2023
1 parent 27bcfbd commit a65191c
Show file tree
Hide file tree
Showing 14 changed files with 173 additions and 172 deletions.
17 changes: 8 additions & 9 deletions docs/integrations/cloudlogging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@ You can send your service logs to Google Cloud Logging to store, search, analyze

There are two steps to setting up this integration:

1. Create the Google Cloud Logging integration

2. Create the integration endpoint
1. Create the Google Cloud Logging integration.
2. Create the integration endpoint.

You can do this using either the `Aiven Console <https://console.aiven.io/>`_ or the :doc:`CLI </docs/tools/cli>`.

Expand Down Expand Up @@ -70,14 +69,14 @@ Step 2. Add the integration endpoint to your service

1. Get the endpoint identifier:

.. code-block:: shell
.. code-block:: shell
avn service integration-endpoint-list --project your-project-name
avn service integration-endpoint-list --project your-project-name
2. Use the ``endpoint_id`` to attach the service to the endpoint:

.. code-block:: shell
.. code-block:: shell
avn service integration-create --project your-project-name \
-t external_google_cloud_logging -s your-service \
-D <ENDPOINT_ID>
avn service integration-create --project your-project-name \
-t external_google_cloud_logging -s your-service \
-D <ENDPOINT_ID>
6 changes: 4 additions & 2 deletions docs/platform/howto/reactivate-suspended-project.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ Reactivate suspended projects

If you have bills past due and didn't set up a payment method, you may receive this error when trying to log in to the console:

ERROR
.. code::
Project suspended, access prohibited
ERROR
Project suspended, access prohibited
Reactivate a suspended project
------------------------------
Expand Down
2 changes: 1 addition & 1 deletion docs/platform/howto/saml/setup-saml-okta.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ This is a two step process. First, you create the SAML SP-Initiated authenticati

#. Enter a name for the app and add a logo.

#. Set it's visibility for your Okta users and click **Next**.
#. Set its visibility for your Okta users and click **Next**.

#. Set the following values in the app configuration:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ Elasticsearch servers to the same cluster, online migration is not
currently possible.

.. important::
Migrating from Elasticsearch to OpenSearch may affect the connectivity between client applications and your service. For example, some code included in clients or tools may check the service version, which might not work with OpenSearch. We recommend that you check the following OpenSearch resources for more information:

Migrating from Elasticsearch to OpenSearch may affect the connectivity between client applications and your service. For example, some code included in clients or tools may check the service version, which might not work with OpenSearch. We recommend that you check the following OpenSearch resources for more information:

* `OpenSearch release notes <https://github.com/opensearch-project/OpenSearch/blob/main/release-notes/opensearch.release-notes-1.0.0.md>`_
* `OpenSearch Dashboards release notes <https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/release-notes/opensearch-dashboards.release-notes-1.0.0.md>`_
* `Frequently asked questions about OpenSearch <https://opensearch.org/faq/>`_
* `OpenSearch release notes <https://github.com/opensearch-project/OpenSearch/blob/main/release-notes/opensearch.release-notes-1.0.0.md>`_
* `OpenSearch Dashboards release notes <https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/release-notes/opensearch-dashboards.release-notes-1.0.0.md>`_
* `Frequently asked questions about OpenSearch <https://opensearch.org/faq/>`_


To migrate or copy data:
Expand Down
2 changes: 1 addition & 1 deletion docs/products/opensearch/howto/saml-sso-authentication.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ To enable SAML authentication for your Aiven for OpenSearch service, follow thes

.. note::

The SP Entity ID can be any arbitrary value defined by the user. Additionally, OpenSearch suggests creating a new application for OpenSearch Dashboards and using the URL of your OpenSearch Dashboards as the SP entity ID.
The SP Entity ID can be any arbitrary value defined by the user. Additionally, OpenSearch suggests creating a new application for OpenSearch Dashboards and using the URL of your OpenSearch Dashboards as the SP entity ID.

* **SAML roles key**: This is an optional field that allows you to map SAML roles to Aiven for OpenSearch roles.
* **SAML subject key**: This is also an optional field that allows you to map SAML subject to Aiven for OpenSearch users.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,20 @@ Setup cross cluster replication for Aiven for OpenSearch® |beta|
Aiven for OpenSearch® cross-cluster replication (CCR) is a :doc:`limited availability feature </docs/platform/concepts/beta_services>`. If you're interested in trying out this feature, contact the sales team at `[email protected] <mailto:[email protected]>`_.

.. note::
- Cross cluster replication feature for Aiven for OpenSearch is a beta release.
- Cross cluster replication is not available for Hobbyist and Startup plans.

- The cross cluster replication feature for Aiven for OpenSearch is a beta release.
- Cross cluster replication is not available for the Hobbyist and Startup plans.

Follow these steps to set up :doc:`cross cluster replication </docs/products/opensearch/concepts/cross-cluster-replication-opensearch>` for your Aiven for OpenSearch service:

1. Log in to the `Aiven Console <https://console.aiven.io/>`_, and select the Aiven for OpenSearch service for which you want to set up cross cluster replication.
2. In the service's **Overview** screen, scroll to the **Cross cluster replications** section and select **Create follower**.
3. In the **Create OpenSearch follower cluster** page,
3. In the **Create OpenSearch follower cluster** page:

* Enter a name for the follower cluster
* Select the desired cloud provider
* Select the desired cloud region
* Select the service plan
* Enter a name for the follower cluster.
* Select the desired cloud provider.
* Select the desired cloud region.
* Select the service plan.

.. note::
During creation, the follower cluster service must have the same service plan as the leader cluster service. This ensures the follower cluster service has as much memory as the leader cluster. You can change the service plan as required later.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ To check the TLS versions clients are connecting with, you can query the ``pg_st
.. code::
datname │ pid │ usesysid │ usename │ application_name │ client_addr │ ssl │ version │ cipher │ backend_start
datname │ pid │ usesysid │ usename │ application_name │ client_addr │ ssl │ version │ cipher │ backend_start
──────────┼─────────┼──────────┼──────────┼──────────────────┼────────────────┼─────┼─────────┼────────────────────────┼───────────────────────────────
defaultdb │ 2172508 │ 16412 │ avnadmin │ psql │ 192.178.0.1 │ t │ TLSv1.3 │ TLS_AES_256_GCM_SHA384 │ 2022-09-12 12:39:12.644646+00
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,15 @@ PgBouncer is a lightweight connection pooler for PostgreSQL® with low memory re

PgBouncer offers several methods when rotating connections:

Session pooling
This is the most permissive method. When a client connects, it gets assigned with a server connection that is maintained as long as the client stays connected. When the client disconnects, the server connection is put back into the pool. This mode supports all PostgreSQL features.
- **Session pooling:** This is the most permissive method. When a client connects, it gets assigned with a server connection that is maintained as long as the client stays connected. When the client disconnects, the server connection is put back into the pool. This mode supports all PostgreSQL features.

Transaction pooling
A server connection is assigned to a client only during a transaction. When PgBouncer notices that the transaction is over, the server connection is put back into the pool.
- **Transaction pooling:** A server connection is assigned to a client only during a transaction. When PgBouncer notices that the transaction is over, the server connection is put back into the pool.

.. warning::

This mode breaks a few session-based features of PostgreSQL. Use it only when the application cooperates without using the features that break. For incompatible features, see `PostgreSQL feature map for pooling modes <https://www.pgbouncer.org/features>`_.
This mode breaks a few session-based features of PostgreSQL. Use it only when the application cooperates without using the features that break. For incompatible features, see `PostgreSQL feature map for pooling modes <https://www.pgbouncer.org/features>`_.

Statement pooling
This is the most restrictive method, which disallows multi-statement transactions. This is meant to enforce the ``autocommit`` mode on the client and is mostly targeted at PL/Proxy.
- **Statement pooling:** This is the most restrictive method, which disallows multi-statement transactions. This is meant to enforce the ``autocommit`` mode on the client and is mostly targeted at PL/Proxy.

Handling connection pooling issues
----------------------------------
Expand Down
117 changes: 59 additions & 58 deletions docs/tools/terraform/howto/config-postgresql-provider.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,70 +12,71 @@ The new provider must be added to the ``required_providers`` block in the Terraf

1. This example shows how to add the PostgreSQL provider (source: ``cyrilgdn/postgresql``) along with the Aiven Terraform Provider (source: ``aiven/aiven``).

.. code:: terraform
terraform {
required_providers {
aiven = {
source = "aiven/aiven"
version = ">=4.0.0, < 5.0.0"
.. code:: terraform
terraform {
required_providers {
aiven = {
source = "aiven/aiven"
version = ">=4.0.0, < 5.0.0"
}
postgresql = {
source = "cyrilgdn/postgresql"
version = "1.16.0"
}
}
postgresql = {
source = "cyrilgdn/postgresql"
version = "1.16.0"
}
}
}
2. If the PostgreSQL provider is used on its own, you can provide the Aiven for PostgreSQL service connection details as follows:

.. code:: terraform
provider "postgresql" {
host = "pg-serivicename-projectname.aivencloud.com"
port = 12691
database = "defaultdb"
username = "avnadmin"
password = "postgres_password"
sslmode = "require"
connect_timeout = 15
}
Optionally, when the Aiven for PostgreSQL service is created within the same Terraform project, the values required to configure the PostgreSQL provider can be passed using references to the resource, as shown in the code below:
.. code:: terraform
.. code:: terraform
resource "aiven_pg" "demo-pg" {
project = var.project_name
cloud_name = "google-asia-southeast1"
plan = "business-8"
service_name = "demo-pg"
termination_protection = true
}
# PostgreSQL provider is configured with references to the aiven_pg.demo-pg resource.
provider "postgresql" {
host = aiven_pg.demo-pg.service_host
port = aiven_pg.demo-pg.service_port
database = aiven_pg.demo-pg.pg.dbname
username = aiven_pg.demo-pg.service_username
password = aiven_pg.demo-pg.service_password
sslmode = "require"
connect_timeout = 15
}
provider "postgresql" {
host = "pg-serivicename-projectname.aivencloud.com"
port = 12691
database = "defaultdb"
username = "avnadmin"
password = "postgres_password"
sslmode = "require"
connect_timeout = 15
}
Optionally, when the Aiven for PostgreSQL service is created within the same Terraform project, the values required to configure the PostgreSQL provider can be passed using references to the resource, as shown in the code below:

.. code:: terraform
resource "aiven_pg" "demo-pg" {
project = var.project_name
cloud_name = "google-asia-southeast1"
plan = "business-8"
service_name = "demo-pg"
termination_protection = true
}
# PostgreSQL provider is configured with references to the aiven_pg.demo-pg resource.
provider "postgresql" {
host = aiven_pg.demo-pg.service_host
port = aiven_pg.demo-pg.service_port
database = aiven_pg.demo-pg.pg.dbname
username = aiven_pg.demo-pg.service_username
password = aiven_pg.demo-pg.service_password
sslmode = "require"
connect_timeout = 15
}
3. Create a PostgreSQL role called ``test_role`` using the Terraform resource ``postgresql_role.my_role``.

.. code:: terraform
resource "postgresql_role" "my_role" {
name = "test_role"
}
.. note::

For the full documentation of the ``Aiven Terraform Provider`` refer to `Aiven provider documentation <https://registry.terraform.io/providers/aiven/aiven/latest/docs>`_.

For the full list of resources available in ``PostgreSQL provider`` refer to `PostgreSQL provider documentation <https://registry.terraform.io/providers/cyrilgdn/postgresql/latest/docs>`_.

.. code:: terraform
resource "postgresql_role" "my_role" {
name = "test_role"
}
.. note::

For the full documentation of the ``Aiven Terraform Provider`` refer to `Aiven provider documentation <https://registry.terraform.io/providers/aiven/aiven/latest/docs>`_.

For the full list of resources available in ``PostgreSQL provider`` refer to `PostgreSQL provider documentation <https://registry.terraform.io/providers/cyrilgdn/postgresql/latest/docs>`_.


4 changes: 2 additions & 2 deletions docs/tools/terraform/howto/terraform-logging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ If you are encountering issues when deploying your Aiven service via Terraform,

3. To generate an example of the core and provider logs,run:

.. code:: Shell
.. code:: Shell
terraform refresh
terraform refresh
30 changes: 15 additions & 15 deletions docs/tools/terraform/howto/update-deprecated-resources.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@ Use the following steps to migrate from resources that have been deprecated or r
In the following example, the ``aiven_database`` field is migrated to the new ``aiven_pg_database`` field for an Aiven for PostgreSQL® service.

1. Replace references to the deprecated field with the new field. In the following file ``aiven_database`` was replaced with ``aiven_pg_database``:

.. code::
- resource "aiven_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
+ resource "aiven_pg_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
.. code::
- resource "aiven_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
+ resource "aiven_pg_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
2. View a list of all resources in the state file:

Expand Down
10 changes: 5 additions & 5 deletions docs/tools/terraform/howto/upgrade-provider-v1-v2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -54,18 +54,18 @@ Upgrade Terraform 0.12 to 0.13
Between v0.12 and v0.13, the syntax of Terraform files changed. If you have the older syntax,
follow these steps to get the updated syntax:


1. Upgrade your modules first by installing Terraform v0.13.x (i.e. 0.13.7): ``tfenv install 0.13.7 && tfenv use 0.13.7`` and then using ``0.13upgrade`` tool.

2. Update ``required_version`` from ``>= 0.12`` to ``>= 0.13`` in the requirements block.

3. Update the existing state file, by running:
``terraform state replace-provider registry.terraform.io/-/aiven registry.terraform.io/aiven/aiven``
you will replace old Aiven terraform provider references to the new format.

``terraform state replace-provider registry.terraform.io/-/aiven registry.terraform.io/aiven/aiven``
you will replace old Aiven terraform provider references to the new format.

4. Run ``terraform 0.13upgrade`` to see any additional fixes recommended by HashiCorp.
If you are using more providers than Aiven provider you most likely need to upgrade them as well.
More information `here <https://www.terraform.io/upgrade-guides/0-13.html>`_.
If you are using more providers than Aiven provider you most likely need to upgrade them as well.
More information `here <https://www.terraform.io/upgrade-guides/0-13.html>`_.

5. Run ``terraform init -upgrade``

Expand Down
28 changes: 14 additions & 14 deletions docs/tools/terraform/howto/upgrade-provider-v3-v4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,20 +51,20 @@ In this example, the ``aiven_database`` field is updated to the service-specific

1. Update ``aiven_database`` references to ``aiven_pg_database`` as in this example file:

.. code::
- resource "aiven_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
+ resource "aiven_pg_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
.. code::
- resource "aiven_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
+ resource "aiven_pg_database" "mydatabase" {
project = aiven_project.myproject.project
service_name = aiven_pg.mypg.service_name
database_name = "<DATABASE_NAME>"
}
2. View a list of all resources in the state file:

Expand Down
Loading

0 comments on commit a65191c

Please sign in to comment.