How to use Fabric

What is Fabric

Fabric is a cloud service that provides crash reporting and mobile analytics, showing the data in dashboards. If you already know what Fabric is you can skip this to Fabric Setup.

Features

Two of the available services provided by Fabric are Crashlytics and Answers.

Crashlytics

With Crashlytics, you get real-time information on crashes inside your app, and all the details you need to tackle the most impactful stability issues head-on.

Answers

Answers gives you real-time statistics on how your app is being used, including active user numbers, session length, stability rating, and retention. Answers gives you instant metrics as soon as you turn it on, without requiring any additional code.

You can also send customized events with your mobile application.

Developers can have accurate and detailed data about the usage of the mobile application when analysing the customized events.

Offline Mode

When there’s no connectivity, gathered metrics are cached and sent when the Application is launched with an active network connection.

How to activate Answers

After accepting the Answers agreement, you will be asked to perform a new install of your app in order to start sending events to Answers.

When the Answers is activated in your mobile application, you will see the following success screen:

What can you do with the Fabric Plugin

When the Fabric Plugin is integrated in your Outsystems Application, by default you are able to see: native crashes, real-time data aboutactive users, daily new users, number of sessions, most used application build, most used operating systems and also most used devices.

It is also possible to refine this information using Fabric Plugin actions. You can also track: crashes with additional information (which user or variables used to crash the application); custom views and content; information about login and sign up; the most used search queries; information about rated content and information about invitations and shares of the application.

Fabric Plugin Actions

These are the actions available on Fabric Plugin:

For more detailed information about each action, you can find their descriptions and input params on the Plugin itself.

To use the Fabric Plugin actions, you have to drag and drop the “Client Action” to your screen and choose one of the Fabric Plugin action that you want to use on your Outsystem application.

Some integration use cases

Track Crashes

It is possible to track all exceptions that occur in your actions. For that use the “SendNonFatalCrash” Fabric Plugin action.

As input to this Fabric action, use the exception message content:

Now let’s see the data in Fabric website. Click on the Crashlytics tab, and you will be able to see the crashes of your application.

Custom Event

Let's say you have a mobile home banking application, and you want to know which types of bank transfers are most used by your users.

Assuming you have a “Transfer” action flow like this:

You can track the transfer event by using ““SendCustomEvent” Fabric action in your “Transfer” action.

Next, you need to fill the inputs of the Fabric Plugin action. “EventName” is a mandatory field and as an example you can use the string “Transfer” on it.

“Custom Attributes” is an optional field. In this example it is used to track the transfer type.

The “CustomAttributes” is a List of “Attribute” Structure data type that you can use to collect additional information about the event. In this example let’s track the type of transfer that the user did.

To do that, Add a variable called “AttributeList” to your “Transfer” action.

All required inputs are now ready to be assigned to “SendCustomEvent” action.

Despite all the variables being assigned to the Fabric Plugin action, our “AttributeList” remains empty. Let's create a new variable of “Attribute” Structure data type and call it “TransferType”.

Now, you just need to assign values to that variable.

To track the transfer as an internal bank transfer, assign “Key” with “Type” string and “Value” with “Internal” string.

To populate the “AttributeList”, use “AppendList” action.

The final step is to append the “TransferType” variable to “AttributeList”.

In the end the “Transfer” action should be similar to this:

Now let’s see the data in Fabric website. You need to activate Answersto be able to view data about events.Click on the Answers tab and click also on the events tab, and you will be able to see the “Transfer” event.

We can get more details of this event:

With the above dashboard you can conclude that 417 transfers were made with your application. Let’s see what kind of transfers and how many transfers were made:

You can see that there were 281 “Internal Transfers” and 136 “External Transfers”.

Limitations

Crashlytics on iOS

Outsystems platform doesn’t create the “dSYM” file after generating an iOS application. Therefore, it’s not possible to see the crash details from iOS applications on Fabric without a “dSYM” file upload.