Moodle Community Hub / Network coming together (with multi-auth, web services)

Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martín Langhoff -
Number of replies: 27
Brief update from the NZ front!

Donal, Jonathan and I are hacking away crazy at the Moodle Network (formerly known as Moodle Community Hub). It includes the multi-auth refactor (done), a rather cool WS/RPC layer (done) and is now to the point where you can set things up trivially in the admin area to get SSO across 2 Moodles.

We are gearing up to be ready for a demo for Friday. Who said panic? wink

The code is based on the early betas of 1.7. If you want to give it a test drive, or look at it a bit, and you can find it at http://git.catalyst.net.nz/gitweb?p=moodle-r2.git;a=shortlog;h=mdl17-mnet - you can click on 'snapshot' to download it. Or use cogito to get hold of it.

From that same repo you can get the mdl17-mnet-rpc and mdl17-mnet-multiauth which have only the RPC and the Auth code.

Once things settle a bit we'll be looking into merging the multiauth and rpc parts into HEAD. I am actually pretty happy with how this is shaping up... big grin
Average of ratings: -
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Art Lader -
OMG Martin,

That is a huge development. Talk about taking things to the next level. Wow...

Thanks for the time and effort you guys are putting into this and for update. Much appreciated!

Regards,
Art
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Timothy Takemoto -
Martin,
"The Moodle Network".... I remember that there was some discussion as to whether it would be a hub or p2p or both. Does the change of name indicate a move more towards p2p? 
This will be a major reason to upload to whatever version it becomes a part of. Looking forward to it.  
Timothy
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Ludo (Marc Alier) -
Keept it up Martin!
An Good Luck in friday's demo.
Ludo
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Myles Carrick -
Nice work, Martín.

At the Sydney Moodle Conf I heard from you about this but couldn't see relevance for my (mostly K-12) organisation... then this month we merged with another school... both of us being heavy Moodlers... We were just chatting today about this potential today!

Can't wait to see it in action!

MC


BTW Any chance of seeing the answers you guys came up with for the many questions raised in the docs?
(http://docs.moodle.org/en/Multi_Authentication)


In reply to Myles Carrick

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martín Langhoff -
Myles,

good to see you in the forums! Thinking of the questions raised in the docs... we didn't have to come up with any answers wink We implemented the ability to run more than one kind of plugin at the same time, but not the "many instances of the same plugin".

In other words, there is one Database plugin, and you can run it alongside the LDAP and email plugins. But you cannot have 3 database plugins configured differently at teh same time. Only one of each.

This simplifies things a lot in Moodel core and, to be frank, many plugins don't make sense to have multiple instances of. For those that do (like ldap and database) the "multiple backends" feature can be implemented inside the plugin itself.
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Iñaki Arenaza -
Picture of Core developers Picture of Documentation writers Picture of Peer reviewers Picture of Plugin developers

Thinking of the questions raised in the docs... we didn't have to come up with any answers

I'd say this is not true smile You have implicitly answered this two at least:

  • Can 'manual' (now called 'internal') be disabled?

  • Should 'manual' auth type be handled separately from all this multi-auth mess?

and partially this one:

  • If we store the 'prefix_auth_intance.id' value in the 'prefix_user.auth' field as suggested above, what should we do when we remove that auth instance from our system?

(substitute 'prefix_auth_instance.id' with 'auth', 'remove' with 'disable' and 'auth instance' with 'auth type' and the question is still valid in your current scheme).

I don't know your answers right now (I haven't had a look at the code so far), but I'm pretty sure you choosed one way or the other smile

Saludos. Iñaki.

In reply to Iñaki Arenaza

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martín Langhoff -

Hola Iñaki! If I try and answer them more explicitly... reordering and rewording ...

What should we do when we disable that auth instance from our system?

The users are not deleted, but are not allowed to login either. This can be used as a temporary measure to disable logins from a given plugin.

Can 'manual'/'internal' be disabled?

I would say no -- it would lock-out the standard admin account. Having said that, I think the current multi-auth code lets you disable it (ducks).

Should 'manual' auth type be handled separately from all this multi-auth mess?

Except than for being always-on... no.

(BTW, I've seen your patch to git-cvsimport -- good stuff!)

In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martin Dougiamas -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
Yes, it's great to see this progressing!

Just to clarify the naming though, because the hub name is not deprecated at all:

Moodle Networking: a way to network two or more Moodles
Moodle Hub: a Moodle server set up as a destination for other Moodles via Moodle Networking

ie as a Moodle admin you will see a list of Hubs to connect to. "The" Moodle Network doesn't exist as such, but there *will* be a central list of hubs maintained at moodle.org.
Average of ratings: Useful (1)
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Just to be clear....

Is this going to cover the WS "basics" (for want of a better word)? I'm thinking user creating, course creation etc etc.

Also will there be any provision for synchronizing moodle user databases, ie, in a cluster of moodles if you create a profile in one it will be reflected (or available) in others.

FWIW, if this kind of thing is not in your requirements I will be happy to get involved and do some of this work based on what you have started as I was messing around with this already - but you guys are just too good for me big grin
In reply to Howard Miller

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martín Langhoff -
Hi Howard -

it provides the WS "infrastructure". Some of the 'basics' are there or are mostly trivial, and yet some are rather complex to do "right". In most cases, we need to abstract them a bit (so yes! help will be welcome).

For example, right now course creation would be mostly trivial to abstract. And a fully-working user creation and updates will probably be quite a bit harder.

But we need to get on to do all those interesting bits on internals...
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Ji Ming -

Martin, would this network run in the order of the old Fidonet, GT Power, Telnet and Wildcat BBS networks where a mail or file hub system is used? I used to be a major hub in Asia for some of these networks before the Internet expanded. I would be happy to help in the testing.

James

In reply to Ji Ming

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Martín Langhoff -
Hi James,

thanks for the offer! We will need testers pretty soon wink On the other hand, it doesn't really need central servers, as it is quite distributed in its topology.
In reply to Martín Langhoff

Re: Moodle Community Hub / Network coming together (with multi-auth, web services)

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Yes - it did come as a bit of a surprise that none of those functions were abstracted already. Of course, this is an opportunity to create a programming api as well as a WS api as, I believe, a common library would be needed for all these functions anyway.
In reply to Martín Langhoff

Moodle Community Hub / Network - Progress update

by Martín Langhoff -
There you go, I've added yet another wiki page (is this addictive?) to track our progress on the final stretch. Right now, we have Donal McMullan, Jonathan Harker and myself hacking on this.

The wiki page is:
http://docs.moodle.org/en/Community_hub_progress

General functionality is complete, though some config screens are very raw (and yet others quite polished). Looking forward we have

* Polish configuration aspects
* Polish some usability aspects
* More meaningful errors for end users - and easier to debug
* Some internal changes
* Some bugfixing (not many so far - cross fingers!)
* Get some extra eyes on this and aim for a merge!
-- MultiAuth is 99% ready - reviews and testers welcome
-- RPC aspects are 90% ready - will be looking for review soon, testers welcome
-- Hub Services (SSO and Enrolment) are 80% ready - undergoing minor rework and fixups

We'll add a section there now for testers / reviewers...
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - Progress update

by Martín Langhoff -
Quick update: we are merging this into HEAD! The whole of Moodle Network will be included in 1.8. I will be working some very long days on this this week and next week.

Wohoo!

(Note! There are still quite a few things to do in our list. We'll merge into HEAD as the are complete, and we are all happy with the state of the code.)
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - Progress update

by Art Lader -
Martin,

Thank you for posting these updates. And thanks for all the work you guys have put into this. I am so looking foward to this feature. I know that many others must be, too.

Regards,
Art


In reply to Martín Langhoff

Re: Moodle Community Hub / Network - Progress update

by Martín Langhoff -
Merry Christmas!

We are working over the xmas break to get this stuff in shape and in HEAD. wink Yummmm...
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - Progress update

by Mike Finney -
Sorry... I am jumping into this late in the game... so when the update to 1.8 comes out... I would be able to set it up as a "Community Hub?" THAT WOULD BE AWESOME!.. understand that what I am trying to do is create an avenue for fire departments and fire academies to share information and begin networking to work together. It sounds like you guys have developed the answer.
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - HowTo

by Martín Langhoff -
For those interested in playing with it, I've started drafting a HowTo here http://docs.moodle.org/en/Moodle_Network. The code isn't in HEAD yet, but we are working hard on that. If you want to test it, you can grab our development code at http://git.catalyst.net.nz/gitweb?p=moodle-r2.git;a=shortlog;h=mdl17-mnet - you can click on 'snapshot' to download it. Or use cogito to get hold of it.

With cogito, just do

cg-clone http://git.catalyst.net.nz/git/moodle-r2.git#mdl17-mnet
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - HowTo

by Julian Ridden -
Fantastic stuff. What a great Xmas pressie. smile

Let me know when it is in head and Ill add it to the Playpen site for users to play with.

In fact, should you feel like it (generous perhaps) I can even give you ftp access.

Have a great new year.
In reply to Julian Ridden

Re: Moodle Community Hub / Network - HowTo

by Martín Langhoff -
If you want a playpen right now, head over to http://git.catalyst.net.nz/gitweb?p=moodle-r2.git;a=shortlog;h=mdl17-mnet and follow the "snapshot" link. It is a v1.7 with the MNET patches wink

[Note! Don't use it for production, it won't upgrade nicely to 1.8 later unless you do some voodoo.]

Edit: actually, you'll need 2 playpens and this little howto http://docs.moodle.org/en/Moodle_Network
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - HowTo

by Martín Langhoff -
Wohoo! This is in HEAD now! Needs help testing and improving the doco. Drivers wanted... wink
In reply to Martín Langhoff

Re: Moodle Community Hub / Network - HELP

by Ludo (Marc Alier) -
Hi Martin,
we are trying to test the Moodle Network on a MacBook...
We have installed two moodle 1.8 Beta 2007020400 on the same apache servers (different directories, databases and cookies)...
We have followed the instructions on http://docs.moodle.org/en/Moodle_Network and so far we have reached step 2.7 ( Enable Networked Enrolment-> Click on Manage Moodle Network Enrolments to see a list of Moodle servers that offer this service to you) So far we cant see any Manage Moodle Network Enrolments thing .... sad

When trying to access a remote server via network block we get a nice error:
"RPC auth/mnet/user_authorise:ERROR Array:Array" on the peer moodle url.
Help! :_(
Cheers Ludo


In reply to Ludo (Marc Alier)

Re: Moodle Community Hub / Network - HELP

by Donal McMullan -
Hi Marc - sorry you're having problems with Moodle Network.

I just committed a change to CVS that should give you a more informative Error message than Array:Array. There was a bug in the error-handling there.

Can you update and let me know what happens?

Otherwise - I haven't yet been able to reproduce your error, so possibly it's an error in the docs! I'll look again tomorrow.

Cheers
In reply to Ludo (Marc Alier)

Re: Moodle Community Hub / Network - HELP

by Martín Langhoff -
Hey Ludo! After we wrote the Doco, I changed the names of some pages (to make them shorter & simpler) and I moved some stuff around. And that's what's happening -- that specific page has moved...

So now under the enrol/mnet plugin you only control the courses you allow external admins to enrol users on. For the courses you _are offered_, you have an option under the main mnet links in the admin menu, but I cannot remember the name. "Network enrollments"? Don't have access to a mnet site right now, otherwise I'd check -- but I'm sure you can find it wink