CVS edit link for cmcintosh

I am developing a Services API module that exposes Aegir/Hosting functionality for external applications to communicate with.

Comments

cmcintosh’s picture

Assigned: Unassigned » cmcintosh
StatusFileSize
new4.39 KB

Hosting_services module will expose functionality provided by the Hosting module as well as Provisioning, all part of the Aegir Suite to be accessed via the Services API functionality that already exists. Following their api.

This initial upload is only a small part of what the module will be doing. It will be broken up into several modules:
Hosting_services - Will be providing basic status, small maintenance, reporting service calls
Site_service - Will provide service calls specific to just Sites and the tasks that can be performed on them.
Server_service - Will provide service calls specific to just Server Objects.
ETC.

This module is very much ALPHA and needs feature requests, bug reports, and the like to help continue to move it forward as something that could greatly help the community of aegir/drupal users.

cmcintosh’s picture

StatusFileSize
new26.2 KB

Fixed some bugs and added functionality from last version. Test this one please. Per mig5 / vertice changing namespace to hosting_serviceapi.

voxpelli’s picture

I would suggest taking a look at http://drupal.org/coding-standards as well as running your modules code through http://drupal.org/project/coder - it's important to have a unified coding style for others to be able to easily contribute to your project with eg. patches.

Some changes you should do are to indent with double spaces and not end your php-files with a ?>

The module seems like a good idea though - I would be happy to help you with feedback on it.

ddorian’s picture

+1

avpaderno’s picture

Status: Postponed (maintainer needs more info) » Needs work
Issue tags: +Module review

Hello, and thanks for applying for a CVS account. I am adding the review tags, and some volunteers will review your code, pointing out what needs to be changed.

As per http://drupal.org/cvs-application/requirements, the motivation message should be expanded to contain more details about the features of the proposed module, and it should include also a comparison with the existing solutions.

avpaderno’s picture

Assigned: cmcintosh » Unassigned
Macronomicus’s picture

+1 ...awesome!

gdd’s picture

voxpelli is correct about the coding style, this definitely needs to get fixed up.

Some other comments

- If all you are doing is checking user_access(), you don't actually need a separate access callback. You can just put the perm into the 'access arguments' key. See the comments service in the main services download for an example of this.

- You may also want to put your functions into an include file using the 'file' key. Again, there are many examples of this in the existing service implementations.

The coding style stuff is the big thing though.

Looking forward to seeing this happen, I think its a great idea.

cmcintosh’s picture

I wrote a long post about this, but it did not save it. Summary now as it is 2am, I will be reviewing this more tomorrow. Updating it with the new version, and posting back a better purpose statement for the module page.

cmcintosh’s picture

Right at this moment we are only checking user_access(), but I am working in checking for things like if a User is related to a client, if that client has permissions for site_x and task_x, etc. So there will be some stuff added into those functions, but just trying to get it prototyped up as quick as i can. Then look at adding complexity to it.

kvvnn’s picture

Subscribe. Want to help somehow.

avpaderno’s picture

Status: Needs work » Closed (won't fix)

There have not been replies in the last week. I am marking this application as won't fix.

cmcintosh’s picture

Assigned: Unassigned » cmcintosh
Status: Closed (won't fix) » Active

This is active, just because there has not been a post in a week does not mean it is dead. I am working on some of the syntax issues as well as the features I mentioned above. Please do not close this issue again as this is where i upload code for this and where i hope to get feedback for this module as well.

avpaderno’s picture

Status: Active » Closed (won't fix)

Please re-apply for a CVS account when you will be able to change the code as reported by voxpelli in comment #3.
The application has been already declined; changing the status of this report doesn't change the status of the application.

avpaderno’s picture

Assigned: cmcintosh » Unassigned
cmcintosh’s picture

Assigned: Unassigned » cmcintosh
Status: Closed (won't fix) » Active
StatusFileSize
new3.19 KB

Posted some of the work i have done, i believe i have a majority of the Grammatical issues corrected in this version of them module.

avpaderno’s picture

Assigned: cmcintosh » Unassigned
Status: Active » Needs review
avpaderno’s picture

Status: Needs review » Needs work
  1. See http://drupal.org/coding-standards to understand how a module should be written. In particular, see how the code should be formatted; comments need to be wrapped at column 80.
  2. /**
     * Implementation of hook_perm().
     */
    function hosting_serviceapi_perm() {
      return array(
      'load site data',
      'list sites',
      'create site',
      'backup',
      'clone',
      'delete',
      'disable',
      'enable',
      'import',
      'reset',
      'migrate',
      'restore',
      'verify'
     );
    }
    

    The last permission strings don't respect the format used by Drupal, which is <verb> <object>.

avpaderno’s picture

Status: Needs work » Closed (won't fix)

There have not been replies in the past week. I am marking this application as won't fix.

avpaderno’s picture

Component: Miscellaneous » new project application
Issue summary: View changes
Status: Closed (won't fix) » Closed (duplicate)
Related issues: +#822258: cmcintosh [cmcintosh]