MH AAIRS block

From MoodleDocs
MH AAIRS block
Type Blocks
Set N/A
Downloads Moodle plugins repo
Issues Moodle tracker
Discussion TBA
Maintainer(s) Itamar Tzadok

Installation

Git Clone

  • In the root of your Moodle install type the following command:
git clone git://github.com/itamart/moodle-block_mhaairs.git blocks/mhaairs.
  • Go to the blocks/mhaairs folder.
  • Type the following command (replace XX with your Moodle major version number; e.g. 29):
git checkout MOODLE_XX_STABLE

Download

  • Download the recent release for your Moodle version from one of the following locations:
https://github.com/itamart/moodle-block_mhaairs/releases
https://moodle.org/plugins/pluginversions.php?plugin=block_mhaairs
  • Extract into the 'blocks' subfolder of your Moodle install.
  • Rename the new folder to mhaairs.
  • Visit http://your-domain/admin to finish the installation.

Moodlerooms customer

  • Please contact Moodlerooms and ask them to install the MH-AAIRS moodle block on your instance.

Administration

The mhaairs block administration options can be found in the Administration block under Site administration > Plugins > Blocks > McGraw-Hill AAIRS.

mhaairs-admin-administration-options.png

  • Settings - The plugin site configuration settings.
  • Web service test client - Forms for testing the block web services.
  • Grade exchange logs - Index and management of existing grade exchange logs.
  • Reset caches - Resets the block's local caches.

Settings

mhaairs-admin-site-settings.png

SSL ONLY

Require secured connection for login validation and user info requests from Connect. Either the moodle server protocol or the Connect protocol must be https.

CUSTOMER NUMBER

Set the 'Customer Number' to value provided to you by MH Campus in a welcome email.

SHARED SECRET

Set the 'Customer Secret' to value provided to you by MH Campus in a welcome email.

AVAILABLE SERVICES

One or more of the web services is currently down or your client access data are not correctly configured. Please contact McGraw-Hill help for further action.

  • Name: block_mhaairs_display_services
  • Default: Empty

HELP LINKS

Select this option if you wish help links to appear in the block appropriate to admin and teacher roles.

  • Name: block_mhaairs_display_helplinks
  • Default: Yes

GRADEBOOK SYNC

Gradebook Sync provides the ability to push scores from MH Campus directly to the Moodle gradebook. Note: If only Tegrity is enabled on your site, this setting is irrelevant.

  • Name: block_mhaairs_sync_gradebook
  • Default: Yes

LOCKING TYPE

With Gradebook Sync enabled, you may need to activate a locking method to prevent race conditions when the gradebook is updated. You can choose a locking type appropriate for your server setup.

  • Name: block_mhaairs_locktype
  • Default: No locking
  • Options:
    • No locking - No locking is done.
    • File locking - Creates a file in the Moodle data temp directory and uses the handler as the locking indicator.
    • Redis locking - Redis (http://redis.io/) is an open source (BSD licensed), in-memory data structure store, used as database, cache and message broker. It supports data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs and geospatial indexes with radius queries. Redis has built-in replication, Lua scripting, LRU eviction, transactions and different levels of on-disk persistence, and provides high availability via Redis Sentinel and automatic partitioning with Redis Cluster.

GRADE EXCHANGE LOG

Log grade exchange raw data for debugging purposes. Should be disabled on production sites. Log files are stored in moodledata directory [moodledata]/mhaairs. Every individual web service request generates a separate log file with the filename format 'mhaairs_year-month-day_hour-min-sec_randomkey.log'.

  • Name: block_mhaairs_gradelog
  • Default: No

Web service test client

Admins can simulate external access to the plugin web services by using the plugin's web service client forms. Warning: The web service test client executes the functions for REAL. Do not use on production sites. The Function… dropdown displays a list of the plugin's web service functions that can be tested via the client.

mhaairs-admin-web-service-test-client-01.png

Selecting a function will open the proper form for entering the service parameters. For example, selecting the update_grade function will open the following form:

mhaairs-admin-web-service-test-client-02.png

The Web service test client section is shared by all functions and allows you to select the target protocol and response format. By default these are REST and JSON respectively. The test client currently supports only REST protocol. It supports JSON and XML response formats.

mhaairs-admin-web-service-test-client-03.png

The Authentication section is also shared by all functions and allows you to enter the authentication parameters. By default the client expects a token authentication. The token must be generated for the designated user by admin at Site administration ► Plugins ► Web services ► Manage tokens. Alternatively you can switch to the Username/Password method and enter the username and password of the designated user.

mhaairs-admin-web-service-test-client-04.png

The Service params section is function specific. In some functions the service params may consist of several sections for readability. You need to enter valid service params. For example:

mhaairs-admin-web-service-test-client-05.png

mhaairs-admin-web-service-test-client-06.png

Upon pressing the Execute button the service request will be executed. The service url and the response text will be displayed at the top of the form.

mhaairs-admin-web-service-test-client-07.png

Grade exchange logs

Displays the list of existing log files that are generated when the 'Grade exchange log' setting in the plugin configuration is enabled.

mhaairs-admin-grade-exchange-logs-01.png

Currently the content of the log files cannot be viewed on from this page. Admin will have to open the file from its actual location in the designated moodledata directory [moodledata]/mhaairs. You can click the 'Delete all' link to delete all the existing log files.

File:mhaairs-admin-grade-exchange-logs-02.jpg

Reset caches

This plugin caches store the configured tools and help urls.

File:mhaairs-admin-reset-caches-01.jpg 

Admin can click the Reset link to clear the caches.

File:mhaairs-admin-reset-caches-02.jpg

The caches will be automatically regenerated as soon as the respective info is required.

AAIRS configuration

1. Login to your MH Campus account as the admin.

2. Click 'Manage AAIRS' to open the AAIRS interface.

File:aairs-config-admin-dashboard.png

3. Edit the Authorization section.

File:aairs-config-authorization1.png

4. Drag the 'Custom' box from 'Manual Configuration' into the 'Currently Used Connectors' area.

File:aairs-config-authorization2.png

5. Enter the following parameters in the custom connector form:

server=YOUR-MOODLE-SERVER-URL;block_name=mhaairs;secret=YOUR-MHAAIRS-SECRET;protocol=YOUR-PREFERRED-PROTOCOL 
    • Replace YOUR-MOODLE-SERVER-URL with the actual url of your moodle server.
    • Replace YOUR-SHARED-SECRET with the shared secret provided to you by MH Campus in a welcome email.
    • Replace YOUR-PREFERRED-PROTOCOL with the protocol you use on your moodle server, either https or http.
File:aairs-config-authorization3.png

6. Click 'Save' in the custom connector form to save the Moodle connector configuration. 7. Click 'Save & Continue'.

File:aairs-config-authorization4.png