James Shubin 1b01f908e3 Add resource auto grouping
Sorry for the size of this patch, I was busy hacking and plumbing away
and it got out of hand! I'm allowing this because there doesn't seem to
be anyone hacking away on parts of the code that this would break, since
the resource code is fairly stable in this change. In particular, it
revisits and refreshes some areas of the code that didn't see anything
new or innovative since the project first started. I've gotten rid of a
lot of cruft, and in particular cleaned up some things that I didn't
know how to do better before! Here's hoping I'll continue to learn and
have more to improve upon in the future! (Well let's not hope _too_ hard
though!)

The logical goal of this patch was to make logical grouping of resources
possible. For example, it might be more efficient to group three package
installations into a single transaction, instead of having to run three
separate transactions. This is because a package installation typically
has an initial one-time per run cost which shouldn't need to be
repeated.

Another future goal would be to group file resources sharing a common
base path under a common recursive fanotify watcher. Since this depends
on fanotify capabilities first, this hasn't been implemented yet, but
could be a useful method of reducing the number of separate watches
needed, since there is a finite limit.

It's worth mentioning that grouping resources typically _reduces_ the
parallel execution capability of a particular graph, but depending on
the cost/benefit tradeoff, this might be preferential. I'd submit it's
almost universally beneficial for pkg resources.

This monster patch includes:
* the autogroup feature
* the grouping interface
* a placeholder algorithm
* an extensive test case infrastructure to test grouping algorithms
* a move of some base resource methods into pgraph refactoring
* some config/compile clean ups to remove code duplication
* b64 encoding/decoding improvements
* a rename of the yaml "res" entries to "kind" (more logical)
* some docs
* small fixes
* and more!
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2015-09-25 01:16:03 -04:00
2015-09-25 01:16:03 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2015-09-25 01:16:03 -04:00
2016-01-08 02:43:38 -05:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-01-08 02:43:38 -05:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-01-04 21:00:13 -05:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2015-09-25 01:16:03 -04:00
2016-03-28 20:54:41 -04:00
2016-03-28 20:54:41 -04:00
2015-09-25 01:16:03 -04:00
2016-03-28 20:54:41 -04:00
2015-10-02 11:05:19 -04:00
2016-03-10 04:06:57 -05:00

mgmt: This is: mgmt!

Build Status Documentation IRC Jenkins COPR

Community:

Come join us on IRC in #mgmtconfig on Freenode! You may like the #mgmtconfig hashtag if you're on Twitter.

Questions:

Please join the #mgmtconfig IRC community! If you have a well phrased question that might benefit others, consider asking it by sending a patch to the documentation FAQ section. I'll merge your question, and a patch with the answer!

Quick start:

  • Either get the golang dependencies on your own, or run make deps if you're comfortable with how we install them.
  • Run make build to get a freshly built mgmt binary.
  • Run cd $(mktemp --tmpdir -d tmp.XXX) && etcd to get etcd running. The mgmt software will do this automatically for you in the future.
  • Run time ./mgmt run --file examples/graph0.yaml --converged-timeout=1 to try out a very simple example!
  • To run continuously in the default mode of operation, omit the --converged-timeout option.
  • Have fun hacking on our future technology!

Examples:

Please look in the examples/ folder for more examples!

Documentation:

Please see: DOCUMENTATION.md or PDF.

Roadmap:

Please see: TODO.md for a list of upcoming work and TODO items. Please get involved by working on one of these items or by suggesting something else! Feel free to grab one of the straightforward #mgmtlove issues if you're a first time contributor to the project or if you're unsure about what to hack on!

Bugs:

Please set the DEBUG constant in main.go to true, and post the logs when you report the issue. Bonus points if you provide a shell or OMV reproducible test case. Feel free to read my article on debugging golang programs.

Dependencies:

  • golang 1.4 or higher (required, available in most distros)

  • golang libraries (required, available with go get)

      go get github.com/coreos/etcd/client
      go get gopkg.in/yaml.v2
      go get gopkg.in/fsnotify.v1
      go get github.com/codegangsta/cli
      go get github.com/coreos/go-systemd/dbus
      go get github.com/coreos/go-systemd/util
    
  • stringer (required for building), available as a package on some platforms, otherwise via go get

      go get golang.org/x/tools/cmd/stringer
    
  • pandoc (optional, for building a pdf of the documentation)

  • graphviz (optional, for building a visual representation of the graph)

Patches:

We'd love to have your patches! Please send them by email, or as a pull request.

On the web:

Happy hacking!

Description
No description provided
Readme 12 MiB
Languages
Go 95%
Shell 2.3%
Yacc 0.9%
Makefile 0.8%
JavaScript 0.4%
Other 0.6%