Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Joe Ferguson:
Homestead Welcomes Z-Ray by Zend
Feb 07, 2018 @ 15:41:44

In a post to his site Joe Ferguson, the maintainer on the Laravel Homestead project, has announced a change in the 7.1.0 version: compatibility with Zend's Z-Ray debugging tool.

Since the release of Homestead version 7.1.0 and base box version 5.1.0 Homestead now supports the Zend Z-Ray plugin for PHP 7.2. You can start leveraging the power of Z-Ray in your application with a small changes to your Homestead project.

He includes the instructions to help you upgrade your current installation to this latest versions and the configuration changes required. He also walks through the commands you'll need to use and the resulting output so you can be sure you're on the right track. The end result integrates Z-Ray directly into the site without any additional work.

tagged: laravel homestead zend zray debugging tool install vagrant

Link: https://www.joeferguson.me/homestead-welcomes-z-ray-by-zend/

Adam Culp:
Setting up local step debugging with PhpStorm
Feb 17, 2017 @ 15:58:31

Adam Culp has posted a new tutorial to his site showing you how to set up local debugging inside PhpStorm combining it with the Zend Debugger tool.

Setting up debugging in an IDE with a local development environment has gotten so easy it can be done in a few automated steps. In this post I will demonstrate how to get step debugging functioning with
tagged: local step debug phpstorm tutorial zendserver zray

Link: http://www.geekyboy.com/archives/1289

Zend Developer Zone:
Z-Ray Tip #4: Getting Rid of It!
Jan 29, 2016 @ 16:44:14

On the Zend Developer Zone they've posted the fourth part in their series of tips around using the Z-Ray profiling tool in your PHP applications. In this fourth tip they show you how to "get rid of it" in certain parts of your application.

Well, while Z-Ray is a great friend to have when developing your apps, there are just some parties you don’t want it to show up at. You might be using PHP scripts for accessing static pages. Or, you might not want Z-Ray to be displayed for one specific request. In production, you most definitely don’t want Z-Ray popping up for users using your app!

There are numerous ways to disable Z-Ray both in development and in production to make sure your development workflow is not interrupted and your live apps are not affected. Here are a few of them.

They include a few different ways to disable the tool including the use of a function call in the code (zray_disable), using a header in the HTTP request and, naturally, from the Z-Ray toolbar itself. They also talk about setting it up to be removed for production in one of two modes, either selective (only showing for certain requests) and completely disabled.

tagged: zray tip disable development production api get header selective

Link: http://devzone.zend.com/7149/z-ray-tip-4-getting-rid-of-it/

Zend Developer Zone:
Introspecting your Code with Z-Ray for Azure
Jan 13, 2016 @ 18:38:38

On the Zend Developer Zone blog Daniel Berman has posted a guide showing how to use their Z-Ray plugin to inspect code running on Azure for statistics around performance, queries and errors thrown by the code.

Quick experimentation, easy collaboration, automated infrastructure and scalability, together with advanced diagnostic and analytical tools – all provide PHP developers with good reasons to develop in the cloud.

[...] The combination of Z-Ray and the Azure cloud means PHP developers building apps on the Azure web app service get the best of both worlds – Z-Ray’s powerful introspection capabilities and Azure’s rich cloud infrastructure.

The post walks you through the steps to create a new Azure-based web application, how to upload your code and enable the Z-Ray feature directly from the Azure "Tools" menu. The Z-Ray toolbar is then automatically injected into your application for your immediate profiling needs.

tagged: azure microsoft hosting zray profiling tool interface tutorial

Link: http://devzone.zend.com/7093/introspecting-code-with-z-ray-for-azure/

Zend Developer Zone:
Developing a Z-Ray Plugin 101
Nov 04, 2015 @ 16:44:13

The Zend Developer Zone has posted a tutorial showing you the basics of creating a plugin for Z-Ray, the tool from Zend that provides details and metrics around the execution of your application.

One of the great things about Z-Ray is the ability to extend it to display any info you want about your app. This is done by creating plugins. In this tutorial I’m going to describe how to create a new Z-Ray plugin. I’ll be supplying code snippets to insert in the various plugin files but of course feel free to replace it with your own code when possible.

They start by describing how Z-Ray shows its data and offering two options - the default panel or a custom panel. They choose the custom panel and show you how to:

  • create the template for the panel
  • make the module directory and zray.php
  • and Modules.php file to define the plugin

There's also a section on how the Z-Ray plugin traces through the execution of your application, illustrating with a DummyClass. They include the code to set up the Trace and define which methods and actions to watch. Finally they relay this information back out to the custom panel view via Javascript collection and the code to show the results.

tagged: zray plugin custom performance dummyclass execution tracer tutorial

Link: http://devzone.zend.com/6826/developing-a-z-ray-plugin-101/

SitePoint PHP Blog:
Debugging WordPress on Azure with Z-Ray
Oct 13, 2015 @ 16:23:55

On the SitePoint PHP blog there's a tutorial showing you how to integrate the Z-Ray tool into WordPress to make debugging it on an Azure instance simpler. The steps make major use of the Azure control panel handling, so it's not quite as useful as a cross-platform guide but at least it gives you an idea of what you could expect from the Z-Ray+WordPress integration.

We all know that WordPress is an amazingly rich, extendable and simple platform. That’s probably one of the reasons it powers so much of the web today. But in some cases this richness can be the downfall of your site. [...] This means you need an easy, safe and reliable way to profile your WordPress app that will help you identify the bottlenecks slowing it down.

This article demonstrates a simple way to do just this. It describes how to debug a WordPress application deployed on Microsoft Azure’s web app service, using Z-Ray for Azure – a new technology that was announced a few months ago and is now in preview mode.

He walks you through the entire process (assuming you already have an account on Azure:

  • Creating the sample WordPress application on Azure
  • Enabling Z-Ray
  • Developing WordPress with Z-Ray

In that last step he includes some screenshots of the kinds of results you can expect from the plugin including details about cache objects, plugin statistics, hooks being executed and WP Query use. He ends the post looking at using Z-Ray for mobile debugging and how to use it in "secured mode" in a production environment.

tagged: tutorial wordpress azure microsoft zray debugging installation configuration

Link: http://www.sitepoint.com/debugging-wordpress-on-azure-with-z-ray/

Rob Allen:
Simple Ansible file for Z-Ray preview
Sep 15, 2015 @ 15:12:07

For those wanting to check out the latest preview of the Zend Z-Ray stand-alone version, Rob Allen has posted a full Ansible script to help building the environment much easier.

Recently, Zend made available a Z-Ray Technology Preview which takes the Z-Ray feature of Zend Server and makes it stand-alone. This is very interesting as it means that I can run it with the PHP 5.6 on Ubuntu 14.04 LTS Vagrant set up that I prefer. I decided to create an Ansible playbook to install Z-Ray into my VM. The Z-Ray instructions are clear enough, so it was simply a case of converting them to a set of YAML steps as who wants to do manual installation nowadays?!

The configuration is set up to run on a Ubuntu machine with PHP 5.6 installed. It will download the Z-Ray plugin, extract it and copy over all necessary configuration files to get it up and running. This stand-alone version can help to make debugging your applications simpler with real-time information right in your browser.

tagged: zray preview standalone version ansible configuration ubuntu php56

Link: http://akrabat.com/simple-ansible-file-for-z-ray-preview/

Laravel News:
Installing Zend Z-Ray on Homestead
Aug 25, 2015 @ 15:45:01

On the Laravel News site there's a tutorial posted showing you how to Install the Zend Z-Ray tool on Homestead, the popular Laravel-related virtual machine environment. This tool helps with debugging applications by giving you an inside look (a sort of "x-ray") into its inner workings as it executes.

For the past week or so I have been running Zend Z-Ray in Laravel Homestead. Every time using it, new features come to light that are fantastic for debugging your apps in development! What follows is a quick preview of Z-Ray, along with all the steps necessary to install it on Laravel Homestead.

He talks some about the Z-Ray tool and the features it has to offer as well as some of the technologies it supports. He also covers some of the Laravel specific features included like project information, route inspection and current user information. He then gets into the Administration panel, what kinds of information it provides and, finally, how to get it all installed and working. It's not a super simple process but all the commands you'll need are included in the post.

tagged: install zray zend tool plugin laravel tutorial inspect

Link: https://laravel-news.com/2015/08/installing-zend-z-ray-on-homestead/

Zend:
Debugging WordPress with Zend Server and Z-Ray on AWS
Aug 05, 2015 @ 16:57:02

The Zend.com blog has a post showing you how to debug WordPress running on Zend Server with the help of the Z-Ray plugin. In their example they're hosting it on an AWS instance, but the same technique can apply on any other hosted version as well.

More and more PHP development is being done in the cloud and on virtual platforms nowadays. The workflow detailed in this brief tutorial is just one way to develop PHP in these environments, but it illustrates just how easy and productive this type of development can be. More specifically, it demonstrates how to launch the newly available Zend Server 8.5 instance on AWS with a WordPress application already deployed, and then use Z-Ray to introspect and debug the code.

The tutorial walks you through the setup and configuration of a new AWS instance with Zend Server and WordPress installed (you can skip to the end if you already have this). They show you how to:

  • Launch the Zend Server AWS instance
  • Configure the instance to install WordPress as a part of the setup process
  • Access the Zend Server control panel
  • Accessing the WordPress application deployed on the instance

Once the WordPress application is accessed, the Z-Ray inspection bar will appear at the bottom giving you insight into various configuration options, performance metrics and server information. They also link to a video with more information about the WordPress plugin.

tagged: zendserver wordpress aws amazon instance zray debug tutorial install configure

Link: http://blog.zend.com/2015/08/04/debugging-wordpress-with-zend-server-and-z-ray-on-aws

Andrew Embler:
Creating a Z-Ray Plugin for Zend Server 8.5
Jul 22, 2015 @ 16:37:45

In this post to his site Andrew Embler shows you how to create a custom Z-Ray plugin for the Zend Server (v8.5) to show some statistics about requests made to the application.

Zend just released version 8.5 of their Zend Server application server. A major part of this release is the plugin gallery, which provides an App store for Zend Server extensions. These extensions can add application-specific debugging features to the Z-Ray Debugger. We've built one such extension specifically for Concrete5. It didn't take long – just a day or two. That said, there were some bumps in the process, as you're working on a platform for which the documentation hasn't quite caught up yet. With that in mind, I'm going to share my process for building the Concrete5 Z-Ray plugin, in the hopes that it might help someone who is building their own Z-Ray plugin for Zend Server.

The post is pretty comprehensive, sharing all the code you'll need to implement the extension along the way. He's broken it up into sections to help make it a bit more manageable:

  • Create Your Directory
  • Place the deployment.json file in the directory
  • Add Additional Items specified by deployment.json
  • Add the Z-Ray specific Directory
  • Create the Z-Ray PHP Class
  • [Adding] The Logo
  • Basic Panel Details: The Pages Panel
  • Advanced Panel Details: The Blocks Panel

Screenshots also accompany some of the steps showing you what the page output should look like once the files and functionality are in place.

tagged: zray plugin zendserver tutorial application server platform

Link: http://andrewembler.com/2015/07/creating-z-ray-plugin-zend-server-85/


Trending Topics: