Yml problem in 610


#1

Dears,

anybody had any luck in using ror with es610? For a ror configuration that was fine in es600, in es610 I’m getting the following exception:

  SettingsException[Failed to load settings from [elasticsearch.yml]]; nested: IllegalStateException[only value lists are allowed in serialized settings];

It seems that the configuration parser was changed in es610 and no longer accepts key:value pairs inside lists (i.e. the above exception is thrown when parsing entries inside access_control_rules).

Any ideas for a workaround?


(Simone Scarduzio) #2

Hello @tmf! Thanks for reporting this.

  • Can you give us an example of the minimal settings that reproduce this error?
  • Does this error still appears if you move your ROR settings into the conf/readonlyrest.yml file (which is highly recommended for security reasons)?

#3

Dear Simone,

thanks for a prompt answer! Moving the configuration into conf/readonlyrest.yml fixes the problem.

Minimal configuration to trigger this is rather simple:

readonlyrest:
  enable: true
  access_control_rules:
      - name: "1"
        type: allow

(should be placed inside elasticsearch.yml)

BTW I’ve noticed another small thing - names should be strings, so no more ‘name: 1’. The latter causes ‘java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String’ exception.