GithubHelp home page GithubHelp logo

moodle-local_maillog's Introduction

Mail log plugin by Catalyst IT

This plugin requires a changes to the core email_to_user function so that it will function - you will need to
apply the patch file in patches/moodlelib.php against your moodle install first.

* lib/moodlelib.php (see patch file in patches/moodlelib.patch)

PLEASE NOTE:
The Moodle version of this plugin doesn't currently provide a report that exposes the maillog data - you will need to view the data directly in the database until a report is developed.

moodle-local_maillog's People

Contributors

danmarsden avatar euven avatar matthewhilton avatar peterburnett avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

moodle-local_maillog's Issues

Make purge query more efficient

Currently https://github.com/catalyst/moodle-local_maillog/blob/MOODLE_310_STABLE/classes/helper.php#L46

If you have a lot of emails with attachments, it tries to query a lot of rows and can fall over. For example, we had ~308k rows that this query would select, causing php to run out of memory (100mb)

Some possible improvements:

  • Only query the id, since that seems to be the only actual thing its using (rather than the entire row)
  • Call in a recordset
  • Call in a loop with a LIMIT until there are no more left
  • use the scheduled task to schedule an adhoc task, so if it fails you get a faildelay, retries, etc...

Totara 13+ regression - unable to install

Totara 16.4 (Build: 20220826.00) command line installation program
Default exception handler: Table "config_plugins" does not exist Debug: 
Error code: ddltablenotexist
* line 727 of /lib/dml/moodle_database.php: dml_exception thrown
* line 1604 of /lib/dml/moodle_database.php: call to moodle_database->where_clause()
* line 1850 of /lib/dml/moodle_database.php: call to moodle_database->get_records()
* line 1597 of /lib/moodlelib.php: call to moodle_database->get_records_menu()
* line 25 of /local/maillog/version.php: call to get_config()
* line 300 of /lib/classes/plugin_manager.php: call to include()
* line 330 of /lib/classes/plugin_manager.php: call to core_plugin_manager->load_present_plugins()
* line 230 of /lib/classes/plugininfo/base.php: call to core_plugin_manager->get_present_plugins()
* line 156 of /lib/classes/plugininfo/base.php: call to core\plugininfo\base->load_disk_version()
* line 93 of /lib/classes/plugininfo/base.php: call to core\plugininfo\base::make_plugin_instance()
* line 390 of /lib/classes/plugin_manager.php: call to core\plugininfo\base::get_plugins()
* line 350 of /lib/classes/plugin_manager.php: call to core_plugin_manager->get_plugins_of_type()
* line 741 of /lib/classes/plugin_manager.php: call to core_plugin_manager->get_plugins()
* line 188 of /admin/cli/install_database.php: call to core_plugin_manager->all_plugins_ok()

Recent changes to version.php in particular with get_config calling is causing issues on install. I believe the code should be moved to upgrade.php instead and might fix the install issue.

#10
#11

@sumaiyamannan @danmarsden

Version number for Totara branches is 11 chars as oppose to the usual 10.

Just a heads up here not a change request, happy to fork.

Have some tooling that depends on version numbers being able to parsed as a u32.

The version number for Totara is not a normal version and I'm surprised Totara has allows the installation of it in the first place.

Since it's since been incremented to 001 there is no 10 char version number that can be a smooth upgrade.

Store or at least be able to report on just the domains of emails

Option 1)

As an email comes in split both to and from into the inbox + domain parts are store them separately. This might make it harder to report on the whole email

Option 2)

As an email comes in split the domain out and store the full email in 1 field and the domain in another. Will increase data size but probably be much nicer to work with on the reporting side

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.