cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mikhail Stepura (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-5958) "Unable to find property" errors from snakeyaml are confusing
Date Tue, 03 Sep 2013 04:11:52 GMT


Mikhail Stepura commented on CASSANDRA-5958:

For example I have the following in my cassandra.yaml

oh: my
bla: bla

Then the stacktrace will be
ERROR 04:06:57 Fatal configuration error
org.apache.cassandra.exceptions.ConfigurationException: Invalid yaml. Please remove properties
[bla, oh] from your cassandra.yaml
        at org.apache.cassandra.config.YamlConfigurationLoader$MissingPropertiesChecker.check(
        at org.apache.cassandra.config.YamlConfigurationLoader.loadConfig(
        at org.apache.cassandra.config.DatabaseDescriptor.loadConfig(
        at org.apache.cassandra.config.DatabaseDescriptor.<clinit>(
        at org.apache.cassandra.service.CassandraDaemon.setup( ~[main/:na]
        at org.apache.cassandra.service.CassandraDaemon.activate(
        at org.apache.cassandra.service.CassandraDaemon.main( ~[main/:na]
Invalid yaml. Please remove properties [bla, oh] from your cassandra.yaml
Fatal configuration error; unable to start. See log for stacktrace.
> "Unable to find property" errors from snakeyaml are confusing
> -------------------------------------------------------------
>                 Key: CASSANDRA-5958
>                 URL:
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: J.B. Langston
>            Priority: Minor
>         Attachments: trunk-5958-skip-missing-properties.patch, trunk-5958-v2-print-all-invalid-properties.patch
> When an unexpected property is present in cassandra.yaml (e.g. after upgrading), snakeyaml
outputs the following message:
> {code}Unable to find property 'some_property' on class: org.apache.cassandra.config.Config{code}
> The error message is kind of counterintuitive because at first glance it seems to suggest
the property is missing from the yaml file, when in fact the error is caused by the *presence*
of an unrecognized property.  I know if you read it carefully it says it can't find the property
on the class, but this has confused more than one user.
> I think we should catch this exception and wrap it in another exception that says something
like this:
> {code}Please remove 'some_property' from your cassandra.yaml. It is not recognized by
this version of Cassandra.{code}
> Also, it might make sense to make this a warning instead of a fatal error, and just ignore
the unwanted property.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message