AppBeat Blog

Perfect Monitoring for Your Cloud

API access for our uptime monitor

Today we published AppBeat 1.3.6 with following features:

  • "Account / API Access" - possible to call first AppBeat REST method which returns status overview of your system. This allows you to create your own simple client. We will add more useful methods in future.
  • security improvement: same application session can not be used from multiple IP addresses
  • we are now displaying question dialog when new web client is available (you can also postpone version upgrade) --> this will be visible first time when next version arrives
  • back-end upgraded to .NET Core 1.0 RTM
  • other minor improvements

API access is currently simple (just one method), but now we have solid infrastructure on which we can build. Next we will try to add REST method for measuring page speed from different locations. Website speed will be measured on remote browser and will also download all page resources (CSS, scripts, images, ...).

.NET Core 1.0 was officially released yesterday at Red Hat DevNation. Few hours later we already had our entire web backend migrated to RTM version. Because all internal tests were positive, we decided to push it to our production environment - less than 24 hours since official announcement :) This is what we call agile development :)

If your current version does not update to 1.3.6, simply press CTRL+F5 in your web browser. This should reload your page and replace cached version with new one.

How to send service outage alerts to your Slack channel?

Want to integrate your website monitoring notifications with Slack? Please follow these instructions.

Step 1

From AppBeat dashboard, click on Account in the left navigation and then choose Integrations from tab menu.

Step 2

Press the Slack button which opens Add notification channel dialog. Enter arbitrary name for this channel and your Slack webhook URL.

To make sure that everything works please click Test button which should send test notification to your Slack channel. If you don't receive any message we suggest that you double check your webhook URL. When everything looks OK you can click Add button.

Step 3

Click on Services & Checks in the left navigation and double click on service for which you want to enable Slack notifications. In Edit service dialog, please click on Notification types tab. Enable your slack channel and click Save. You can repeat this step for your other services.

 

Dynamic webhooks for integration with any notification provider (and more)

Today we published AppBeat 1.3.5 with following features:

  • added context menus for services, checks and contacts for more clean user interface
  • when you right click on check in "Service & Checks / Checks", there is new "Failure/success notes..." option. This allows you to include additional instructions for your support staff for each check and is included in sent notifications.
  • "Account / Personalization" - possible to customize notification subject and short message (SMS) template
  • "Account / Integrations" - added dynamic webhook provider which supports request customization - can be used with any notification provider that supports JSON payload
  • check name is now included by default in notification subject and short message
  • "Account / Security" - current password must be entered before changing to new password
  • other minor improvements

Context menu support:

When user clicks on check with right button, context menu is shown

Failure/success check notes:

Notification templates:

Dynamic JSON webhooks:

Backup web client for high availability

Some of our users are constantly using our "Live status" page by their monitoring teams. Primarily for this reason we are introducing secondary backup web client which can be used to monitor "Live status" page even if there is issue or outage of primary web client. Backup web client is actively running on different datacenter and can be accessed by navigating to web2.appbeat.io (this is also displayed in application footer).

Is this feature available for our free users? Of course, this feature is available for all our users! If you are not yet member, you can register here for free.

We are one of rare monitoring provider to offer such feature to their users!

---

High level diagram of current AppBeat architecture:

Embed service status to your dashboard

Today we published new version of AppBeat (1.3.4) which allows users to enable embeddable status images for each service. You can access this feature from "Public status / Embed Status":

Images are periodically updated with latest statuses by following rules:

  • if there is no status change for your service then image is refreshed every 5 minutes
  • if service status changes (from good to error, from warning to good, etc.) then we try to upload new status image as soon as possible (this is usually less than 30 seconds after you received your notification)

Status images can be embedded to your internal dashboards or internet facing websites. Image URL contains random Globally Unique Identifier (GUID) in its name which allows you too keep links private / for internal use only.

Optionally you can also customize image template with your own colors and texts (for example, you can remove service name from image).

This feature is available only for paid accounts (from 1.99 EUR / month).

AppBeat web app can now run on Linux!

We have successfully migrated our web application from .NET Core RC1 to .NET Core RC2 and published it on test Linux instance (CentOS). Best of all: AppBeat binaries are 100% identical to those on Windows (same cross platform codebase!) and were simply copied to Linux... And it works! It works great!

Here are some setup details for those who are interested.

First, you have to install .NET Core runtime by following simple instructions on Microsoft .NET Core website.

ASP.NET Core web applications are running on lightweight web server called Kestrel, but since it lacks some of important web server features (for example HTTPS, various built-in tools, ...) it is usually configured to run in tandem with other web server of your choice. On Windows this is IIS, on CentOS we selected NGINX. Those web servers then forward your request to Kestrel which runs your ASP.NET Core web application, creates output and returns it back to main web server.

To setup NGINX to forward requests to Kestrel you have to edit nginx.conf with following (adapt if needed):

location / 
{
proxy_pass http://127.0.0.1:5000;
proxy_set_header Connection "";
proxy_set_header Host $host;
proxy_set_header X-Original-Proto $scheme;
proxy_set_header X-Original-For $remote_addr;
proxy_http_version 1.1;
}

Then we installed supervisor to monitor our Kestrel process and make sure it is always running:
sudo yum install supervisor

We created kestrel_default.ini file in /etc/supervisord.d/kestrel_default.ini with following content:

[program:kestrel_default]
command=dotnet /usr/share/nginx/WebApp/AppBeat.Web.dll
directory=/usr/share/nginx/WebApp
autorestart=true
autostart=true
stdout_logfile=/var/log/AppBeat/app_std_out.log
stderr_logfile=/var/log/AppBeat/app_err.log

After you saved file you can start Kestrel process by typing:

sudo supervisorctl start kestrel_default

Make sure nginx and supervisor are started on system boot:

sudo systemctl enable nginx
sudo systemctl enable supervisord

This is pretty much it :) We are now prepared for future! If you have questions you can reach us on @AppBeatMonitor

AppBeat Incidents

To make everything fully transparent we have added "Incidents" section into our Help module. Here you can find all AppBeat operation issues that were detected, with detailed description what went wrong, how service was affected and how could we prevent similar issue in future.

Monitor websites with ease

If your technical support is using AppBeat Live status screen to monitor current performance and availability of your systems, we have new useful feature for you.

You can now enable sound alarm which is automatically triggered when "Live status" icon turns red. This additionally minimizes chance for missed alarms (other notifications, such as Slack, PagerDuty, email, SMS are of course also dispatched as configured).

You can enable / disable this feature by clicking bell icon as shown below:

Before relying on this functionality please click "sound test" link to see if your web browser supports Audio API. Most modern browsers should support this feature out of the box. If everything works you should hear test alarm for approximately 15 seconds.

Would you like to see this feature in action? Sign up for free account and try it yourself!

Integration with PagerDuty - The Incident Resolution Platform

Today we published AppBeat 1.3.0 which implements support for third-party notification providers (from Account / Integrations). We are also happy to announce that first provider to be implemented in AppBeat is PagerDuty (available to all users, even those on Free Plan).

You can add PagerDuty to your AppBeat account by following these easy steps:

  • click "Account / Integrations":

  • click on "PagerDuty" button to add new notification channel (you can add multiple PagerDuty notification types; ServiceKey can be obtained on your PagerDuty website):

  • once you have tested and added your PagerDuty notification please click on "Services & Checks". Now double-click on desired service and click "Notification types" tab. Select your PagerDuty notification:

Congratulations! You have successfully integrated your PagerDuty service! From now on, when your service fails, you will automatically receive incident report directly to your PagerDuty!

We will soon add support for more third party incident management tools. Stay tuned!

How to develop PagerDuty support in C#

We are currently working on version of AppBeat which will have support for PagerDuty (third party incident management tool).

Their API is very easy to use. Here is code example from AppBeat which sends PagerDuty notifications:

namespace AppBeat.Core.Notifications
{
    class PagerDuty
    {
        //NOTE: this is dispatched in separate thread, exception handling is done by NotificationManager
        public static bool Send(ThirdPartyDispatcher.CustomNotification notification)
        {
            var settings = (Types.CustomNotificationPagerDuty)notification.Settings;

            if (string.IsNullOrWhiteSpace(settings.ServiceKey))
            {
                throw new Exception("ServiceKey is required!");
            }

            string incidentKey = Guid.NewGuid().Normalize();

            var req = new PagerDutyReq()
            {
                service_key = settings.ServiceKey,
                description = notification.ShortMessage,
                incident_key = incidentKey,
                details = new { Message = notification?.Details?.Output?.Details },
                event_type = "trigger",
                client = "AppBeat",
                client_url = "https://appbeat.io"
            };

            using (var wc = new WebClient())
            {
                var res = JsonConvert.DeserializeObject<PagerDutyRes>(wc.UploadString("https://events.pagerduty.com/generic/2010-04-15/create_event.json", JsonConvert.SerializeObject(req)));
                return res.IsOk();
            }
        }

        class PagerDutyReq
        {
            public string service_key
            {
                get; set;
            }

            public string event_type
            {
                get; set;
            }

            public string incident_key
            {
                get; set;
            }

            public string description
            {
                get; set;
            }

            public string client
            {
                get; set;
            }

            public string client_url
            {
                get; set;
            }

            public object details
            {
                get; set;
            }
        }

        class PagerDutyRes
        {
            public string status
            {
                get; set;
            }

            public string message
            {
                get; set;
            }

            public string incident_key
            {
                get; set;
            }

            public bool IsOk()
            {
                return string.Compare(status, "success", StringComparison.InvariantCultureIgnoreCase) == 0;
            }
        }
    }
}

To use this code you must first create service on PagerDuty with API integration. You then receive unique service key which you use in your API. It can't be more simple than this :)