Using a9s PostgreSQL
This chapter describes how to use a9s PostgreSQL.
Use a9s PostgreSQL with an App
To use the a9s PostgreSQL with an app, follow the procedures in this section to create a Service Instance and bind the Service Instance to your app. For more information on managing Service Instances, see Managing Service Instances with the cf CLI.
View the a9s PostgreSQL Service
After the Data Service is installed, a9s-postgresql
and its Service Plans appear in your CF marketplace. Run
cf marketplace
to see the service listing:
$ cf marketplace
Getting services from marketplace in org test / space test as admin...
OK
service plans description
a9s-postgresql postgresql-single-small, postgresql-cluster-small, postgresql-single-big, postgresql-cluster-big This is the a9s PostgreSQL 13 service.
See the next section for instructions on creating PostgreSQL Service Instances based on the plans listed in the
cf marketplace
output.
Create a Service Instance
To provision a PostgreSQL database, run cf create-service
. For example:
cf create-service a9s-postgresql postgresql-single-small my-postgresql-service
Depending on your infrastructure and service broker usage, it may take several minutes to create the Service Instance.
Check the creation status using cf services
. This displays a list of all your Service Instances. To check the status
of a specific Service Instance, run cf service NAME-OF-YOUR-SERVICE
.
Bind an Application to a Service Instance
After you create your database, run cf bind-service
to bind the service to your application:
cf bind-service a9s-postgresql-app my-postgresql-service
Restage or Restart Your Application
To enable your app to access the Service Instance, run cf restage
or cf restart
to restage or restart your app.
Obtain Service Instance Access Credentials
After a Service Instance is bound to an application, the credentials of your PostgreSQL database are stored in the
environment variables of the application. Run cf env APP-NAME
to display the environment variables.
You can find the credentials in the VCAP_SERVICES key.
$ cf env a9s-postgresql-app
Getting env variables for app a9s-postgresql-app in org test / space test as admin...
OK
System-Provided:
{
"VCAP_SERVICES": {
"a9s-postgresql": [
{
"credentials": {
"host": "EXAMPLE-HOST",
"hosts": ["EXAMPLE-HOST"],
"name": "d92e2bd",
"password": "EXAMPLE-PASSWORD",
"port": 5432,
"uri": "EXAMPLE-URI",
"username": "EXAMPLE-USERNAME"
},
"label": "a9s-postgresql",
"name": "my-postgresql-service",
"plan": "postgresql-cluster-small",
"tags": [
"sql",
"database"
]
}
]
}
}
...
You can use the host
, username
and password
values to connect to your database with a PostgreSQL client. The
database is specified as name
, and this is the database that should be used to store the data.
The postgres
database is reserved for administrative use only and no data should be stored there.
Best Practices
There are some best practices for using service binding information in apps in a separate document.
Delete an a9s PostgreSQL Service Instance
Before deleting a Service Instance, you must backup data stored in your database. This operation cannot be undone and all the data is lost when the Service Instance is deleted.
Before you can delete a Service Instance, you must unbind it from all apps.
List Available Services
Run cf services
to list your available services.
$ cf services
Getting services in org test / space test as admin...
OK
name service plan bound apps last operation
my-postgresql-service a9s-postgresql postgresql-single-small a9s-postgresql-app create succeeded
This example shows that my-postgresql-service
is bound to the a9s-postgresql-app
app.
Unbind a Service Instance
Run cf unbind
to unbind the service from your app.
cf unbind-service a9s-postgresql-app my-postgresql-service
Delete a Service Instance
After unbinding the service, it is no longer bound to an application. Run cf delete-service
to delete the service:
cf delete-service my-postgresql-service
It may take several minutes to delete the service. Deleting a service deprovisions the corresponding infrastructure
resources. Run the cf services
command to view the deletion status.
Upgrade the Service Instance to another Service Plan
Once created, you can upgrade your Service Instance to another, larger service plan. A larger service plan provides more CPU, RAM and storage. For more information, see the Managing Service Instances with the cf CLI - Update a Service Instance documentation.
cf update-service my-postgresql-service -p a-bigger-plan
Configuring metrics intervals
It is possible to configure the collection of metrics groups to take place at specific intervals. Metrics groups are collections of related metrics. Each metric groups has a custom parameter that can be used to set its collection interval.
Intervals are in seconds and if the interval is set to 0
, the metric group is disabled.
Metric groups
Custom parameter name | Suggested (interval in seconds) | Default value (interval in seconds) | Description |
---|---|---|---|
metric_pg_database_size | 300 | 300 | This group lets you see how quickly your database is growing. |
metric_pg_stat_all_indexes | 30 | 0 | This group provides status information on all indexes. |
metric_pg_statio_all_indexes | 60 | 0 | This group provides information on index usage for all indexes. |
metric_pg_statio_all_tables | 30 | 0 | This group provides information on table usage for all tables. |
metric_pg_stat_all_tables | 120 | 0 | This group provides the status of all tables. |
metric_pg_stat_archiver_table | 300 | 0 | This group provides the archival status. Useful with continuous archiving enabled. |
metric_pg_stat_database | 120 | 0 | This group provides the general status of each database. |
metric_pg_stat_database_conflicts | 300 | 0 | This group provides insights on database conflicts. |
metric_pg_replication | 10 | 10 | This group provides the status of replication. Useful when the Service Instance is a replica set. |
metric_pg_node_status | 10 | 10 | This group provides metrics based on node state |
Metric group patterns
Each metric group has a set of patterns that describe the metrics contained in each group.
These metrics are dynamic between the PostgreSQL versions, therefore some of them might differ based on the PostgreSQL version that is currently running on the Service Instance. In order to be sure, search into the documentation link provided in the metric item and confirm the information based on PostgreSQL metric and PostgreSQL version.
metric_pg_database_size
Metric Id | Type | Description |
---|---|---|
pg_database_size | Bigint (Bytes) | Database size. |
*.*.postgres.*.*.*.*.database.*.pg_database_size
metric_pg_stat_all_indexes
The pg_stat_all_indexes
view will contain one row for each index in the current database, showing statistics about
accesses to that specific index. The pg_stat_user_indexes
and pg_stat_sys_indexes
views contain the same
information, but filtered to only show user and system indexes respectively.
Metric Id | Type | Description |
---|---|---|
idx_scan | Bigint | Number of index scans initiated on this index. documentation |
idx_tup_read | Bigint | Number of index entries returned by scans on this index. documentation |
idx_tup_fetch | Bigint | Number of live table rows fetched by simple index scans using this index. documentation |
*.*.postgres.*.*.*.*.database.*.table.*.*.index.*.*.*.idx_scan
*.*.postgres.*.*.*.*.database.*.table.*.*.index.*.*.*.idx_tup_read
*.*.postgres.*.*.*.*.database.*.table.*.*.index.*.*.*.idx_tup_fetch
metric_pg_statio_all_indexes
The pg_statio_all_indexes
view will contain one row for each index in the current database, showing statistics about
I/O on that specific index. The pg_statio_user_indexes
and pg_statio_sys_indexes
views contain the same information,
but filtered to only show user and system indexes respectively.
Metric Id | type | Description |
---|---|---|
idx_blks_read | Bigint | Number of disk blocks read from all indexes on this table. documentation |
idx_blks_hit | Bigint | Number of buffer hits in all indexes on this table. documentation |
*.*.postgres.*.*.*.*.database.*.table.*.*.index.*.*.*.idx_blks_read
*.*.postgres.*.*.*.*.database.*.table.*.*.index.*.*.*.idx_blks_hit
metric_pg_statio_all_tables
The pg_statio_all_tables
view will contain one row for each table in the current database (including TOAST tables),
showing statistics about I/O on that specific table. The pg_statio_user_tables
and pg_statio_sys_tables
views
contain the same information, but filtered to only show user and system tables respectively.
Metric Id | type | Description |
---|---|---|
heap_blks_read | Bigint | Number of disk blocks read from this table.documentation |
heap_blks_hit | Bigint | Number of buffer hits in this table. documentation |
idx_blks_read | Bigint | Number of disk blocks read from all indexes on this table. documentation |
idx_blks_hit | Bigint | Number of buffer hits in all indexes on this table. documentation |
toast_blks_read | Bigint | Number of disk blocks read from this table's TOAST table (if any). documentation |
toast_blks_hit | Bigint | Number of buffer hits in this table's TOAST table (if any). documentation |
tidx_blks_read | Bigint | Number of disk blocks read from this table's TOAST table indexes (if any). documentation |
tidx_blks_hit | Bigint | Number of buffer hits in this table's TOAST table indexes (if any). documentation |
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.heap_blks_read
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.heap_blks_hit
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.idx_blks_read
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.idx_blks_hit
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.toast_blks_read
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.toast_blks_hit
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.tidx_blks_read
*.*.postgres.*.*.*.*.database.*.io_table.*.*.*.tidx_blks_hit
metric_pg_stat_all_tables
The pg_stat_all_tables
view will contain one row for each table in the current database (including TOAST tables),
showing statistics about accesses to that specific table. The pg_stat_user_tables
and pg_stat_sys_tables
views
contain the same information, but filtered to only show user and system tables respectively.
Metric Id | type | Description |
---|---|---|
seq_scan | Bigint | Number of sequential scans initiated on this table. documentation |
seq_tup_read | Bigint | Number of live rows fetched by sequential scans. documentation |
idx_scan | Bigint | Number of index scans initiated on this table. documentation |
idx_tup_fetch | Bigint | Number of live rows fetched by index scans. documentation |
n_tup_ins | Bigint | Number of rows inserted. documentation |
n_tup_upd | Bigint | Number of rows updated (includes HOT updated rows for < 17 and includes row updates counted in n_tup_hot_upd and n_tup_newpage_upd, and remaining non-HOT updates for ≥ 17). documentation |
n_tup_del | Bigint | Number of rows deleted. documentation |
n_tup_hot_upd | Bigint | Number of rows HOT updated (i.e., with no separate index update required). documentation |
n_live_tup | Bigint | Estimated number of live rows. documentation |
n_dead_tup | Bigint | Estimated number of dead rows. documentation |
last_vacuum | Timestamp With Time Zone | Last time at which this table was manually vacuumed (not counting VACUUM FULL). documentation |
last_autovacuum | Timestamp With Time Zone | Last time at which this table was vacuumed by the autovacuum daemon. documentation |
last_analyze | Timestamp With Time Zone | Last time at which this table was manually analyzed. documentation |
last_autoanalyze | Timestamp With Time Zone | Last time at which this table was analyzed by the autovacuum daemon. documentation |
vacuum_count | Bigint | Number of times this table has been manually vacuumed (not counting VACUUM FULL). documentation |
autovacuum_count | Bigint | Number of times this table has been vacuumed by the autovacuum daemon. documentation |
analyze_count | Bigint | Number of times this table has been manually analyzed. documentation |
autoanalyze_count | Bigint | Number of times this table has been analyzed by the autovacuum daemon. documentation |
*.*.postgres.*.*.*.*.database.*.table.*.*.*.seq_scan
*.*.postgres.*.*.*.*.database.*.table.*.*.*.seq_tup_read
*.*.postgres.*.*.*.*.database.*.table.*.*.*.idx_scan
*.*.postgres.*.*.*.*.database.*.table.*.*.*.idx_tup_fetch
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_tup_ins
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_tup_upd
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_tup_del
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_tup_hot_upd
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_live_tup
*.*.postgres.*.*.*.*.database.*.table.*.*.*.n_dead_tup
*.*.postgres.*.*.*.*.database.*.table.*.*.*.last_vacuum
*.*.postgres.*.*.*.*.database.*.table.*.*.*.last_autovacuum
*.*.postgres.*.*.*.*.database.*.table.*.*.*.last_analyze
*.*.postgres.*.*.*.*.database.*.table.*.*.*.last_autoanalyze
*.*.postgres.*.*.*.*.database.*.table.*.*.*.vacuum_count
*.*.postgres.*.*.*.*.database.*.table.*.*.*.autovacuum_count
*.*.postgres.*.*.*.*.database.*.table.*.*.*.analyze_count
*.*.postgres.*.*.*.*.database.*.table.*.*.*.autoanalyze_count
metric_pg_stat_archiver_table
The pg_stat_archiver
view will always have a single row, containing data about the archiver process of the cluster.
Metric Id | type | Description |
---|---|---|
failed_count | Bigint | Number of failed attempts for archiving WAL files. documentation |
archived_count | Text | Number of WAL files that have been successfully archived. documentation |
last_archived_time_in_seconds | Integer (seconds) | Time of the last successful archive operation. documentation |
wal_files_count | Integer | Amount of WAL files. |
last_archive_successful | Boolean (0 = success/1 = failed)` | Indicate if the last archive operation was successful. |
*.*.postgres.*.*.*.*.stat_archiver.failed_count
*.*.postgres.*.*.*.*.stat_archiver.archived_count
*.*.postgres.*.*.*.*.stat_archiver.last_archived_time_in_seconds
*.*.postgres.*.*.*.*.stat_archiver.wal_files_count
*.*.postgres.*.*.*.*.stat_archiver.last_archive_successful
metric_pg_stat_database
The pg_stat_database
view will contain one row for each database in the cluster, showing database-wide statistics.
Metric Id | type | Description | Versions |
---|---|---|---|
numbackends | Integer | Number of backends currently connected to this database. This is the only column in this view that returns a value reflecting current state; all other columns return the accumulated values since the last reset. documentation | all |
xact_commit | Bigint | Number of transactions in this database that have been committed. documentation | all |
xact_rollback | Bigint | Number of transactions in this database that have been rolled back. documentation | all |
blks_read | Bigint | Number of disk blocks read in this database. documentation | all |
blks_hit | Bigint | Number of times disk blocks were found already in the buffer cache, so that a read was not necessary (this only includes hits in the PostgreSQL buffer cache, not the operating system's file system cache). documentation | all |
tup_returned | Bigint | Number of rows returned by queries in this database. documentation | all |
tup_fetched | Bigint | Number of rows fetched by queries in this database. documentation | all |
tup_inserted | Bigint | Number of rows inserted by queries in this database. documentation | all |
tup_updated | Bigint | Number of rows updated by queries in this database. documentation | all |
tup_deleted | Bigint | Number of rows deleted by queries in this database. documentation | all |
conflicts | Bigint | Number of queries canceled due to conflicts with recovery in this database. (Conflicts occur only on standby servers; see pg_stat_database_conflicts for details.) documentation | all |
temp_files | Bigint | Number of temporary files created by queries in this database. All temporary files are counted, regardless of why the temporary file was created (e.g., sorting or hashing), and regardless of the log_temp_files setting. documentation | all |
temp_bytes | Bigint | Total amount of data written to temporary files by queries in this database. All temporary files are counted, regardless of why the temporary file was created, and regardless of the log_temp_files setting. documentation | all |
deadlocks | Bigint | Number of deadlocks detected in this database. documentation | all |
blk_read_time | Double Precision | Time spent reading data file blocks by backends in this database, in milliseconds. documentation | all |
blk_write_time | Double Precision | Time spent writing data file blocks by backends in this database, in milliseconds. documentation | all |
session_time | Double Precision | Time spent by database sessions in this database, in milliseconds (note that statistics are only updated when the state of a session changes, so if sessions have been idle for a long time, this idle time won't be included). | documentation |
active_time | Double Precision | Time spent executing SQL statements in this database, in milliseconds (this corresponds to the states active and fastpath function call in pg_stat_activity ). | documentation |
idle_in_transaction_time | Double Precision | Time spent idling while in a transaction in this database, in milliseconds (this corresponds to the states idle in transaction and idle in transaction (aborted) in pg_stat_activity ). | documentation |
sessions | Bigint | Total number of sessions established to this database. | documentation |
sessions_abandoned | Bigint | Number of database sessions to this database that were terminated because connection to the client was lost. | documentation |
sessions_fatal | Bigint | Number of database sessions to this database that were terminated by fatal errors. | documentation |
sessions_killed | Bigint | Number of database sessions to this database that were terminated by operator intervention. | documentation |
stats_reset | Timestamp With Time Zone | Time at which these statistics were last reset. documentation | ≥ 15 |
*.*.postgres.*.*.*.*.database.*.*.numbackends
*.*.postgres.*.*.*.*.database.*.*.xact_commit
*.*.postgres.*.*.*.*.database.*.*.xact_rollback
*.*.postgres.*.*.*.*.database.*.*.blks_read
*.*.postgres.*.*.*.*.database.*.*.blks_hit
*.*.postgres.*.*.*.*.database.*.*.tup_returned
*.*.postgres.*.*.*.*.database.*.*.tup_fetched
*.*.postgres.*.*.*.*.database.*.*.tup_inserted
*.*.postgres.*.*.*.*.database.*.*.tup_updated
*.*.postgres.*.*.*.*.database.*.*.tup_deleted
*.*.postgres.*.*.*.*.database.*.*.conflicts
*.*.postgres.*.*.*.*.database.*.*.temp_files
*.*.postgres.*.*.*.*.database.*.*.temp_bytes
*.*.postgres.*.*.*.*.database.*.*.deadlocks
*.*.postgres.*.*.*.*.database.*.*.blk_read_time
*.*.postgres.*.*.*.*.database.*.*.blk_write_time
*.*.postgres.*.*.*.*.database.*.*.session_time
*.*.postgres.*.*.*.*.database.*.*.active_time
*.*.postgres.*.*.*.*.database.*.*.idle_in_transaction_time
*.*.postgres.*.*.*.*.database.*.*.sessions
*.*.postgres.*.*.*.*.database.*.*.sessions_abandoned
*.*.postgres.*.*.*.*.database.*.*.sessions_fatal
*.*.postgres.*.*.*.*.database.*.*.sessions_killed
*.*.postgres.*.*.*.*.database.*.*.stats_reset
metric_pg_stat_database_conflicts
The pg_stat_database_conflicts
view will contain one row per database, showing database-wide statistics
about query cancels occurring due to conflicts with recovery on standby servers. This view will only contain
information on standby servers, since conflicts do not occur on master servers.
Metric Id | type | Description |
---|---|---|
confl_tablespace | Bigint | Number of queries in this database that have been canceled due to dropped tablespaces. documentation |
confl_lock | Bigint | Number of queries in this database that have been canceled due to lock timeouts. documentation |
confl_snapshot | Bigint | Number of queries in this database that have been canceled due to old snapshots. documentation |
confl_bufferpin | Bigint | Number of queries in this database that have been canceled due to pinned buffers. documentation |
confl_deadlock | Bigint | Number of queries in this database that have been canceled due to deadlocks. documentation |
*.*.postgres.*.*.*.*.conflicts.*.*.confl_tablespace
*.*.postgres.*.*.*.*.conflicts.*.*.confl_lock
*.*.postgres.*.*.*.*.conflicts.*.*.confl_snapshot
*.*.postgres.*.*.*.*.conflicts.*.*.confl_bufferpin
*.*.postgres.*.*.*.*.conflicts.*.*.confl_deadlock
metric_pg_replication
Metric Id | type | Description |
---|---|---|
replication.wal_receiver_count | Integer | Amount WAL receiver process running the master what sends data to the slave. |
replication.wal_sender_count | Integer | Amount of WAL sender process that run at the primary node. Each replication has its own. |
replication.replication_lag | Integer (seconds) | Amount of time since the pg_last_xact_replay_timestamp , that is the last transaction replayed during recovery. |
replication.replication_slots_count | Integer | The same as pg_replication_slots PostgreSQL property that this view provides a listing of all replication slots that currently exist on the database cluster. documentation |
replication.inactive_replication_slots_count | Integer | The amount of replication_slots_count in inactive state. |
replication.cluster_replication_slots_count | Integer | The amount of replication_slots_count that marches with the regex /^repmgr_slot_[0-9]+$/ . |
ha.master | Integer (1 = true/0 = false) | If it is a master node. |
ha.standby | Integer (1 = true/0 = false) | If it is a slave node. |
ha.wal_dir_size | Integer (Bytes) | Size of the WAL directory. |
*.*.postgres.*.*.*.*.replication.wal_receiver_count
*.*.postgres.*.*.*.*.replication.wal_sender_count
*.*.postgres.*.*.*.*.replication.replication_lag
*.*.postgres.*.*.*.*.replication.replication_slots_count
*.*.postgres.*.*.*.*.replication.inactive_replication_slots_count
*.*.postgres.*.*.*.*.replication.cluster_replication_slots_count
*.*.postgres.*.*.*.*.ha.master
*.*.postgres.*.*.*.*.ha.standby
*.*.postgres.*.*.*.*.ha.wal_dir_size
metric_pg_node_status
*.*.postgres.*.*.*.*.postgresql_info_status.blocked
Description of Metrics:
postgresql_info_status.blocked
indicates if any of the nodes has blocked
status that means that this node doesn't participate in cluster life.
This metric can be equal:
1
- blocked0
- unblocked
System Metrics
Aside from the metrics shown above, this Data Service also provides system metrics, common to all a9s Data Services. They can be seen in the Graphite metrics documentation.
Configuring metrics databases
By setting the metric_databases
custom parameter on a Service Instance it is
possible to control which database metrics are generated. The
metric_databases
parameter expects an array
of database names. If the
parameter is not set or the array is set to empty, then metrics will be collected
for all databases.
Add a Graphite Endpoint
Streaming of logs and metrics might not be available for your plan! If unsure, please check your plan description.
If you want to monitor your service with Graphite, you can set the custom parameter graphite
. It expects the host and
port where the Graphite metrics should be sent to.
For example, in order to send Graphite metrics to an endpoint yourspace.your-graphite-endpoint.com:12345
, you can use
the following command:
cf update-service my-instance -c '{ "graphite": "yourspace.your-graphite-endpoint.com:12345" }'
The endpoint would then receive metrics in the format:
<service_guid>.<service_type>.<host>.<metric> <metric value> <metric timestamp>
Metrics Frequency
By default, metrics will be emitted every 10
seconds. You can change the interval via the custom parameter
metrics_frequency
.
For example, in order to send Graphite metrics to an endpoint every minute, you would set the custom parameter
metrics_frequency
to 60
using the following command:
cf update-service my-instance -c '{ "metrics_frequency": 60 }'
You can also change the intervals of different metric groups and decide from which databases you require metrics from. To do this look in the Configuring metrics intervals and Configuring metrics databases sections.
Metrics Prefix
Depending on your graphite provider, you might need to prefix the metrics with a certain value, like an API key for
example. In this case you can leverage the custom parameter metrics_prefix
.
cf update-service my-instance -c '{ "metrics_prefix": "my-api-key-for-a-certain-provider" }'
The resulting metric path would have the format:
<metrics_prefix>.<service_guid>.<service_type>.<host>.<metric>
Cloud Foundry Org and Space Guid
The Platform Operators can enable support on a global level to prefix the Graphite metrics with the CloudFoundry organization and space. This means that all metrics of all Service Instances (not only yours!) contain that information.
In this case the Graphite metric paths have the following format:
<organization_guid>.<space_guid>.<service_guid>.<service_type>.<host>.<metric>
When you enable in addition the metrics_prefix
for your instance, you will
end up with the metric path format:
<metrics_prefix>.<organization_guid>.<space_guid>.<service_guid>.<service_type>.<host>.<metric>
Add a Syslog Endpoint
The cf update-service
command used with the -c flag
can let you stream your syslog to a third-party service. In this case, the command expects a JSON string containing the
syslog
key. A single endpoint item for syslog
can be provided, as well as an array of endpoints.
host
and port
are mandatory parameters.
The protocol
parameter is optional. The accepted values are:
udp
setsrfc
by default torfc3164
.tcp
setsrfc
by default torfc3164
.ssl-tcp
setsrfc
by default torfc6587
.- For
ssl-tcp
;ssl_cert
andssl_key
are required parameters. - If
ssl_verify
is set totrue
, thenssl_cacert
must also be provided.
- For
To remove all endpoints, simply set syslog
to []
.
rfc
valuesOptionally, the rfc
parameter can be explicitly overwritten.
Valid values: rfc3164
, rfc5424
and rfc6587
.
cf update-service my-service \
-c '{
"syslog": [
{
"host": "logs4.your-syslog-endpoint.com",
"port": "6514",
"protocol": "ssl-tcp",
"rfc": "rfc6587",
"ssl_cert": "-----BEGIN CERTIFICATE----- ... -----END CERTIFICATE-----",
"ssl_key": "-----BEGIN CERTIFICATE----- ... -----END CERTIFICATE-----",
"ssl_cacert": "-----BEGIN PRIVATE KEY----- ... -----END PRIVATE KEY-----",
"ssl_verify": "false"
}
]
}'
The legacy format to specify syslog endpoints (["hostname1:port1", "hostname2:port2"]
) is still supported.
The cf update-service
command used with the -c flag
can let you stream your syslog to a third-party service. In this case, the command expects a JSON string containing the
syslog
key.
cf update-service my-postgresql-service \
-c '{ "syslog": ["logs4.your-syslog-endpoint.com:54321"]}'
Cloud Foundry Application Security Groups
This topic describes how to check whether a security group was created.
Each a9s Data Service will automatically create and update Cloud Foundry security groups in order to protected Service Instances to be accessed by applications not running in the same Cloud Foundry applications space. To get a better understanding about Security Groups you can have a look on the Understanding Application Security Groups topic.