Coder Social home page Coder Social logo

Comments (7)

soenkeliebau avatar soenkeliebau commented on June 22, 2024

I would indeed suggest splitting management features into an extra role or even playbook. I have in the past usually created specific playbooks for a restart and then called that from a shell script to facilitate usage.

I have pushed my rolling restart script to https://github.com/opencore/es_rollingrestart please feel free to reuse anything that might be useful.
This specific version has undergone some changes and not been thoroughly tested yet, if you notice any strange behavior or errors please let me know!

from ansible-elasticsearch.

jpcarey avatar jpcarey commented on June 22, 2024

@gingerwizard I created a similar 1.x rolling restart in the past, adding it to the task directory of the role. You could conditionally use include in the main playbook to trigger such a task. To me this makes more sense, having administrative tasks stored in the appropriate roles - but never called/included unless someone did so explicitly. I worked in a large organization where we had over 200 roles, and adding "extra" misc roles would just add clutter and confusion. Roles are generic, which would include their child tasks; a playbook should control how the role is used.

I wouldn't mind rewriting a rolling restart for 2.x, and adding in more protection (check minimum_master_nodes before running, fail if cluster ever goes red, etc). I hate the ansible uri module, but I didn't want to spend time to write it as a plugin or module.

from ansible-elasticsearch.

gingerwizard avatar gingerwizard commented on June 22, 2024

@jpcarey i think we should provide a separate role to do this. Anything in this role needs to be tested. Testing the functionality above will be tricky i suspect and add a maintenance cost that is likely to be unsustainable moving forward. This is also not supported in the puppet module - we are trying to aim for consistent behaviour here.

@jakommo @dliappis for input.

from ansible-elasticsearch.

jakommo avatar jakommo commented on June 22, 2024

I'm +1 for a dedicated role for these tasks

from ansible-elasticsearch.

strootman avatar strootman commented on June 22, 2024

+1 for separating.

Shoving too much stuff into a single role is a bad anti-pattern in ansible and ansible-galaxy. Makes re-usability take a dive.

from ansible-elasticsearch.

barryib avatar barryib commented on June 22, 2024

@gingerwizard @jpcarey I think this duplicate with #126?

from ansible-elasticsearch.

gingerwizard avatar gingerwizard commented on June 22, 2024

yes duplicate and agreed this will not be added. Thanks all.

from ansible-elasticsearch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.