When Salesforce is life!

Author: Enrico Murru Page 18 of 20

[Salesforce / Mobile SDK] Salesforce Mobile SDK 3.1 brings unified app architecture

I left mobile development in the far 2010, when Salesforce development became my actual job.
In the past 6 years I’ve gradually switched to web dev techs over native development, and this a kind of hurted my feelings, but it was a necessary path (I merged the passion for discovering new techs with learning something usefull for my “giving-money” job).

Few months ago I made up with my team a quick demo for a client using PhoneGap and the Salesforce Mobile SDK: it was really amazing, we created a fully working app (I’m not the wizard of UIs, but it was pretty amazing) in a couple of weeks.

With the new release of the Mobile SDK we have a unique set of interfaces shared between all platforms to link your app, so you don’t have to think to which feature you can use and which not, and dedicate your time to develop your awesome app in your preferred platform.

Here it is a link to the Mobile SDK Release Notes.

SmartSync for native and hybrid development is (in my opinion) the coolest utility feature in this release: this grants a common set of complete API to talk to the SmartSync layer, to ptimize data access when storing objects or doing cached queries.

This allow you to develop responsive and high qualities apps that work perfectly is an offline mode as well as online mode, creating a caching layer and a conflict resolution control.

The following is a cool mini-tutorial on how to detect conflicts when managing offline data while the details of the SmartSync usage.

For a complete example jump on this tutorial.

Other important features includes:

  • CocoaPods for iOS: iOS devs can now use CocoaPods to handle the Salesforce Mobile SDK
  • Gradle for Native Android Apps: Gradle is now supported for Android development, and will be available for Cordova Hybrid Dev in the next Cordova release
  • Certificate Based Authentication Pilot: no need for username/password request for your users to log in

This framework is getting new features release after release, and if you haven’t join our developer community and start build awesome apps!

[Salesforce] My favorite Spring ’15 features

a{color:red !important;}
h3{color:red !important;}

This is my top 10 list of the Spring ’15 Force.com platform update’s features.

Make Long-Running Callouts from a Visualforce Page

This is a really important feature. Imagine you have big VisualForce pages in which Apex methods, triggered by buttons / links / rerenders, do one or more callouts to external services.

Imagine hundreds of users use that page and the external services go down, thus causing timeouts on the callouts.

This could lead to heavy problems, because there can be no more than 10 long running Apex processes at the same time: this leads to unexpected and horrible output errors.

Using this new feature we can now “asynchronize” synchronous Apex callouts, using the new Connection Apex class, that is used like a callback when the callout has ended.
Basically you create a method split in 2 parts: the first (invoked by a button / link) has the starting callout code and the last receives the results from the callout.
Even if the callout/callouts (you can trigger up to 3 callout a time) fails / go timed out this call won’t count towards the logn running processes.

I’m gonna write down a post to show how this works using HttpRequests and also SOAP requests.

Set Up Test Data for an Entire Test Class

This is an extremely useful feature for large ORGs with hundreds of test classes.

This allow us to write “test setup” methods (new annotation @testSetup) that are called once per test class: when a test method is executed the context has all the objects created in those setup methods (you can have more than one method of this kind, but the execution order is not guaranteed). Each test method execution rollbacks its data at the end, so that the following class’s test method will see the values as if they were just been created.

Deploy Your Components in Less Time

Imagine you have the GO for a deploy in your production ORG but you have to do it at saturday midnight (and test methods requires more than an hour to run!!!!)…this is absolutely not cool!

This feature allow you to send a deploy to production before your deadline, test classes are run during this “freezed” deploy and it stays freezed for 4 days: when you are ready you simply click the “Quick Deploy” button and the components are deployed instantly! Whoooaa this is magic!

Create Named Credentials to Define Callout Endpoints and Their Authentication Settings

You can finally leave all the authentication mess to the Force.com platform and just sit on your screen and simply code you business requirement, magically storing sessions, tokens and whatever it is needed on Salesforce.

You can also use a named credential in a simplyfied way to store callout endpoints.

Business Continuity – Promote Business Continuity with Organization Sync

With Organization Sync you can setup a secondary ORG that you can use when your primary ORG needs some maintenance (e.g. a big release of your developments), giving a 24/7 service availability.

Orgs are synched automatically through a data replication mapping.

I haven’t already tested this feature, but being available on developer Orgs I’ll certainly try it soon.

Visually Automate Your Business Processes

This is the Lightning Process Builder, a cool visual tool that help you automates your business processes, from simple actions to complex combinations.

It seems really awesome but unfortunately it is not available on the pre-release program.
You better see in the next days tens of posts about this new feature!

Lightning Components (BETA)

Lightning components are still in beta and the builder in pilot.
But we have new additions:

  • New Components: brand new base components (such as select input, textarea, …)
  • Namespace Requirement Removed: finally no need to setup a namespace, easing the creation of packages and the deploy across orgs
  • Support Added for Default Namespace: follows the previous point
  • Extend Lightning Components and Apps: like classes, you can extend components and apps
  • Referential Integrity Validation Added: integrity validation has been boosted

New increased limits

There are some new increased limits:

  • Deploy and Retrieve More Components: limit increased from 5000 to 10000 components
  • Chain More Jobs with Queueable Apex: from 2 chained jobs to infinity (except for Developer and Trial orgs where the limit is 5)
  • Make Apex Callouts with More Data: size per callout (HTTP or SOAP) increased from 3 MB to 6 MB for synchronous APEX and 12 MB for asynchronous

Create or Edit Records Owned by Inactive Users

All users can now edit objects owned by inactive Users, before Spring ’15 only administrator could do it!
Believe me, this is really usefull.

Legitimize User Activity using Login Forensics (PILOT)

These are forensics metrics to identify suspicious behavior of users (such as logins from unusual IPs or excessive number of login among the average number).
This is a PILOT program, so you have to explicitly ask Salesforce to be enabled.

As usual, may the FOrce.com be with you guys!

[Salesforce / JS] Download automatically files from apex (using href link and base64)

This post is a recap of this Salesforce Developer Forum thread.

We want to trigger a download from an attachment but the running user don’t have access to the object (think of Community User for instance).

In the controller read the Attachment’s body in a String getter coded in Base64:

public String base64Value{get;set;}
public String contentType{get;set;}
public void loadAttachment(){
   Attachment att = [Select Id, Body, ContentType From Attachment limit 1];
   base64Value = EncodingUtil.base64Encode(att.Body);
   contentType = att.ContentType;
}

In the page:

<a href="data:{!contentType};content-disposition:attachment;base64,{!base64Value}">Download file</a>

[Chrome Extension] “Pack your link” extension on the store by enree.co (yes, thet’s me…)

a{ color: red !important;}

I’m not a marketing guy, I neither have requested advices from my marketing guys friends…I did it all my way and that’s why my brand new Chrome Extension will be forgotten in days!

Let’s start from the beginning…

Once upon a time there was a simple Chrome Extension I made at work for WebResults, my Company: you will hear about it in weeks, but not now.

After weeks of testing we decided to put it in the market but I didn’t now how to do it (I know, there si plenty of stuff online, but I don’t trust myself till I see things done!…that’s why because sometimes I behave like Goofy when dealing with simple tasks!!).

So I thought, “How can I do a clean job for my company without making foolish mistakes”?

The answer was “Create your own extension”.

That’s why I created url.enree.co (I love this domain name), a simple Url packing utility hosted on Heroku, written in NodeJS.

Why not creating a simple chrome extension to use this service?

Here you are Pack your link by url.enree.co.

Publishing a Chrome Extension on the store is really easy.

  1. Create your extension (start here if you don’t know what to do, it’s easy and fun)
  2. Go to the Chrome Store Developer dashboard: you have to pay 5$ to be able to publish your creations on the store, once in a lifetime! In few minutes you’ll be allowed to publish extensions and apps.
  3. ZIP your local extension’s folder and upload it: it seems that you cannot remove a product once uploaded (read more details here, but I’m not quite sure about it), but you can still unpublish to hide it.

See ya!

[Salesforce / Lightning] Loading scripts with RequireJS

a{color:red !important;}

UPDATE

Due to the introduction of the ltng:require, this post is no more a valid solution. Refer to the official Lightning documentation.

The following is a post that summarizes this blog post‘s solution (if you are not a TLDR; reader you will find there all my trials and errors).

Dreamforce 2014 came out with new awesome features on the Salesfoce platform: one of the most interesting has been the introduction of the new Lightning framework for fast development of reusable components.
In addition to the (still in pilot) Lightning App Builder (an amazing drag & drop tool for easy creation of apps), it’s not hard to figure out how far this new technology will lead the Force.com platform.

The main reason you want to develop a new Lightning component is the fact that you can compose components like a puzzle making them communicating using events: read the official development guide for more details on how to build your first lightning component.

One of the things you’ll be doing while developing new components, is using external libraries to give more and more features to your applications.
You’ll face the following constraints:

  • You can only get external libraries loaded from a static resource
  • You cannot use the {!$Resource.resourceName} expression because we are not inside a VisualForce page, so you have to simply refer to “/resource/[resourceName]” in your <script> tags

When loading more than one external scripts, sometimes happens that the order of loading is not the expected one (even if you have inserted the script tags in the right order).

You could use RequireJS library to overcome this problem (being sure that he’ll be responsible for loading libraries in the correct order).

But the question is: who is responsible to load RequireJS script?

Who will be executing the RequireJS loading code ONLY AFTER the library has been loaded?

Trying to get the right answer (see more details on the “fail” steps here and the community thread that brought me to the solution), I came to the following solution.

The solution is simple (to ease its understanding): you can improve it to add more features (e.g. style sheets loading) and to make a component out of it.

This is the main code (all the code has been packaged into this GitHub repository):

BlogRequireJSDinamic.app

<aura:application>
        <aura:handler event="forcelogic2:BlogRequireJSEvent" action="{!c.initJS}"/>
        <aura:registerEvent type="forcelogic2:BlogRequireJSEvent" name="requireJSEvent"/>
        <aura:handler name="init" value="{!this}" action="{!c.doInit}" />
        <div id="afterLoad">Old value</div>
    </aura:application>

BlogRequireJSDinamicController.app

({
    /*
        Sets up the RequireJS library (async load)
    */
    doInit : function(component, event, helper){
        
        if (typeof require !== "undefined") {
            var evt = $A.get("e.forcelogic2:BlogRequireJSEvent");
            evt.fire();
        } else {
            var head = document.getElementsByTagName('head')[0];
            var script = document.createElement('script');
            
            script.src = "/resource/RequireJS"; 
            script.type = 'text/javascript';
            script.key = "/resource/RequireJS"; 
            script.helper = this;
            script.id = "script_" + component.getGlobalId();
            var hlp = helper;
            script.onload = function scriptLoaded(){
                var evt = $A.get("e.forcelogic2:BlogRequireJSEvent");
                evt.fire();
            };
            head.appendChild(script);
        }
    },
    
    initJS : function(component, event, helper){
        require.config({
            paths: {
                "jquery": "/resource/BlogScripts/jquery.min.js?",
                "bootstrap": "/resource/BlogScripts/boostrap.min.js?"
            }
        });
        console.log("RequiresJS has been loaded? "+(require !== "undefined"));
        //loading libraries sequentially
        require(["jquery"], function($) {
            console.log("jQuery has been loaded? "+($ !== "undefined"));
            require(["bootstrap"], function(bootstrap) {
                console.log("bootstrap has been loaded? "+(bootstrap !== "undefined"));

                $A.run(function(){
                    //do whatever GUI initialization you want
                    //in the aura context
                    $("#afterLoad").html("VALUE CHANGED!!!");
                });
                
            });//require end
        });//require end
    }
})

This is what you’ll get in the developer console of your browser:

RequiresJS has been loaded? true
    jQuery has been loaded? true
    bootstrap has been loaded? true 

And you will see “Old value” string replace with “VALUE CHANGED!!!” in the page body.

What has happened?

When the app loads (init event) the doInit function tries to understand if the RequireJS library has been loaded.
If so fires a BlogRequireJSEvent event.
If not yet loaded, dynamically creates a <script> tag with the path to RequireJS, binding an onload handler, which in fact will inform that the library has been loaded, using the same event.

The same app is also an handler for the BlogRequireJSEvent event trhough the initJS function: it will load sequentially jQuery and Bootstrap libraries: this way you are pretty sure libraries will be loaded in the correct order.

The next step is to make a component out of this app so you can use a RequireJS loader component in all your apps and make all your components handling the BlogRequireJSEvent event.

TCO14 (My) Chronicles

Top Coder Open 2014 has passed and again has been awesome.
The coolest things? Absolutely the developer talks, made by important and influent people from the tech world.
The second cool thing is that I had the chance to blog the whole event and also that I got the 3rd place in the Super Awesome Cloud Mashaton.

The followings are all the posts (in chronological order) I wrote for the TCO14 Blog in the past 3 days.
Enjoy it!

Registration has started!

Short story long: 24 hours trip, 9 hours time zone delay, 3 flights, 1 run at New York airport not to lose my flight connection, but finally I’m here!

I knew it would have been awesome, but it is more that I thought!

Lot of awesome boots, great sponsors, and the whole world ready to compete!

What are you waiting for?
Registration has started, come here to enjoy Top Coder Open 2014!

Topcoder Open Booths

I needed 3 beers to get the right confidence with English (hey children out there, don’t do this at home!) but I managed to talk to all the company’s booths at the 2014 Topcoder Open I could , and I can say it’s been awesome!

In alphabetical order:

  • Appirio: is it necessary to talk about it? I talked the whole time with “Appirians” so I don’t need to tell you how awesome this booth was!
  • Drumpants: as a drummer, I’ve been attracted to this booth like bears on honey. It is a wearable device to make your body have the beat! Try it and you will love it!
  • Facebook: like last year, this booth is full of awesome #swag, pens, note books, stickers, frisbees, a chance to get into this #amazing company!
  • Google: again, do they need a presentation? Come to this booth to see an amazing Chromecast broadcasted game, have a chance to talk to some Google guys and grab some cool swag!
  • IBM Bluemix: they have a cool booth (and cool gadgets). It is actually something you want to explore, a big sets of useful tool for developing advanced and ready for production apps, using advanced features (such as Watson)…check it out!
  • IDEA market: I’ve been attracted by this booth because a sign said “IDEA Market is a curated crowd-sourced marketplace for ideas” and “START YOUR OWN COMPANY TODAY!”…well these are words I constantly think in my head. They simply try to make your ideas come to life searching for investors that could fund your thoughts…isn’t it awesome?
  • HP Idol On Demand: they had developed a bunch of APIs to give your app more and more features (sentiment analysis, language recognition, categorization, …), and I had a cool chance to have a talk with the developers that make these services up and running. Come here to have a great talk!
  • HP Sprout: I’ve been attracted by the fact that they presented something to put my hands on. HP Sprout is a creative workstation with which you can do a lot of cool stuff (3D modeling, realtime graphical design, multitouch support, …); it is also equipped with developer APIs to enhance its features, watch its demos to see this in action!
  • Nymi: I had a chance to see this technology before Top Coder Open, and I found it really fascinating and “romantic”: it is a device (and a set of APIs) used to authenticate you using your heart beat. You will log in with your heart and no more with a cold keyboard 🙂 BTW have a talk with the guys and the booth and let them inspire you!
  • Two Sigma: don’t you know 2 Sigma’s mission? You better know, they are a technology company that applies a rigorous, scientific method-based approach to investment management, they are focused on invest in the best ideas out there, so why not talk to them? (They also have awesome gadgets!)
  • 3DSystems: their booth is really attractive. They have an oculus rift to play their game (sort of Jenga) using a “force-feedback” pen: if you participate to their tournament, you can win a ready to use 3D printer…is it sufficient to visit their booth? If not, they develop cool stuff based on 3D scanning and reproduction of objects / parts. Come to their booths to know more!

Again…if you haven’t come yet, we are waiting to share this awesomeness with you!

Mashathon competitors warriors: let the fight begin!

Are you brave enough to spin the wheel?

I actually was and with me 61 other mighty warriors.

These were the APIs you could “select” from (actually it was a wheel of fortune…so APIs choose you!):

  • Amazon
  • Facebook
  • Google
  • HP Idol on Demand
  • IBM BlueMix
  • Microsoft
  • Nymi
  • Salesforce

And this is the final list of participants to the competition, that ends tomorrow November 18th at 9 am.

Handle APIs

1
adinici Facebook, Salesforce, Pick Any

2
afamefunaudoba Google, Amazon, Salesforce

3
akinwale Facebook, Microsoft, Pick Any

4
alazyrabbit Salesforce, HP IDOL OnDemand, Bionym

5
alexei.bordei Microsoft, Bionym, Pick Any

6
ambatvinay IBM Bluemix, Bionym, Pick Any

7
amethystlei
wintokk
Google, Amazon, Bionym

8
andkon Amazon, IBM Bluemix, Bionym

9
avarada Google, Salesforce, Pick Any

10
Battlecruiser Google, HP IDOL OnDemand, IBM Bluemix

11
bharathMG
sharmibala92
Amazon, Salesforce, Pick Any

12
caLLMEKATOOTIE Amazon, HP IDOL OnDemand, Bionym

13
cjlittle
jasonwiener
Google, HP IDOL OnDemand, Pick Any

14
cyberjag Google, Amazon, Salesforce

15
d_jash Amazon, IBM Bluemix, Pick Any

16
dbradleyfl Amazon, HP IDOL OnDemand, IBM Bluemix

17
defatigue Facebook, Salesforce, HP IDOL OnDemand

18
degupta Salesforce, Microsoft, IBM Bluemix

19
djiofack007 Google, Salesforce, Microsoft

20
elkhawajah Facebook, HP IDOL OnDemand, Pick Any

21
FMX Facebook, Amazon, Microsoft

22
forcelogic Google, IBM Bluemix, Pick Any

23
gabrielgrant Salesforce, IBM Bluemix, Bionym

24
gauravs23 Google, Amazon, Pick Any

25
gkowligi Facebook, Amazon, Pick Any

26
harish_r88 Google, Salesforce, Pick Any

27
hi4sandy
sidthekid
Facebook, Google, Microsoft

28
igorbarinov Facebook, Microsoft, IBM Bluemix

29
james.le Facebook, Amazon, Salesforce

30
KadynCBR Google, Microsoft, IBM Bluemix

31
kennethFax Amazon, Microsoft, IBM Bluemix

32
leejefon
quattrozhou
HP IDOL OnDemand, IBM Bluemix, Pick Any

33
makarochkin
urname
Salesforce, Microsoft, Bionym

34
myung Google, Salesforce, IBM Bluemix

35
nf_happy
lunana
Google, Amazon, Microsoft

36
nickdr Facebook, IBM Bluemix, Pick Any

37
notpad Facebook, Google, Salesforce

38
peda Pola Google, Microsoft, Pick Any

39
pglotov Google, Amazon, Microsoft

40
phyllis Google, Amazon, Salesforce

41
ralphFurmaniak Facebook, Bionym, Pick Any

42

rewinning
nicks1087
mmconrad
Facebook, Google, Bionym

43
rogueleaderr Google, Amazon, IBM Bluemix

44
rriazi Amazon, HP IDOL OnDemand, Microsoft

45
selvaa89 Facebook, Google, HP IDOL OnDemand

46
shadyElyaski
lukedayze
Facebook, Google, IBM Bluemix

47
stephenhan Facebook, Salesforce, Bionym

48
supercharger Salesforce, HP IDOL OnDemand, Microsoft

49
talesforce Facebook, Google, Salesforce

50
terjen Google, IBM Bluemix, Bionym

51
vicho Amazon, Salesforce, HP IDOL OnDemand

52
williscool

Salesforce, HP IDOL OnDemand, IBM Bluemix

53
yedtoss Google, Amazon, Bionym

So good luck to you all (and also to me), be prepared to watch awesome brand new applications fighting against each other to achieve the top of the list!

Developer talks series: Cathy Lewis [CMO @ 3D Systems]

In the first morning talk we had the pleasure to meet Cathy Lewis, CMO at 3D Systems.

She had a great talk about 3D printing systems, from their early adoption (about 32 year ago, when I was born!) to current days.

Good thing about 3D printing systems is that you actually build things only when necessary (think of their use in the International Space Station where bringing all replacement parts could be way too expensive), they use only the right amount matter needed to create that reproduction, they reduce the dimensions of production lines, thus increasing production efficiency.

Today the constantly adoption by companies of such systems allow to break creativity barriers, making easier for developers / designers to touch with hands what they are designing.

Current 3D printing technology is evolving day by day, from healthcare (create body part replacements) to food (that’s right, they are printing food!! from delicious candies to astronauts space food); recently they have developed a way to print using metals, creating a more durable and reliable product.

One of the coolest applications is the idea that in the near future, when traveling, you won’t need to bring things with you because they will be ready (e.g. in your hotel room) “freshly printed” for your own use!

Lastly they are developing a haptic technologies to actually feel things before they are printed!

They are also hosting a series a topcoder challenges at touch.topcoder.com: come over to discover this powerful technology!

Developer talk series: Matt Thompson [General Manager of Microsoft’s Developer Evangelism and Startup Efforts]

First evening talk is with Matt Thompson, General Manager of Microsoft’s Developer Evangelism and Startup Efforts.

The first topic in this awesome talk was about last Microsoft’s announcement of open sourcing .NET platform to be available for all platforms.
This follows the philosophy of Matt’s group, that is allowing developers doing what they do better: hacking!

He distinguishes two kind of tech people in the market:

  • Consumers: they influence the market with their way to use technology
  • Developers: they have the ability to build things

We actually want to be part of the second group, he says, the most important for the market actually!

Don’t think of the word “hacker” as something necessarily bad: “Hacking is wanting to build”, and when building there is also a great tendence toward learning, and when they learn, they also share their skills “open sourcing” them.
That’s why we have to make programming a crucial part of every child study path, so students could be active participants in the global economy and not just passive consumers.

This has been a really inspiring talk, made by a man who works for one of the colossal IT companies out there, that shows how big companies not necessarly tends to sit down at certain age, but still try to improve themselves and innovate.

Developer talks series: Anthony Stevens [Solution Architect for the IBM Watson Ecosystem]

The second speaker of this morning is Anthony Stevens, Solution Architect for the Watson Ecosystem.

He told the story of IBM Watson echosystem starting from the famous Kasparov vs Deep Blue chess match till the recent Jeopardy! win of Watson (1st price of 1 Million dollars, see details here).

It is all about cognitive systems that can extract information from large amount of data, create their own categorization and are capable of providing the best answer.

Humans are part of the equation: cognitive systems can mimic human reasoning process with image recognition and language, evaluate data and provide responses, learn and adapt to new information. From last century computers are evolving by being at first tools, then assistants, then consultant and finally peer!

Watson is about creating the building blocks for cognitive science application (pretty much like Legos are created by single distinct parts that connect each other).

That’s why it perfectly fits into IBM BlueMix PAAS (Platform As A Service), a sets (really big set) of built-in tools (for whatever programming language you love) that helps developers integrate Watson and other IBM services with their apps, without worrying about all the build/deploy phase of the code, leaving the freedom to concentrate on what you like, the code.

Developer talks series: Gayle Laakman McDowell [Programmer, Founder, Author, Consultant, Speaker]

Closing the morning a great speach by Gayle Laakman McDowell, Programmer, Founder, Author, Consultant, Speaker.

Gayle took an awesome speech about how to face an Algorithm interview.

Algorithm questions test your ability to make trade-offs, they highlight your capability to work in team, Solving a problem together.

She listed some of the most important steps to consider when facing such an interview:

  • Code on a paper, this way you make less errors (no synthax highlighter, no autom complete, slow debugging)
  • Always talk while thinking: this way the interviewer can follow your stream of thoughts. Don’t stay in silence!
  • Listen to what is in the problem (make sure you know all the details) and ask questions, so you don’t lose anything
  • When executing your code test it with generic data set and not special cases (e.g. if confronting arrays, avoid using same size arrays)
  • Testing is really important: use test cases and try to test the majority of tricky cases that could make your code crash (null values, strangely shaped date, …)
  • Write beautiful code (this is the most difficult suggestion for me)

She leave us with one important quote: “Be a great engineer“.

Developer talks series: Mike Hines [Developer Evangelist, Amazon Appstore]

In this Tuesday morning, let’s meet Mike Hines, Developer Evangelist @ Amazon.

I’ve been really amazed by Mike’s talk; he is what an evangelist should be. He transmits his passion for what he does and make you want to do the same things!

The main focus of this awesome speech was “How to make money with your app?”, and his first suggestion for us programmers has been “Don’t forget to make money, please!”.

Mike presented a series of suggestions of how to increase app revenues, showing why the top 50 apps on the Amazon App Store makes more money than the rest of the apps.

It is not all about the quality of the game: there are great games on the store that don’t make much money, while other games, undoubtedly less cool, makes way more revenues!

This happens because of different factors.

Mike demonstrates, showing graphics, pie charts, numbers, and percentages, that on average basis 80% of the users that download an app become inactive users after just one week. Seeing this we could argue that it is better to speed up in app purchases on the first week of activity.

It turns out that this is not what it actually is needed to make a high revenue app: users on a span of 30 days spend more money than the first 24 hours, so the less users we have active the better service we have to give them to increase their loyalty to the app and make them purchase more and better.

Here is a list of suggestions I grabbed during the talk.

  • Tutorials are useful to instruct users how to buy things, but in app purchase should not be a mandatory action to have success in the game (top apps maintain their non-paying users!)
  • Generate post purchase tutorials to make user aware of what they bought: this is important because if user is not happy with their purchase, they won’t buy anymore!
  • Add new items on app regularly, differentiate your offering but not too much (you can confuse users)
  • Be clear about value and benefits of purchased items
  • Reduce barriers to frequent use (if user does a thing frequently, make it easy to go straight to the needs: e.g. level selection, difficulty selection)
  • Make the status of the game available on all user devices (es. level, purchases, …): it is frustrating to switch devices and lose all achievements
  • Tune the game difficulty: if it’s too hard, users leaves, if it’s too easy, users gets bored.
    Use “A|B testing”: tune the game variables to keep people in the game by understanding the right tuning of inner behavioral variables of the game (e.g. number of enemies, speed of vehicles, buttons labels, ….)
  • Adopt social engagement: this could increase users sense of competition, that is more play and more purchases
  • Make purchasing easy: this could lead to an increase in revenue by 75%
  • Market your app to all customers and be in all the stores: if you have spent money to make a game, make it available in all market places

Top developers know all these “secrets” and how to handle them, thus selling top apps.

Developer talks series: Scott Jelinsky [Principal Research Scientist at Pfizer]

I present you Scott Jelinsky, Principal Research Scientist at Pfizer.

As you may know, Pfeizer is one of the world’s premier biopharmaceutical company. Why would the company be interested in the topcoder community?

Scott shows how topcoder has been involved in the past year in several challenges to improve human genome analysis.

The community has been called upon to improve the algorithms behind this kind of analysis.

They posted the challenges with the following aims:

  • Increase computational speed
  • Maintain accuracy
  • filtering low prob markers
  • create reasonable sized data sets

They followed then the following steps to improve different pieces of the calculation flow:

  1. Improve algorithm speed: this leads to an incredible 14x improvement
  2. When the algorithm was no more a problem, they concentrated with data access to big data sets, achieving  2x improvement
  3. Then they tried the multithread path and achieve an important 2.2x increase in speed
  4. Then coarse-grained parallelization for further parallelization for additional speedup and division of large dataset across compute nodes to raise memory capacity with a 5x improvement

The whole work lead to an incredible increase of the computational speed by 1200x, from 10 hours to nearly 28 seconds!

The results became even more evident when comparing the analysis time for phenotypes: analyzing 203 phenotypes needed about 95 days to be completed, while now it takes only 10 minutes, an incredible 1300x improvement!

These numbers makes absolutely clear of much topcoder has helped Pfizer into enhancing their software analysis skills.

Developer talks series: Samantha Ready [Developer Evangelist at Salesforce.com]

I’ve already had a pleasure to interview Samantha in the past weeks for the TCO14 blog.

She joined 2014 Topcoder Open with a tech talk about Heroku and its integration with Salesforce.

Samantha showed how simple it is putting an application on production with Heroku: install Heroku toolbelt, push your git repo into an Heroku app, and instantly Heroku acknowledges what kind of app it is and runs the right environment for it to be ran. The only thing you have to think of is your code and how much you want to scale your app (the only limit is your wallet :), but you can still use Heroku for free! ).

One of the features she used is the Heroku Button: with an Heroku button you simply click on a button to make an app working in few seconds. All you have to do is sit down on your chair and wait for the green light!

The demo application was used to handle a list of personal contacts (no built-in integration with external services) using NodeJS server side and AngularJS on client side.

In few minutes Samantha added integration with Salesfoce (using forceng.js, a set of services for integrating AngularJS apps with the Force.com platform) allowing her app to communicate directly with her Salesforce ORG to make it showing her contacts on the CRM and easily (and smoothly) view / edit them with a single tap!

In half an hour she had her app up and running and easily communicating with her Saleforce ORG!

Awesome!

Last thing to say, Samantha has a really swagged-out laptop (envy in my words).

Developer talks series: Robert Severn [Head of Development at HP Aurasma]

If I were the judge of this talk I would give A+++.

Why?

At the beginning of the presentation a 3D “augmented reality” Ironman showed up in the stage with Robert Severn (Head of Development at HP Aurasma)…simply awesome!

I was too amazed to take any pic, but believe me it was amazing!

Robert briefly presented Aurasma, a cool SDK for augmented reality (desktop and mobile). It is available as an SDK or as a free app for iOS and Android mobile devices. Its image recognition technology uses the camera to recognize real images and then overlay awesome things over them in the form of animations, videos, 3D models, and web pages.
Its no mystery that teachers are among the most active group using the platform.

Then it was HP Idol OnDemand time: a cool set of RESTful APIs free and ready to use (I’ve actively developed on it, believe they are awesome) for processing unstructured data to solve some of the toughest information challenges. These APIs can compute analysis with large data sets providing categorization of contents, indexing, fast search, image recognition, and other useful features (jump here to create your free account).

The topcoder community has worked a lot in the past months on integrating HP Idol OnDemand with diverse applications (see the track here).

Finally I want you to have a look at Sprout technology: an immersive experience for creativity!

Watch this video for more details!

Girls in STEM @TCO14

“Where are all the girls?” I’m usually asked this when attending my university computer science courses, in fact the guys used to heavily outnumber the girls. Why this discrepancy?

Today’s panel shown the following “girls in STEM” and Glenn Weinstein (he’s a guy in STEM 🙂 ):

  • Deepti Srivastava, Technical Manager at Google (moderator)
  • Leah McGowen-Hare, Master Technical Trainer at @salesforce
  • Grace Nordin, Technical Program Manager at Google
  • Ashley Mennel, CRM Strategy Consultant at Appirio
  • Jefreena Packianathan, Workday Integrations Consultant at Appirio
  • Glenn Weinstein, Chief Information Officer at Appirio

The talk was focused on describing which barriers to reach the heights of their companies each woman invited to the panel has faced in their careers.

It seems that the most of the problem is related to the fact that computer science is, among society, considered male and nerdy stuff, thus this makes studying science (or in our case computer science) an unacceptably difficult challenge for women (a society challenge, not intellectual).

The suggestion is: do what you like, don’t stop listening to your passion and follow your way.

Computer science is not only programming but a full set of technology related activities that not necessarily leads to be the best programmer in the world: the important thing is to do what you love being yourself.

As Jefreena said, you don’t have to be the very best programmer in the world but you have to give to your work something special, creative, that gives you and your company value.

The panel presented personal experiences, point of views, to demonstrate that women worth the same weight as men, if not more sometimes, given the fact that as of today (luckily things are changing) they have to struggle more to achieve the same results (they talked about the “glass ceiling” that sometimes seems to block you from getting in the highest steps of your company).

Closing quote: “no one fits into a single box, you aren’t one thing and don’t let people put you in one” (Leah McGowen-Hare), so go on with your ideas and be yourself!

Super Duper Awesome Cloud API Mashathon

I waited all the year for this event (hoping to be part of it) and it finally arrived!

I have a little conflict of interest (my app is the 7th) that’s why I won’t write any comment on the apps but simply report the description that each team gave us.

Watched
Voice recognition keyword search

Car pooling app
Car pooling android application for people to share their car rides. Without using any backend server, Facebook Parse syncs the data between the devices, AWS stores user data and Firebase for Realtime Chat between users.

Be a hero!
A web based platform that enable people to inform the world around Ebola especially it provides tips to avoid the disease. It does that automatically in many languages.

Meet Grinder
Meet Grinder prepares you for your next meeting or conversation, pulling the people from your upcoming Google Calendar events and showing you the highlights of their FB, Twitter, and LinkedIn feeds and profiles. Show up to your next BizDev deal, job interview, or Tinder date armed with immediate opposition research fresh in your brain.

Tely.vision
Tely.vision creates never-ending video streams using your favorite shows.

Social game
A social games app that gamifies your friends facebook activity. How well do you really know your facebook friends?

Moar Learn
Moar Learn is a book recommendation engine that utilizes the HP Idol OnDemand and Amazon Product Advertising APIs

Google Drive to Salesforce.com easy connector
Google Drive easy connector for Salesforce.com to view, edit and search for large amount of files.

Forcebook
Forcebook is an iPhone and iPad app built to leverage the social capablities of Facebook with the business power of Salesforce CRM. It lets you use Facebook social analytics for Salesforce contacts & leads and bridges the gap between personal and business communication by allowing cross-posting between Facebook and Salesforce Chatter.

Chainlock
Chainlock is a user-friendly bitcoin wallet – secured with the signature of your heart.

[Salesforce / Apex] Retrieving zipped static resource files from code

Some days ago one of my awesome colleagues asked me: “Can you get a zipped file into a static resource from Apex?”.
My very first thought was NO.

But after having said that syllable, I understood that this could be possible, using an HTTP GET call + cookies + correct resource URL.

This is the solution I came into:

Http h = new Http();
HttpRequest request = new HttpRequest();
request.setEndpoint(URL.getSalesforceBaseUrl().toExternalForm()+'resource/ZIPPEDRESOURCE/file.ext');
request.setMethod('GET');
request.setHeader('Cookie','sid='+UserInfo.getSessionId()+';');
request.setTimeout(60000);
HttpResponse request = h.send(request);
if(request.getStatusCode() != 200){
    //handle the error
    throw new CustomException('Unable to load resource');    
}
//now you can get the content
String fileContent = request.getBody();
//or
Blob fileContentAsBlob = request.getBodyAsBlob();

The last thing to do is to enable your instance URL from Setup > Remote Site Settings, allowing https://xxx.salesforce.com but also I suggest https://c.xxx.visual.force.com and wathever it makes sense (there could be some URL path I haven’t though to).

No surprise that this could be used to get any resource in the CRM (with the proper URL handling).

[-1 to #TCO14] – TCO14 for Dummies

6 Days to Top Coder Open and 6 blog post for each day!

I’m almost there, I’m writing from Rome airport waiting for the flight that will bring me (in “just” 15 hours) to San Francisco.

Move out, the geek army is coming!

The following is a blog post I wrote for the Top Code Open 2014 blog. Enjoy!

When I talked to my wife (a proud non tech-addicted woman) about blog post subjects, she first asked me “What is TCO? How can you describe this event to people that are not coders?”.

This has been a really good suggestion.

The Topcoder Open is about passion.

What do you call spending hours a day sitting in front of a computer trying to solve problems, creating new awesome apps, and exploring new technologies?

This is without doubts called passion.

Non technical people often ask me how I do my job, what programming looks like, and when I start describing it they watch me like I’m a big genius (or a strange alien). This happens because I don’t have a computer at my side and can’t show them how a window of my app simply shows a bunch of information or a button makes a panel appear (I know, a tech guy that is reading these lines, it is not always that simple, but it’s a starting point!).

Sometimes people don’t like things just because they never had a chance to test them.

This is your amazing chance!

The Topcoder Open is a great way to see code in action: from the Matrix style coding (Algorithm competitions…I must admit I feel a little dumb when watching these kind of competitions) to awesome apps created in few days (like in the Mashahton competition). You can breathe tech passion everywhere for 24 hours a days for the whole event and also learn from the best of the best.

New technologies come out daily and topcoder tries to get the best from them and people are happy to start competing with something they have never tried or seen before, just for the sake of learning and increasing their skills (if this comes with money…well…that will make your day!).

This is the main aspect of the Mashathon Competition: developers spin the API wheel and select 3 APIs (i.e. online data services, such as Facebook, Google, Amazon…it’s like when you use your Google+ account to login to another site or when another site shows your Facebook friends) and all the competitors have to do is write an awesome app that integrates these services and come up with a brand-new and innovative application…isn’t it fascinating? I assure you the results are incredible!

If what you want is all but learning to code, you always could participate in the awesome tech talks by leading tech specialists, meet big sponsors (Google, Facebook, Amazon, HP, TwoSigma, and Microsfoft) grabbing tons of gadgets from their booths: for me, this would be a sufficient reason to come!

 

 

And yes, there is always a time to party, meet new, awesome people and be part of one of the greatest events of this year!

[-2 to #TCO14] – 10 Reasons you should participate to TCO14

6 Days to Top Coder Open and 6 blog post for each day!

The following is a blog post I wrote for the Top Code Open 2014 blog. Enjoy!

1) Opportunity to compete live with or to watch competing the best of the best coder in the world

Tens of coders wisely selected among the Topcoder community will fight one another to become the best in their own track.
For the algorithm track, you can even watch them live solving incredible problems on video screens…it is pretty like watching the itch on the Matrix…you could be Morpheus for real (and you can even find the woman in red, cit.).

The Marathon track is like a fast run against time to complete different programming tasks one after the other!

The First to Finish track is like a code frenzy, where contestants try to finish tasks as quickly as they can!

For the Mashaton track, you will see contestants spin the wheel of fortune to get randomly 3 APIs: they have to combine them to achieve a new and innovative product.

You will have a chance to see awesome prototypes, made in few hours, that could be the next killer app (maybe you have just met the next IT billionaire). I personally love this track (I had a chance to get into it at TCO13).

The “Studio” track is the most visually attractive, you can appreciate amazing designers creating new logos, graphics, UIs just in front of you.

You will appreciate their immagination and creativity and maybe see the next TCO15 logo!

Marathon

2) Know coders (friends) from all over the world

People are there to share / show their skills, to have a couple of days of fun; the “mood” is incredible, all people are friendly even when it is difficult to communicate (I’m talking about my past experience…generally topcoders speak a great English, but I do not, so sometimes I used gestures to explain myself) you can still find someone to “eat your meal with”.

You can also learn just by chatting, receiving advices, new point of views, new ideas. I assure you will have a lot of new good friends at the end of the event!

3) What about the “staff”?

Without them Topcoder would not be so amazing!

Maybe I’m influenced by past event and I should not add any word to this point (I have a “bromance” with one of them, we literally fell in bro-love at first sight). The staff is there with at least a smile for each other; they try to make you feel part of the whole (and they actually do it).

4) Big companies on site!

Do you want to meet a guy from a big company and ask him something about your dream job?
Do you want a chance to get in touch with Google, Two Sigma, HP, Amazon, MemSQL, Sequoia Capital and maybe have a chance to get an interview or to get hired (yes, by competing you can also come to this!)?

If your answer is yes, you only have to book a flight to San Francisco!

5) SWAG

Point number 4 leads to point number 5. Get a bag and grab all the gadgets you can take.

6) Chance to visit San Francisco!

7) Listen to experienced and innovative speakers.

We are hosting the first TCO Developer Conference with an incredible lineup! See the agenda and speakers!

8 ) Did I mention the staff? Oh yes, I did, but they certainly deserve 2 places in this list

9) Cool lists have always about 10 items…

10) Do I really need to add another point?

Watch the TCO13 Closing film if you’re not yet convinced!

[-3 to #TCO14] – An evening talk with Samatha Ready, salesforce.com Evangelist

6 Days to Top Coder Open and 6 blog post for each day!

The following is a blog post I wrote for the Top Code Open 2014 blog. Enjoy!

The main reason I started competing in topcoder is because of salesforce.com contests.

In 2009, (casually), I became a salesforce.com developer, and from that time, I started working with this fast growing platform.

In the last 6 years I had the honor to see the platform getting bigger and bigger with new features, powerful tools, a stable cloud platform, and an expanding set of possibilities (Heroku is my favorite one) that really makes my job worth getting done.

But I think that the most valuable “feature” of this technology is the immense amount of docs, blog posts, forums, and repositories, all for free and ready to be consumed in your projects.

The salesforce.com community is really amazing and you always can find an expert ready to help you. If to this awesomeness you add a BIG event, DreamForce, and hundreds of evangelists that “spread the word”, you get why salesforce.com is one of the fastest growing companies in the world.

The 2014 Topcoder Open will see a great line up of speakers with its first Developer Conference Unplugged.

For all these reasons, I decided to ask Samantha Ready, Senior Developer Evangelist at Salesforce.com, and speaker for the event a few questions.

Hi Samantha, it is a pleasure to chat with you.

How does it feel to be a central part of this awesome community?

I am overtaken with gratitude and excitement all the time to be able to be at the hub for technology surrounded by some of the smartest minds in the business. Absolutely love the fact that I get to mingle with developers from all over the industry to hear about the cool things they are cooking up for their companies, and love when I can help with those innovations.

What does really mean to be an evangelist? I mean, the main reason is that your job is to spread the “Salesforce word”, but is there some sort of feeling of responsibility in front of the dev community?

I think being a developer evangelist is partially spreading the “word” aka the whys and how to’s of Salesforce. In addition to that, its also a matter of inciting imagination and possibility with devs helping them envision what they can build for their company and empowering them to use the building blocks they need to do those things. Documentation doesn’t always give that kind of context, and so I try to do it through stickier ways like a Udacity course, developer guides, Project Trailhead for learning paths, webinars, and talks to name a few.

You’ve been a girl that used to talk with robots (you have a background in computer engineering with a concentration in robotics), how and when did you chose to follow the web development and the Salesforce Evangelist path?

So don’t get me wrong, I loved robotics. It was a challenging beast and it was extremely satisfying seeing your robot compete or shipping a product. Truthfully though, most of the programming I did for my last job as an software engineer was low-level embedded C and Perl scripting which plays tricks on your psyche after a while. I lived out of the command line and didn’t really talk to any of the engineers I worked with because we were so heads down. I found Salesforce through a friend and while I had no idea what Salesforce was at the time, the company seemed extremely innovative and I thought it sounded like a good opportunity for growth. I jumped over to an internal development role and felt the atmosphere and company was a fit from day 1. Rapid development, tons of new languages and frameworks, competitive, and collaborative…my favorite things! I immediately loved the “instant gratification” aspect of web development rather than the 10-week push for an inch of progress at my former company, and haven’t really looked back. Both disciplines are great for sure, and they each have their own set of challenges, but I think I prefer the fast iteration of web development and the infinite learning possibilities for new tech.

Has the robotic passion ended or do you plan to reach that path again?

The robotics passion has definitely not ended, and I’m so happy that the internet of things trend is making its way into the enterprise!

How has this passion helped you in your evangelist career?

I think that my passion for robots has helped me geek out more times than I can count. I love to tinker, and I love to talk to people about their pet projects as well. In addition to that, I think it made me more confident in trying other things because it laid a foundation for my own self confidence which was “even if this seems impossible and you have no idea…google it, and figure it out.”

It is not usual to see a woman that loves to code, but recently (and luckily) the number is increasing. In my experience I always felt it was a matter of lack in interest. How do you, as an expert and successful woman, see this?

I think the best analogy I heard was from a colleague of mine (Mary Scotton) who said,”Just like some time ago when being a doctor was seen as a job only men do, that’s how some people see programming right now. But now, being a doctor is seen as a job for both men and women, and that’s where it’s going with programming.” I see the increasing number as a good sign and a definite trend, but I think for this to grow there still needs to be more proactive efforts. I think we need more awareness overall in schools, families, friends about motivating young men and women at a young age to take an interest in STEM education. There are already efforts in this direction: GoldieBlox, Girls Who Code, Hour of Code, Made with Code to name a few, but I think it needs to be even more prominent in both school programs and extracurricular activities to catalyze exponential change. I think if high schoolers have more of an opportunity to learn how to code or get a taste of computer engineering or computer science, we’ll see a big shift in the gender balance.

Were you attracted to the “nerd” world of coders or simply had a secret passion for computers and robotics or the random nature of life is the only explanation?

I fell in love with coding for the exact reason above–my school had a C++ class, and I had no idea what it was but I took it as an elective and had a blast. I took more programming courses after that, and eventually started tinkering on PCB layouts. I’m a polyglot nerd though, because besides coding I’m obsessed with physics, space, and marine science. I’ll nerd out over space or the ocean any day of the week.

You’ve actively worked on Salesforce1 recently. This is an important step for Salesforce and, as far as I worked on it, it actually is a great and important piece for the whole Force.com platform. Which is the feature you love most of Salesforce1?

So up until DreamForce my answer would have been the ability to implement custom Visualforce within Salesforce1 to be able to build dynamic mobile pages instantly deployed. I’ve made a few different iterations of a “Find Nearby” page that will locate restuarants, accounts, people, etc near where you are completely in JavaScript, Visualforce, and Apex in a little under an hour and displayed in an interactive google map.

Can you anticipate any future (and top secret) features?

Now that DreamForce is over, I can tell you about my not-so-secret new feature Lightning Components. Salesforce1 is a Lightning App that is built using Lightning Components, and as such the places where Salesforce1 uses Lightning Components will become extension points for developers. The Salesforce1 UI will not only be customizable to the point where you can not only build completely custom features from scratch but you will also be able to develop on top of the standard UI and still utilize all of the built in functionality the platform provides.

How do you see Salesforce1 in the next future?

Salesforce1 right now is a mobile app and a platform. This mobile app will eventually become the full experience for Salesforce–a new UI and unified desktop across all devices. This means build once and deploy everywhere, which will be huge.

Have you been working on side projects besides your evangelist job that you want to share with us?

I had started tinkering on an integration between the FitBit and Salesforce to store information over time to get more in depth and filterable analytics. I was hoping to build that out even further utilizing your Salesforce network on Chatter and turning it into a competition with colleagues.

What do you plan/want to say at the TCO14 developer talk? Any particular subject?

This is still TBD… Top Secret 🙂

Your bio in the TCO14 site states that you love “scuba diving, scaling mountains searching for the world’s best hot sauce while listening to good music”: did you find the world’s best sauce?

If you like pasta I can give you wise advice 🙂 World’s best is the search for the holy grail…and as such I think is equally futile. The “best” hot sauce is subjective depending on what you’re eating! So here are a couple: Fall foods (butternut squash, roasted veggies, chili) – Yucatan Sunset Picante Sauce, Chicken/Grilled foods – Nando’s HOT Peri Peri, Eggs or Beef – Yucatero XXXtra Hot Habanero, Veggies – Marie Sharp’s. Old faithfuls are Cholula and Sriracha 🙂

Page 18 of 20

Powered by WordPress & Theme by Anders Norén