Code Monkey home page Code Monkey logo

Comments (6)

raphink avatar raphink commented on September 27, 2024

That could be interesting indeed. Do you want to provide a PR with such a shellvar::bulk wrapping definition?

from puppet-augeasproviders_shellvar.

TomOnTime avatar TomOnTime commented on September 27, 2024

I would but... sadly I don't think I know enough Ruby to add a function that does that. If I did it as a define() then it wouldn't have the performance benefit.

from puppet-augeasproviders_shellvar.

raphink avatar raphink commented on September 27, 2024

I was actually thinking of a DSL define. How would you expect to see performance benefit?

from puppet-augeasproviders_shellvar.

raphink avatar raphink commented on September 27, 2024

On the performance issue: since puppet 3.4, augeasproviders use a shared Augeas handler for all resources. Hence, Augeas is only started once, and only parses target files twice as most (one read to fill the tree, a second read to calculate the diff if changes were made, and one write to flush changes if any). All you need is to use puppet 3.4+. The only overhead to using separate resources currently is stuff done entirely in memory, so the gain wouldn't be great.

from puppet-augeasproviders_shellvar.

TomOnTime avatar TomOnTime commented on September 27, 2024

Oh, so the optimization is already in there. That's awesome!

I'll see if I can work up a DSL define.

from puppet-augeasproviders_shellvar.

raphink avatar raphink commented on September 27, 2024

Actually, the lib still saves the Augeas tree once per modified resource (vs once per modified property). I don't think it would be good to change this though, as that would mean that if a resource produces an invalid tree, all resources of that file will fail to apply.

from puppet-augeasproviders_shellvar.

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.