Plugins
0

Amuga Ajax Log

LICENSE TYPE: INFINITE

Description

Its time to find out what is really hitting your admin-ajax.php file so much.

Contrary to popular belief, hits to admin-ajax.php do not only come from the Heartbeat API. Many plugins make use of WordPress built-in ajax functionality, sometimes negatively impacting site performance and resource usage. Unfortunately, its not always easy to tell what is causing these hits.

Many blogs and web hosts will tell you to install a plugin to limit hits to the Heartbeat API. While this is great for hits coming from the Heartbeat API, it does nothing to affect plugins that use admin-ajax. So how do you stop what you cant see?

Thats where Amuga Ajax Log comes in.

Amuga Ajax Log tracks and logs actions that hit admin-ajax. It gives you a look at essential data, such as:

  • Requested action name
  • Possible function or method name
  • Suspected location
  • Page that triggered the hit

The plugin does not track information about the user.

Amuga Ajax Log was built to make it easier to see what is really increasing your admin-ajax usage. The plugin logs the data to a flat file or a custom database table. It also provides an easy to read Leaderboard that shows you which actions are hitting the most.

But wont a busy site cause a lot of data to be tracked? asks curious local man.

Yes, that is true. That is why we dont recommend leaving the plugin activated for extended periods. As a troubleshooter, your goal with this plugin is to obtain enough information to solve your issue. With the Leaderboard and Recent Hits list, you will have a higher chance of tracking down what is hammering your admin-ajax.php file.

Another nice feature of Amuga Ajax Log is that it can clean up after itself. Weve provided two easy options for cleaning up data.

Purge Current Database Log

From the Settings page, check the box that says Purge Current Database Log, hit Save, and Amuga Ajax Log will clear all admin-ajax hit records it has stored in the database.

Remove All Data on Deactivation

We are a big fan of plugins that provide an option to remove their data after deactivation. Amuga Ajax Log does the same. From the Settings page, check the box that says Remove All Data on Deactivation, hit Save, and when you deactivate Amuga Ajax Log from the Plugins page, the plugin does the following:

  • Removes our flag log file if it exists
  • Removes our custom database table
  • Removes our data from the options table

A Few Notes:

Keep in mind that this plugin does not stop admin-ajax hits; it only records them and provides information about the hit. It is up to you or your developer to determine what to do next.

Because you can have Classes that share method names (ex. ILike->Tacos, ILove->Tacos, GiveMe->Tacos), it is possible that there will be multiple Locations listed.

Sometimes, we cant figure out where something is. In those cases, we recommend using the action name or the function name and running a Grep search using SSH, or doing a text search with a tool such as Notepad++.

Screenshots

Installation

  1. Install Amuga Ajax Log by uploading the amuga-ajax-log.zip ZIP file.
  2. Activate it through the Plugins menu in WordPress.
  3. It is now ready to work. Default settings may be altered in the Amuga Ajax Log settings page.

FAQ

This was developed using PHP 7.4 and should work on 7.0+. Anything lower has not been tested.

No, this plugin only watches what fires through admin-ajax and logs it. If we added the option to unhook an action running through admin-ajax, your site would probably break and you would be sad.

We search for the action by using function names and searching for class methods. If we are unable to determine the location, we recommend using a grep search via SSH to find what is using the action name weve logged.

Yes. Absolutely. Probably. No, not really.

Leave a Reply

Your email address will not be published.

Fill out this field
Fill out this field
Please enter a valid email address.
You need to agree with the terms to proceed

Most Viewed Posts
Menu