fog / fog-xenserver

Module for the 'fog' gem to support XENSERVER
MIT License
16 stars 22 forks source link

Refactoring Structure. Defining Compute inside XenServer #1

Closed plribeiro3000 closed 10 years ago

plribeiro3000 commented 10 years ago

I've started to change the structure so it would be more like stated on rubygems.

plribeiro3000 commented 10 years ago

@geemus , can you please take a look at this changes? I did not changed any logic, just the structure. Is this ok for you? Or you think we should keep it as it is in fog ?

plribeiro3000 commented 10 years ago

I will merge this so i can keep working. Let me know if you think this shouldn't be on master. :kissing_heart:

fernandes commented 10 years ago

uow :kissing_heart: hahahha

geemus commented 10 years ago

My preference would be for compute to contain xenserver still. The hope is that by doing this, we increase the likelihood of interoperability (by having something like the adapter pattern). I'm certainly happy to discuss further what issues you were having or what prompted the change though.

plribeiro3000 commented 10 years ago

I did this change so the structure would be more like the convention. With a gem named fog-xenserver, the expected would to require it like:

require 'fog/xenserver'

By having the Compute namespace before the Xenserver constant, we should move all the xenserver stuff into a compute folder, and then the require would be:

require 'fog/compute/xenserver'

unless we do some hack and create a file named xenserver inside the fog folder requiring the correct file.

I dont know what would be the best, but i do think, that the compute namespace here it kind of a confusion IMHO.

geemus commented 10 years ago

That makes sense. I guess my preference would be to leave the structure and add an (admittedly hacky) file to allow the expected load path. I realize this is awkward here, but helps us remain more consistent with main fog (at least for the time being).

plribeiro3000 commented 10 years ago

Ok, i will make a new pull request with this changes, Xenserver inside Compute and create the hacky file. =)

geemus commented 10 years ago

Great, thanks!

On Fri, Jun 20, 2014 at 4:27 PM, Paulo Henrique Lopes Ribeiro < notifications@github.com> wrote:

Ok, i will make a new pull request with this changes, Xenserver inside Compute and create the hacky file. =)

Reply to this email directly or view it on GitHub https://github.com/fog/fog-xenserver/pull/1#issuecomment-46728621.