PostgreSQL supports and allows config entries, such as those in postgresql.conf, to be set to the empty string. The postgresql::server::config_entry defined type, however, requires String[1] when supplying string values. This doesn't allow for the empty string.
Expected Behavior
The postgresql::server::config_entry defined type should allow the empty string for its value parameter.
Steps to Reproduce
A typical use case is setting database-specific parameters that can be empty:
postgresql::server::config_entry { 'my_database.important_parameter':
value => ''
}
This should render as follows in postgresql.conf, which is valid from PostgreSQL's PoV.
my_database.important_parameter = ''
However, the Puppet agent run fails with an error message:
Postgresql::Server::Config_entry[my_database.important_parameter]: parameter 'value' expects a value of type Undef, String[1], Numeric, or Array[String[1]], got String
This is because the empty string is not allowed here.
Describe the Bug
PostgreSQL supports and allows config entries, such as those in
postgresql.conf
, to be set to the empty string. Thepostgresql::server::config_entry
defined type, however, requiresString[1]
when supplying string values. This doesn't allow for the empty string.Expected Behavior
The
postgresql::server::config_entry
defined type should allow the empty string for itsvalue
parameter.Steps to Reproduce
A typical use case is setting database-specific parameters that can be empty:
This should render as follows in
postgresql.conf
, which is valid from PostgreSQL's PoV.However, the Puppet agent run fails with an error message:
This is because the empty string is not allowed here.
Environment