Auto Group

General plugins (Local) ::: local_autogroup
Maintained by Mark Ward, Emma Richardson, Arnaud Trouvé
A local plugin which automatically assigns enrolled users on a course into groups dependant upon information within their user profile. (Now with custom profile field support - called User Info Field in settings.) This plugin will create, update, and delete groups automatically to match the users on your course. All behaviour is event-driven and so will occur within page loads. The system can also monitor manual group setting changes and moderate them to ensure that groups are kept neat and tidy.
Latest release:
961 sites
595 downloads
71 fans
Current versions available: 7

A local plugin which automatically assigns enrolled users on a course into groups

dependant upon information within their user profile.

 

This plugin will create, update, and delete groups automatically

to match the users on your course. All behaviour is event-driven

and so will occur within page loads.

 

The system can also monitor manual group setting changes and

moderate them to ensure that groups are kept neat and tidy.

Screenshots

Screenshot #0
Screenshot #1

Contributors

Mark Ward (Lead maintainer)
Emma Richardson: Maintainer
Arnaud Trouvé: Contributor
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Wed, Jan 5, 2022, 11:08 PM
    We used to use automatic account creation (LDAP) and later SAML2 but this is still per student not per college enrolment.

    We can not use automatic account creation (and arguably should not have been using it) because student usernames are based on their actual name (with numbers added when more than one would be created in the same year). Not my idea and not under my control but it has led to pre-existing accounts being accessed by new students.

    I was forced to revert to the upload because of this and to added a script which checks for these collisions and optionally creates the file to upload.
  • Wed, Jan 5, 2022, 11:12 PM
    It doesn't matter how you get your students in, it will still work. Per the docs - when you are using csv upload, "To create a custom field "genre", you must write a shortname "genre" in the new field, and write "profile_field_genre" in the header of the .csv file." Is that how you formatted it?
  • Wed, Jan 5, 2022, 11:16 PM
    "To create a custom field "genre", you must write a shortname "genre" in the new field, and write "profile_field_genre" in the header of the .csv file." Is that how you formatted it?

    Yes. Nevermind.
  • Ricardo Caiado
    Tue, Apr 26, 2022, 10:37 AM
    Hi,

    100% cpu usage after the plugin is enabled.

    When disable cpu usage drops to 12%.

    Is this the expected behavior?

    Ricardo
  • Tue, Apr 26, 2022, 10:54 AM
    No.. Not at all. What server, Moodle version and plugin version?
  • Ricardo Caiado
    Tue, Apr 26, 2022, 11:03 AM
    Hi, Emma.

    Auto Group 2.6 (2022040500)

    Moodle 3.10.6+
    PostgreSQL 12
    PHP 7.4
    Apache 2
    Ubuntu 20.04

    21K courses
    356k users

    Ricardo
  • Wed, Apr 27, 2022, 5:48 AM
    Did you try and apply to all 21K courses at once? I guess that could be somewhat intensive...or apply to a course that has a huge amount of students? I am not sure - never dealt with those numbers..if it is trying to reading everyone's profile and create mass groups in thousands of courses, that would probably tax the server..
  • Ricardo Caiado
    Wed, Apr 27, 2022, 7:02 AM
    Hi, Emma.

    From what I've verified, there is a global configuration and a local configuration.

    I found a local configuration in a course with over 60K students!

    So, when activating the plugin, because of this course I had a spike in CPU usage.

    If my memory serves me right, I think I enabled the "addtonewcourses" option at the beginning of the semester and, after that, +10k courses were created...

    My mistake...

    Ricardo
  • Thu, Jan 19, 2023, 3:25 PM
    I have a site which uses autogroups very heavily, and for the last 2 years it has worked fine. For some reason the other day it suddenly stopped working - e.g. it was part way through the process of adding new users to groups in lots of courses, when it abruptly stopped. If I 'force' the issue e.g. set up a new autogroup in a test course it runs as expected, or if I update a users profile it picks that up and executes, but there are a whole load of actions that are waiting to run which haven't yet. Is there a way to 'restart' the plugin so that it goes through all courses and check all enrolment and does the group manipulation as required?
  • Thu, Jan 19, 2023, 8:54 PM
    How were you running it on multiple courses at once? Was this due to a user upload? Could you re-upload the users maybe?
  • Thu, Jan 19, 2023, 9:23 PM
    Thanks Emma for responding - a couple of things going on at the same time. We use 'Enrol user by profile fields' in conjunction with autogroups. So by changing a user's profile field, that first enrolled them onto lots of courses, and then the autogroups would follow and put them into the correct groups. The host company (who initially couldn't see the problem) believes that it may be a PHP issue where something maxed out - so were are currently exploring that.
  • Thu, Jan 19, 2023, 10:59 PM
    Ok, that makes more sense. I wonder if you disabled and reenabled the plugin it might work but if it does hit a timeout that might put you in a worse position than you are now. Have you tried clearing caches by chance?
  • Sat, Jan 21, 2023, 3:19 PM
    @Emma - for reference, it was a php issue that caused the problem - too many things happening at the same time, reached some sort of threshold (which I don't understand)
  • Wed, Apr 5, 2023, 9:06 PM
    Hello - I have a quite a few sites that are using the auto group plugin (and I love it). However, as one site started to grow the site would become extremely slow whenever any user profile was updated. They are at roughly 6,000 users and about 60 courses. We didn't think it was the auto group plugin at first until the our infrastructure team dug in a little further. I was wondering if there was a way to adjust the plugin so that it doesn't check against all profiles and all courses each time a profile is updated. Maybe the ability to schedule a cron task? If you want to chat further, you can reach out to me directly. Thank you in advance.
1 2 3 4 5 6 7
Please login to post comments