Archives For

An Advanced Workflow process can only be triggered once per PHP process or HTTP request. This is intended to prevent Sugar Administrators from defining infinitely looping processes. (A real catastrophe!) But what does this mean for PHP customizations?

Assume that you have an Advanced Workflow process enabled for the Contacts module that performs an update on this Contact each time it is saved. If you have an Accounts after_save logic hook that performs an update on each related Contact SugarBean then the process will only run against the first related Contact. Any other related Contact that gets saved during your logic hook execution will not have a process run.

This affects not just logic hooks but any other class of PHP customization such as custom API endpoints or jobs.

Workaround

If you really need to run that process more than once in the same request, here is a workaround:

use Sugarcrm\Sugarcrm\ProcessManager\Registry;
...
Registry\Registry::getInstance()->drop('triggered_starts');

Calling this method will clear the internal Advanced Workflow registry that keeps track of the triggered process starts. After calling this method, the same process can then be triggered again inside the same PHP process or HTTP request.

Careful use of this method can make sure that PHP customizations play nicely with processes defined in Advanced Workflow.

Want to make sure you are included in upcoming Developer Webinars, Newsletters, and other developer updates straight from SugarCRM? Don’t miss out. Sign up to get Sugar Developer News today!

You may have noticed that we made changes to Sugar University over the past few months. We introduced new online role based learning pathways for Administrators, Developers, and Solution Architects. This will help you locate the training you need to get your job done and hone the skills you need to be certified. All the online learning pathways are free!

We have also added some classes to the calendar that Sugar Developers should definitely check out!

Continue Reading…

Note from the SugarCRM team

This post represents an individual customer’s experience with using CloudFlare CDN. The results are pretty exciting! But here is a word of warning.

SugarCRM does not officially support use of a Content Delivery Networks (CDNs). CDNs alter the behavior and content of HTTP requests which can cause bugs and prevent the propagation of administrative (ex. Studio) and code changes. The author has provided a process that works for them but may not work for everyone.

Sugar Support will not help you with CDN configuration. If you run into problems with Sugar using a CDN that you cannot resolve on your own then you should discontinue use of the CDN.

The following post was written by Sugar Customer Mark Anderson. It was originally posted on his personal blog and is reproduced here in a lightly edited form.

The CloudFlare content delivery network (CDN) is an inexpensive but powerful way to optimize the performance of a Sugar on-premise deployment. This post looks at how a free CloudFlare account could double the performance of a Sugar On-Site instance.

The experiment started with a review of the performance of a Sugar deployment, using GTMetrix to establish baseline performance. The ultimate goal was to improve performance. We wanted to explore all options since our initial assumption was that better performance would require a costly server upgrade.

Continue Reading…

Where will you be on September 26th at 1:00pm Pacific Time? If you are a Sugar Developer then you better be in San Francisco, the City By the Bay, at the Hilton Union Square!

The annual UnCon is the top rated event at SugarCon because of the in-depth technical content, knowledgable speakers, and our enthusiastic developer and admin community.  This is a unique event where you get an incredible level of access to the development teams and decision makers that build our products and platforms.

Essential to the success of UnCon is input from the Sugar Developer and Administrator community! We are just over 90 days away so planning is well underway. Now is the time to provide your input on the content presented at UnCon.

Please fill out this very short on question survey. This will help us focus the event on the types of content that you want to see.

UnCon 2017 Theme Survey

 

Fill out the UnCon 2017 Theme Survey!

 

Continue Reading…

You may have seen that that Sugar 7.9 has now been released! We have moved the Quotes module and Reports list view to Sidecar framework. We’ve also made plenty of platform enhancements such as adding prepared statements support.

pastedImage_3

Quotes in Sidecar!

Quotes Module Developer Guide

We have created an all new Quotes section in the Sugar 7.9 Developer Guide that is designed to address common customizations that Sugar Developers make to the Quotes module.

Sugar 7.9 Migration Guide

The Migration Guide for Sugar 7.9 is an essential resource for any Sugar Developer upgrading a customer from Sugar 7.8.x. The guide will help you identify code and platform changes that you need to make in order to ensure that you can upgrade your code and customers successfully.

Sugar 7.9 Unit Tests

The Sugar Unit Tests repository has been updated with unit tests for Sugar 7.9. This is the same test suite that the product team used in developing Sugar 7.9. Remember that you need to sign up for access to the Sugar test repositories.

Sugar 7.9 Overview for Sugar Developers

We delivered a recorded webinar that will be shortly available in the Developer space in the Sugar Community. This is a great way to get immediate understanding about all the new features and platform changes that were introduced in Sugar 7.9. The presentation slides will also be posted in the Developer community shortly.

What are Prepared Statements?

Prepared Statements, also known as parameterized statements, is a database feature that allows the same or similar queries to be executed with more efficiency and greater security. It has also been a common Sugar platform feature request for some time.

A prepared statement looks something like this:

SELECT * FROM table WHERE id = ?

As you can see, a prepared statement is basically a SQL template that allows you to identify parameters that can be bound later. The database engine can parse, optimize, and cache this statement without executing it.

This reduces the overhead associated with parsing complex queries that are used frequently by applications like Sugar. For example, you can imagine that List View queries would benefit from prepared statements since they are often complex and executed each time a list is displayed, searched, filtered, or paginated. With prepared statements, the database will do less work each time one of these actions is repeated.

Continue Reading…