crowbar/barclamp-crowbar — pull request #591 by cloudedge (2013-07-10 13:21:02+00:00)
Title: WIP role node-role upstream and downstream methods, added cycle model, BDD refactoring partial [1/2]

These commits include a partially complete BDD refactor. I'm bringing that in so that my other work can be exposed.

BDD TESTS ARE NOT 100% - that is OK for now. RSPEC & UNIT pass 100%.

These changes include several important WIP items

1) node-role upsteam/downstream relationship methods (instead of parent & children)
2) jig refactoring to just show needed methods (create/delete node, execute cycle)
3) added cycle model (similar to earlier run concept)
4) pseudo code for jig execute WIP
5) BDD refactoring to use record types instead of ad hoc calls (this is greatly simplifying the code)

I have updated the model DIA to show progress.

Also, added a doc page about design discussions.

BDD/attrib.erl | 7 +-
BDD/authenticate.erl | 41 +-
BDD/barclamp.erl | 28 +-
BDD/bdd.erl | 30 +-
BDD/bdd.hrl | 11 +-
BDD/bdd_catchall.erl | 63 +--
BDD/bdd_clirat.erl | 1 +
BDD/bdd_crud.erl | 101 +++++
BDD/bdd_restrat.erl | 462 +++++++-------------
BDD/bdd_utils.erl | 17 +-
BDD/bdd_webrat.erl | 135 +++---
BDD/crowbar.erl | 47 +-
BDD/crowbar_rest.erl | 112 ++---
BDD/dashboard.erl | 8 +-
BDD/deployment.erl | 23 +-
BDD/dev.erl | 1 +
BDD/eurl.erl | 139 +++---
BDD/features/authenticate.feature | 3 +-
BDD/features/barclamp_api.feature | 11 +-
BDD/features/deployment.feature | 9 +-
BDD/features/group.feature | 7 +-
BDD/features/scaffolds.feature | 14 +-
BDD/group_cb.erl | 94 ++--
BDD/groups.erl | 8 +-
BDD/jig.erl | 7 +-
BDD/json.erl | 1 -
BDD/node.erl | 7 +-
BDD/simple_auth.erl | 59 ++-
BDD/snapshot.erl | 7 +-
BDD/support.erl | 7 +-
BDD/swift.erl | 7 +-
BDD/users.erl | 5 +-
crowbar.yml | 3 +-
.../app/controllers/application_controller.rb | 34 +-
.../app/controllers/attribs_controller.rb | 2 +-
.../app/controllers/crowbar_controller.rb | 41 +-
.../app/controllers/groups_controller.rb | 2 +-
.../app/controllers/jigs_controller.rb | 2 +-
.../app/controllers/nodes_controller.rb | 4 +-
.../app/controllers/scaffolds/cycles_controller.rb | 20 +
crowbar_framework/app/models/attrib.rb | 12 -
crowbar_framework/app/models/barclamp.rb | 2 +-
.../app/models/barclamp_crowbar/jig.rb | 11 +-
crowbar_framework/app/models/cycle.rb | 29 ++
crowbar_framework/app/models/deployment.rb | 5 -
crowbar_framework/app/models/jig.rb | 43 +-
crowbar_framework/app/models/node_role.rb | 54 ++-
crowbar_framework/app/models/role.rb | 6 +-
crowbar_framework/app/models/role_require.rb | 4 +-
crowbar_framework/config/locales/crowbar/en.yml | 1 +
crowbar_framework/config/routes.rb | 3 +
.../db/migrate/20120731310000_create_node_roles.rb | 5 +-
.../migrate/20120731320000_create_role_requires.rb | 1 +
.../db/migrate/20120731330000_create_cycles.rb | 27 ++
.../db/migrate/20120801190200_scaffold_nav.rb | 2 +
crowbar_framework/test/test_helper.rb | 5 +-
crowbar_framework/test/unit/attrib_model_test.rb | 30 --
doc/devguide/model/00100_CB2_Design_Topics.md | 30 ++
doc/devguide/model/crowbar_model.dia | Bin 2926 -> 3071 bytes
59 files changed, 986 insertions(+), 864 deletions(-)

Crowbar-Pull-ID: a890e04c8d0b7039a3afeffa62dea1b9068745a2

Crowbar-Release: development