Category: logging

Poka Yoke – Saving Projects with Hyper-Defensive Programming

When working in a medium to large team on the same codebase, it can sometimes become hard to understand each other’s code and how to use it. Various solutions exist to help with this. For example, you can agree to follow a set of coding standards to make the code more readable for each other, or use a framework t...

Redux Logging in Production with LogRocket

Setting up LogRocket Setting up LogRocket is easy, and only requires adding a few lines of code to your app: Install with npm: npm i --save logrocket. Create a free account at https://app.logrocket.com, and take note of your application id. Initialize LogRocket in your app: import LogRocket from 'logrocket'; // Initi...

Sending PHP Event Messages to Remote Logstash on Windows

By opening this article you’ve endeavored yourself to expanding your knowledge of PHP applications as part of event-based distributed systems. You’ll be given a quick intro into what we are referring to when we say event messages, what Logstash is, and why it is so cool. If you’ve already heard of B...

Sourcehunt – Open Source Week Edition

Sourcehunt – Open Source Week Edition This week is Open Source Week at SitePoint.com. While we do usually cover open source here, what with all the tutorials and introductions to amazing new libraries, packages, and frameworks, this week will be a little “theoretical” for a change. We’ll discus...

Logging Errors in Client-Side Applications

Logging is an important part of any software application, both during active development and when it’s running in production mode. When you’re working on the server, there are hundreds of libraries available to you regardless of your server-side language of choice, a wide range of storage mechanisms, and a...

Mail Logging in Laravel 5.3: Extending the Mail Driver

One of the many goodies Laravel offers is mailing. You can easily configure and send emails through multiple popular services, and it even includes a logging helper for development. Mail::send('emails.welcome', ['user' => $user], function ($m) use ($user) { $m->to($user->email, $user->name)->s...

Monitoring WordPress Apps with the ELK Stack

WordPress is an amazing piece of engineering. There’s little wonder that more than a quarter of all CMS-based websites are using it. In reality, though, WordPress sites crash just like any other site. Bad plugins or themes causing the “WordPress screen of death”, or WordPress updates going south, are an all too ...

How Can the ELK Stack Be Used to Monitor PHP Apps?

This article was peer reviewed by Christopher Thomas, Younes Rafie, and Scott Molinari. Thanks to all of SitePoint’s peer reviewers for making SitePoint content the best it can be! When things go south with our applications — as they sometimes do, whether we like it or not — our log files are normally am...

Logging with Monolog: From Devtools to Slack

Logging is an important part of the app development/maintenance cycle. It’s not just about the data you log, but also about how you do it. In this article, we are going to explore the Monolog package and see how it can help us take advantage of our logs. Installation Monolog is available on Packagist, which means tha...