ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
Cloud Formations for Curriculum TransformationTech-read ¡°Mashing up Services for Students¡±Alex Lee & Steve Nisbet, Learning & Research Technology. MMUhttp://lrt.mmu.ac.uk
Why change what we do?National Student Survey -  we¡¯ve actually asked students what they thinkLots of things they don¡¯t likeThey Do like the IT (certainly @ MMU in the main), more tech savvy?Some Unsurprising results perhaps ¨CDon¡¯t make me thinkDo give me what I wantI want it now!
EQALEQAL ¨C Complete review of teaching, support and administration of the University. Awareness of the need for change and new tools
Considerations for a solutionStudents require (recurring themes):ImmediacyPersonalisationSimplicity and ease in finding the information they wantA core set of vital information to help them study and take part in their courseResearch from Initial developments, lessons learned Student Portal Background services for WebCT (alex?)Identification of needs, software and partnersWhat do students actually need?Who /what can best provide (sometimes ¨C choice is limited) the informationHow can we tap into the software solutions to provide immediacy, personalisation in a seamless manner, simple for the student?
This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceCore distributed VLE architecturenews, eventsassessments, enrolmentsExam papers, digitized materialsLearning Objectsresource liststimetablesnews, eventsmoodle.mmu.ac.ukemail, storage
This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceConsistent mashups for every UnitUnit CodeMMU IDUnit AreaTimetableUnit CodeMMU IDHand-ins & marksUnit CodePodcastsUnit CodeReading ListsprovisioningUnit CodePast PapersScanned articlesOn/off-campus mediaUnit CodeMMU IDEnrolments
The key Problems then¡­How do we mash it all up?Systems often incompatible with each otherCorporate buy-in (we need that data)Common enforced tags (student id,unit_id)Get around the incompatibilitiesXML as a transitSSO (permissions, authorization and so on)
Services modelSeparate service oriented support platformEases the load on the mainline platformAggregates many different and occasionally incompatible database driven systems and delivers a standard output of XML based information for consuming blocks/plugins on the mainlinePortable data - isolated from major platform changes (should still work fine in Moodle 2 ¨C doesn¡¯t rely on schema changes Etc.)standard architecture (render anything not quite standard)Can be used to deliver to other platforms (W2C Widgets -> phones, CMS etc)Clear set of logs and statistics ¨C better measurement of useDR / resiliency potentially easier, but requires excellent network connections and hosting (shameless ULCC plug folks!)
This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceService-oriented architecturegetMoodleAreasgetMoodleAnnouncementsgetMoodleEventsgetEventsgetResourcesgetEnrolmentsgetAssessmentsgetCurriculumDetailsgetFeeStatusRESTRESTSOAPapis.mmuRESTPodcast ProducerRESTSOAPREST
This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licencegetResources web serviceLists tagged with Unit codeRESTIndividual items extracted from RDF & XHTML getResources called with: moodleauth usermoodle course id (unit code)datetime stampsecurity tokenCustom block+ To buy (3)Uploads tagged with Unit code+ Essential (8)apis.mmu+ Further (12)SOAPREST+ Podcasts (4)Web-service searchby Unit returns matching items + Exam papers (4)Search by Unit  codereturns RSS feedof matching podcastsgetResources returns:Atom feed with SSO item links(item provenance maintained in source element)Podcast ProducerRESTPodcasts tagged with Unit code
PC Availability Web Service
Rest Web Service Overview Can be accessed over http in a browser
 Allows focus on data!
 Very quick to develop
 Quick development time means innovation can happen quickly
 MMU web services output data in XML, RSS, and Atom
 Turns inconsistent formats into standard compliant formats
 Access data around firewalls and across  networks ¨C access anywhereREST Web Service Overview Can develop in a variety of languages ¨C MMU use C#
 Strict syntax ¨C good for critical services
 What version of .NET?
 Cool software or addons:
 Use SoapUI to check SOAP services to consume in .NET!
LinqPad
PasteXML as XElementConsuming RSS in Moodle Blockrequire_once($CFG->libdir .'/rsslib.php');require_once(MAGPIE_DIR .'rss_fetch.inc'); if (!defined('MAGPIE_OUTPUT_ENCODING')) {        define('MAGPIE_OUTPUT_ENCODING', 'utf-8');  // see bug 3107 }?ob_start(); $rss = fetch_rss(¡®http://apis.mmu.ac.uk/Service1.svc/getResources?¡¯.	¡®getResources?person=' . $USER->id . '&unit=' . $COURSE->shortname); $rsserror = ob_get_contents();ob_end_clean();?if ($rss === false) {	//handle error}?foreach ($rss->items as $item) {	//process the RSS!}?Personalised!Tagged!

More Related Content

LRT MoodleMootUK11 Unconf Presentation

  • 1. Cloud Formations for Curriculum TransformationTech-read ¡°Mashing up Services for Students¡±Alex Lee & Steve Nisbet, Learning & Research Technology. MMUhttp://lrt.mmu.ac.uk
  • 2. Why change what we do?National Student Survey - we¡¯ve actually asked students what they thinkLots of things they don¡¯t likeThey Do like the IT (certainly @ MMU in the main), more tech savvy?Some Unsurprising results perhaps ¨CDon¡¯t make me thinkDo give me what I wantI want it now!
  • 3. EQALEQAL ¨C Complete review of teaching, support and administration of the University. Awareness of the need for change and new tools
  • 4. Considerations for a solutionStudents require (recurring themes):ImmediacyPersonalisationSimplicity and ease in finding the information they wantA core set of vital information to help them study and take part in their courseResearch from Initial developments, lessons learned Student Portal Background services for WebCT (alex?)Identification of needs, software and partnersWhat do students actually need?Who /what can best provide (sometimes ¨C choice is limited) the informationHow can we tap into the software solutions to provide immediacy, personalisation in a seamless manner, simple for the student?
  • 5. This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceCore distributed VLE architecturenews, eventsassessments, enrolmentsExam papers, digitized materialsLearning Objectsresource liststimetablesnews, eventsmoodle.mmu.ac.ukemail, storage
  • 6. This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceConsistent mashups for every UnitUnit CodeMMU IDUnit AreaTimetableUnit CodeMMU IDHand-ins & marksUnit CodePodcastsUnit CodeReading ListsprovisioningUnit CodePast PapersScanned articlesOn/off-campus mediaUnit CodeMMU IDEnrolments
  • 7. The key Problems then¡­How do we mash it all up?Systems often incompatible with each otherCorporate buy-in (we need that data)Common enforced tags (student id,unit_id)Get around the incompatibilitiesXML as a transitSSO (permissions, authorization and so on)
  • 8. Services modelSeparate service oriented support platformEases the load on the mainline platformAggregates many different and occasionally incompatible database driven systems and delivers a standard output of XML based information for consuming blocks/plugins on the mainlinePortable data - isolated from major platform changes (should still work fine in Moodle 2 ¨C doesn¡¯t rely on schema changes Etc.)standard architecture (render anything not quite standard)Can be used to deliver to other platforms (W2C Widgets -> phones, CMS etc)Clear set of logs and statistics ¨C better measurement of useDR / resiliency potentially easier, but requires excellent network connections and hosting (shameless ULCC plug folks!)
  • 9. This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licenceService-oriented architecturegetMoodleAreasgetMoodleAnnouncementsgetMoodleEventsgetEventsgetResourcesgetEnrolmentsgetAssessmentsgetCurriculumDetailsgetFeeStatusRESTRESTSOAPapis.mmuRESTPodcast ProducerRESTSOAPREST
  • 10. This work is licensed under a Attribution-NonCommercial-ShareAlike 2.0 licencegetResources web serviceLists tagged with Unit codeRESTIndividual items extracted from RDF & XHTML getResources called with: moodleauth usermoodle course id (unit code)datetime stampsecurity tokenCustom block+ To buy (3)Uploads tagged with Unit code+ Essential (8)apis.mmu+ Further (12)SOAPREST+ Podcasts (4)Web-service searchby Unit returns matching items + Exam papers (4)Search by Unit codereturns RSS feedof matching podcastsgetResources returns:Atom feed with SSO item links(item provenance maintained in source element)Podcast ProducerRESTPodcasts tagged with Unit code
  • 12. Rest Web Service Overview Can be accessed over http in a browser
  • 13. Allows focus on data!
  • 14. Very quick to develop
  • 15. Quick development time means innovation can happen quickly
  • 16. MMU web services output data in XML, RSS, and Atom
  • 17. Turns inconsistent formats into standard compliant formats
  • 18. Access data around firewalls and across networks ¨C access anywhereREST Web Service Overview Can develop in a variety of languages ¨C MMU use C#
  • 19. Strict syntax ¨C good for critical services
  • 20. What version of .NET?
  • 21. Cool software or addons:
  • 22. Use SoapUI to check SOAP services to consume in .NET!
  • 24. PasteXML as XElementConsuming RSS in Moodle Blockrequire_once($CFG->libdir .'/rsslib.php');require_once(MAGPIE_DIR .'rss_fetch.inc'); if (!defined('MAGPIE_OUTPUT_ENCODING')) { define('MAGPIE_OUTPUT_ENCODING', 'utf-8'); // see bug 3107 }?ob_start(); $rss = fetch_rss(¡®http://apis.mmu.ac.uk/Service1.svc/getResources?¡¯. ¡®getResources?person=' . $USER->id . '&unit=' . $COURSE->shortname); $rsserror = ob_get_contents();ob_end_clean();?if ($rss === false) { //handle error}?foreach ($rss->items as $item) { //process the RSS!}?Personalised!Tagged!
  • 26. Results & StatsIn 227 days the web services have had 6,445,204 hits?getWebCTAreas 2,426,383getWebCTAnnouncements 1,600,768getFeeStatus 768,057getPCAvailability 306,403 This is only by widgets and My Mobile does not count My MMU getFeeEmail 3,506 (i.e. number of students who have requested full details)
  • 27. Useful Linkslrt.mmu.ac.uk//w2c = W2C widget developments
  • 29. Create a new project in Visual Studio with WCF Service Application Template
  • 30. Edit the config.xml file
  • 31. Delete the <service> and <servicebehavoiur> nodes
  • 32. Add the following code:Creating a REST Web Service in VS2008
  • 33. <service name="uk.ac.mmu.Service1" behaviorConfiguration="uk.ac.mmu.Service1Behavior">??????? <endpoint address="" binding="wsHttpBinding" contract="uk.ac.mmu.IService1">??????? </endpoint>??????? <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange"/><endpointBehaviors> <behavior name="webHttp"> <webHttp/> </behavior> </serviceBehaviors></endpointBehaviors>
  • 34. Create the InterfaceEdit Iservice.csusing System.ServiceModel.Web;[OperationContract, WebGet(UriTemplate = "getResources?person={user}&unit={unit}",ResponseFormat = WebMessageFormat.Xml)]Rss20FeedFormatter GetResourcesRss( string user, string unit);
  • 35. Reading XML ¨C Simple Waystring token = GetMD5Hash(developer + date + sharedsecret);egXml.Load('Service1.svc/getResources?person=' + person + 'unit=' + unit + 'developer=' + dev + 'dtm=' + date + 'token=' + token);nsm.AddNamespace("mmu", "http://apis.mmu.ac.uk/");XmlNodeListxnList = homeAreaXml.SelectNodes("//entry");foreach (XmlNodexn in xnList){ //do something!}
  • 36. Reading XML or RSS ¨C The LINQ Wayvar items = from item in feed.Items where trueorderbyitem.LastUpdatedTime.Date descending select item;foreach (SyndicationItem item in items) { //do something!}
  • 37. Outputting RSSSyndicationFeedresourcesFeed = new SyndicationFeed( "Resources for " + unit, "", null); Collection<SyndicationItem> items = new Collection<SyndicationItem>();item = new SyndicationItem( title1 , description1, new Uri(buyItemsFeed) ); items.Add(item);item = new SyndicationItem( title2 , description2, new Uri(essentialItemsFeed) ); items.Add(item);resourcesFeed.Items = items;//choose between outputting as RSS or AtomRss20FeedFormatter rss = new Rss20FeedFormatter(feed);return rss;

Editor's Notes

  • #5: We are often fixed in place by what our institutions have already bought into
  • #7: We have a policy that dictates ¡®every unit will have an entry in the MIS and an entry in Moodle¡¯
  • #8: Note tokenisation- equella
  • #14: LinqPad?PasteXML as XElement - powerful way to create a XML document in C# codeLinq to everything (Linq to Facebook, Linq to Amazon, Linq to AD, Linq to LDAPhttp://rshelton.com/archive/2008/07/11/list-of-linq-providers.aspx)