Sunday, 13 November 2016

10 Things I love About Wave Analytics

If your company has huge amount of data and your top management needs actionable reports for turnover, growth, revenue etc., you would need a robust and scalable BI tool or provide these answers quickly. This is where Salesforce Wave Analytics has emerged as a crucial player.

Sample Wave Dashboard (Image source: elibrumbaugh.com)

Built on the Wave platform, Salesforce Analytics Cloud is much more than simple Business Intelligence. Organizations can build their own BI applications and make important data-driven decisions, enabling quick actions and smarter connectivity.

How is Wave different from Traditional BI?

Every BI application has a different architecture. The speed with which your BI application gives you the required information is a key factor in its usability, which in turn depends on how you get the data from source system, how you store the data, how you query the data and how you present the data on the UI.

Image source: Salesforce Wave Training

Most of the traditional BIs need to be installed in the client’s machine and store data in the same manner as a relational database would. In almost all those traditional BI tools, queries are complex and time consuming, and these BI tools are often found to be lacking in providing complex insights that is often required by the business.

Compared to traditional BI tools, Wave scores on a lot of fronts. Not only does it disseminate required information at a faster speed, it can get the data from Salesforce, CSV files and partners like Jitterbit, Informatica, Talend, Mulesoft, Boomi, Snaplogic etc. Additionally, Wave is schema free and stores the data in the form of compressed .json. To top it all, Wave is 100% mobile.

Why Wave Analytics?

A pertinent question that arises is the need for Wave Analytics if Salesforce already has inbuilt reports and dashboards. The answer lies in Wave’s capabilities that extend beyond Salesforce reports and dashboards. When compared to Wave, Salesforce dashboards have a lot of limitations, like the inability to create a dashboard using external systems data, inability to get the required insights from the data, Dashboards on Salesforce1 are read-only and are not available to edit.


Which brings me to the 10 most significant reasons why I absolutely love Wave!
  1. Search Based Technology: Wave can get the data from Salesforce, csv, external tools like Informatica, Talend, Jitterbit etc. Wave runs the data flow and wave parser converts all the incoming data into a compressed structure and stores the data in the form of json, which is only the plain text data in the form of key value pairs and a very light weight form of data. With minimal efforts, Wave can search on these key pairs and get the insights from the data.
  2. Schema free non-relational database: Unlike traditional BI tools, the Wave engine does not store the data in the form of a relational database because the database brings quite a few limitations along with it. The database could have repeated values, join operations in schema are always expensive and a linear size expansion makes it ever so difficult to be optimized for read and write operations.  A schema-free Wave stores the data in a compressed format using a key value pair.

    Image source: Salesforce Wave Training

  3. Inverted Index: Speed is a key factor for any successful BI application and it depends on multiple factors like hardware, chosen architecture, query, search operations, etc.



    An indexing technique is used in traditional BI tools. However, if you have a large amount of data and it is increasing rapidly over time, your index also gets increased. You would end up requiring indexes for the indexes, meaning if you use indexing for large datasets, it can affect the speed. Wave has implemented the concept of an inverted index. Just as a book’s last pages has the information on keywords and page numbers on which that keyword has appeared (inverted index), Wave would also store the data in the form of a key value pair.
  4. Loading External data to Analytics cloud:  When stakeholders decide on a BI tool, they consider a few aspects like the type of data within their systems and the compatibility between their systems and the BI tool.  Wave overcomes all these problems. Wave engine is intelligent enough to get the data from Salesforce as well as csv file and partners like Jitterbit, Informatica, Talend, Mulesoft, Boomi, Snaplogic etc.

    Image source: Salesforce


  5. Trusted and secure architecture: Wave being a Salesforce product essentially means that all the security measures in Salesforce hold true for Wave as well. Additionally, Wave also has App level security, field level securities, row level securities to ensure authorized access.

    Image source: Salesforce


  6. Mobile First Design: The top level management of every company needs relevant dashboards and it is additionally useful if they can access the same on the go. Wave enabling the users to create, update and edit dashboards on the fly, with a beautiful and responsive UI for some added zing and It is also available on Apple watches.

    Image source: techcrunch.com


  7. Customized business apps: There are some predesigned wave apps readily available on the AppExchange Like Sales Wave, eCommAnalytics, FinancialForce etc. User can install these wave apps, and get instant answers to their questions.
  8. Visualforce Integration: Yes, you read that right! Wave dashboard can be a part of your Visualforce page by using <wave:dashboard> attribute in the Visualforce page, enabling you to transfer the power of wave to your Visualforce page.
  9. Display Dashboards in Salesforce sObject page layout: You can display Wave dashboards within your Salesforce page layout and display the user specific records on that dashboard.
  10. Can perform actions in Salesforce: Even though Wave is altogether a different platform, it has the power to perform certain actions directly on Salesforce objects, like creation of a task or event, logging a call, creation of a case or updating records etc.
Wave has a killer UI to top it all, ensuring that you are truly able to see and realize the power of analytics that is packed into it. Analytics was never this powerful and beautiful before!



Written by Anand Shinde, Salesforce Developer at Eternus Solutions
Read More »

Monday, 7 November 2016

Managing Different Perspectives of the Developer Console

Being a rookie Salesforce.com developer, I often wondered if System.debug statements were the only way to find out where my superbly written code was breaking. Much to my dismay, I was often all at sea, trying to find out the actual cause of the issue only through execution debug logs provided and without actually editing the code. Wasn’t there a better way, I thought? That’s when I stumbled upon the inbuilt features of the developer console.

The developer console basically provides a convenient set of tools for efficiently tracking down logical issues. A perspective is a predefined arrangement of panels in the developer console log inspector. The developer console has a set of tools that enables the developers to track what exactly is happening down there in the hood. These tools are grouped together by default and presented to us in the form of a perspective.

To view all the default perspectives, simply click on debug → Perspective Manager in the developer console.

Out of these predefined perspectives, one of the most helpful panel is the Execution Overview panel which is a part of Analysis perspective.

The Execution Overview panel consists of four tabs.

Save Order Tab

Let’s consider a case where you are new to a project and are unable to gauge the exact flow of execution. Alternatively, you might be familiar with the project but observing some weird changes. You might find that some fields or actions are affected only if the code is executing recursively but for some reasons you are unable to determine where and what is making the code run into recursion? Another possible scenario could be where you are unable to determine which validation rule or which workflow rules are fired or is it a custom workflow or validation that is causing an issue to occur?

For all such scenarios, the immediate solution could be to direct to the Save Order tab which is a part of Execution Overview panel.

The Save Order tab provides an overview of all the actions that are performed during a DML operation in a beautiful color-coded format. Not only is it color coded, but it also displays all the actions in a intuitive sequence diagram. You no longer need to scratch your head in determining whether the validation rule ran first or the trigger; the Save Order tab has got it all covered.

This tab follows a color code format for better and fast understanding for the end user.

It states:

Colour
Actions
Before trigger
After Trigger
Validation Rule
Assignment Rule
Workflow Rule

Once you click on the validation rules, you are directed to the actual validation rule in the execution log panel where you are able to view its actual detail.




Executed Units Tab

As a part of the Salesforce development, we might have faced a few exceptional scenarios we are usually scared of, but which need to be tackled nonetheless; such as the CPU time limit exceeded exception or the Heap size Limit exceeded exception. There might have been cases where you were unable to figure out the total number of rows affected due to the DML action.

The Executed Units tab, which is a part of the Execution Overview panel, helps you find the answers to all these queries very easily.

It displays the system resources used by each item in the process. Additionally, there are various buttons:  Method, Queries, Workflows, callouts, DML, validations, triggers, Pages; at the bottom of the tab which can be used to filter out information by item type.

In the Execution Units tab, we have following columns:

#
Column
Description
1
What The what column includes the various operations known as process items that are executed in particular execution.
The different process items that are included are as follows:
  • Method
  • Queries
  • Workflow
  • Callouts
  • DML
  • Validations
  • Triggers
  • Pages
2
Name For each of the process included above, it gives the name for it.  e.g.
If “method” is included in the “what” column the name of the method that is executed is displayed in the name column accordingly.
3
Sum If the process is executed more than once then the sum of duration for that particular execution is calculated in milliseconds.
4
Avg The Avg column displays the average duration (in milliseconds) taken for the process to be executed. It is calculated based on the formula (Sum/Count).
5
Max If the particular process is called more than once, the maximum duration (in milliseconds) taken for execution among all those executed processes is included in max column.
One of the use case where the information displayed in this column would help you, is to solve CPU time limit exceeded exception.
6
Min If the particular process is called more than once the minimum duration (in milliseconds) taken for execution among all those executed processes is included in min column.
7
Count Number of times a particular process was called during its execution.
8
Heap Amount of space the process took on the heap is specified in bytes.
e.g. Heap size limit exceeded exception would be traced much faster by observing information listed in this column.
9
Query Type Type of query. Possible values are:
  • SOQL
  • SOSL
10
Sum rows Sum of all records changed during the execution of particular process.
11
Avg rows Average number of records changed during the execution of particular process.
12
Max rows Maximum number of records changed during the execution of particular process. For eg: The Max rows count would help you to solve SOQL Limit exceeded exception by determining the exact process which has caused the exception.
13
Min rows Minimum number of records changed during the execution of particular process.



So many tools in such a small window! Magic, thy name is Developer Console! Guess what, the fairy tale doesn’t end here; there are some more unsung features that prove to be a great boon to the developers.  But that is for another day, as I shall be covering them in my next blogs. Till then, let the magic of Developer Console make life a smooth ride for you!



References :



Written by Kaajal Bhawale, Salesforce Developer at Eternus Solutions
Read More »