Wednesday, October 31, 2012

Detect EDT Violations

One of the hardest ideas for developers to grasp in Codename One (or GUI programming in general) is the idea of a single event dispatch thread (EDT). The rules of using it and releasing it are sometimes complex and mistakes are very easy to make e.g.:
  • Writing complex/slow code that blocks the EDT thus slowing the entire application
  • Accessing Codename One widgets from a thread that isn't the EDT.

The problem is that both of these issues are notoriously hard to catch on  the simulator but often crop up on the device where race conditions can happen more easily and slow EDT performance is more noticeable.

To ease the process of detecting these violations we added a flag to the simulator allowing you to receive information about such cases.  When using light debugging you will see printouts to the console when accessing the EDT from a separate thread or taking too long to perform the task on the EDT. When setting it to full you will also see the stack trace where the violation was detected.

These tools aren't perfect and they sometimes printout warnings that are unwarranted while entirely missing a real violation. However they can be a valuable tool in improving your application's portability and responsiveness on multiple devices when used consciously.

Thursday, October 25, 2012

Screen Capture of Our Java One Session


For those of you unable to attend JavaOne this year, you can check out the full video of our session here. You don't actually see me but you can hear me talk and see the slides/demos since the feed from the projector was recorded.
Apple wiped my iPad the day before with a stupid iOS 6 beta bug and my version of the demo had some bugs in it, but other than that I'm pretty happy with the presentation.
Check it out.

Wednesday, October 24, 2012

Installing On A Windows Phone Device

We recently added Windows Phone support to Codename One, this allows you to build your applications as a Windows XAP application for installation on a Windows Phone device. Unfortunately of all the platforms we support (including J2ME and iOS) MS is the only company that chose not to allow standard OTA distribution so you will literally need a PC in order to install the application with a cable.

MS has a sort of beta distribution option which might alleviate the problem but we didn't get a chance to try it out.

Sending a build for Windows Phone is similar to sending it to any other platform, with the latest distribution just right click and send a build for Windows Phone, its just that simple.
Unlike most other platforms MS didn't burden us with the silly need to sign the distribution (they can sign it themselves when we upload to the store, makes MUCH more sense!).

Installing said build requires that you enable your device for development for which you need to pay Microsoft. The instructions for doing all of this are all here.

Friday, October 19, 2012

[Survey] Developer Economics 2013: Best practices for app development & marketing

This is a guest post from Andreas Pappas from Vision Mobile, I'm posting this at their request since I think our community can both help them in their research and benefit a great deal from reading the results!
Shai.


As we launch the Developer Economics 2013 online survey, Senior Analyst Andreas Pappas introduces Developer Economics 2013, the fourth in our series of developer research reports. This time we're benchmarking the building blocks of the app economy, from analytics tools to voice APIs. Join us in Developer Economics 2013, take our online survey and win great prizes.

Back in June 2012 we launched Developer Economics 2012, the third in our series of reports that focused on app ecosystems, developer segmentation, platform economics and global app trade routes.
Description: http://www.visionmobile.com/wp-includes/js/tinymce/plugins/wordpress/img/trans.gifToday we are embarking on the evolution of our developer research: Developer Economics 2013 focuses on the best practices for the tools, services and APIs that developers use to build, market and monetise their apps. Take the survey, have your say on your favourite tools and win prizes, including an iPhone 5 and a Samsung Galaxy SIII. The survey will soon be available in Chinese, Russian, German, French, Spanish, Korean. Developer Economics 2013 is sponsored by AT&T, Mozilla, Nokia, BrightCove, BlackBerry and Telefonica.
A service economy develops around app ecosystems
The mobile development landscape has undergone a massive transformation since the early days of the iOS and Android platforms. In the early stages developers faced a limited supply of tools and services to assist them with crossing platforms, beautifying the UI, bridging fragmentation, integrating with ad networks or analysing user behaviour. They had to create most of the building blocks from scratch using their own means.
As mobile application development continues its growth from 100,000s to millions of apps, the rush for gold has sparked a rush for spades. Across the developer journey, there is now a tool for (almost) every developer need, from app testing to ratings management. The app economy is evolving towards a service economy where developers can pick from a range of tools and services to assist them along the plan - develop - market journey. But best practices are yet far from clear.
Third-party developer services, ranging from user analytics, location APIs, bug-tracking tools, app-store optimisation services, and cross-promotion networks are, today, vying for mindshare among developers. Developer Economics 2013 aims to identify the most popular developer services among these and measure their Developer Mindshare. Furthermore we aim to understand the reasons developers choose the services they do and how they rate them across range of key performance indicators (KPIs), such as reliability, availability across platforms and ease of integration within an app.
The right tools for building an app business
Developer Economics 2013 is benchmarking best practices in a variety of developer tools sectors:
Ad Networks
AdColony
AdMarvel
AdMob
AdWhirl
Airpush
Apple (iAd)
Burstly
Fiksu
Flurry
InMobi
Inneractive
JumpTap
Lead Bolt
MillenialMedia
mOcean Mobile
MobClix
Nexage
mopub
Smaato
warp.ly
Back-End as a Service
ACS
Applicasa
Apstrata
Buddy
CloudMine
CloudyRec
Deployd
FeedHenry
iKnode
Kinvey
kumulos
mobDB
Parse
ScottyApp
sencha.io
StackMob
Usergrid (Apigee)
Trestle (Flurry)
QuickBlox
Bug Tracking
Airbreak
Apphance
BugSense
Crashlytics
Crittercism
Hockey App
TestFlight
Usermetrix
Cross-Platform Tools
Adobe AIR
Appcelerator
AppMobi
Brightcove
Corona
Marmalade
Mono
MoSync
PhoneGap
Qt
RunRev
Sencha
Unity
Cross-Promo Networks
adDash
AdDuplex
AppCircle (Flurry)
Applifier
AppFlood (Papaya)
Chartboost
clashmedia
Fiksu
G6Pay
GreatPlay Network
Jampp
maudau
RevMob
SponsorPay
Tapjoy
W3i
Wavex (6waves)
User Analytics
Apsalar
Bango
Distimo
Flurry
Google
Localytics
MobClix
mopapp
Testflight Live (Burstly)
UserMetrix
Voice Services
AT&T
Deutsche Telecom
FonYou
GetVocal
HarQen
Hoiio
Ifbyphone
IOVOX
Jaduka
Microsoft
OneAPI
Sendflow
Skype
Telefonica
Teleku
TringMe
Tropo
Twilio
Verizon
Vivox
Which tool should you use and which one should you trust?
These sectors are becoming increasingly crowded with new entrants while merger & acquisition activity is changing the landscape almost on a monthly basis. The tools and services benchmarked in this survey are becoming the building blocks of modern apps and Developer Economics 2013 aims to establish best practices for the key developer tools sectors across the developer journey.
Developers are often at a loss when it comes to selecting the right tool or partner among the hundreds of services available to them. Cost is just one variable in the selection process but quite often, it is not the most crucial. The reliability of a service, the regional reach, key metrics (such as eCPM or fill rates), as well as the flexibility to adapt to the developer’s needs are sometimes more important than cost, particularly when developers invest time, money and resources to integrate a third-party service with their apps.
Developer Economics 2013 aims to assist developers with the selection process by benchmarking a number of third-party tools and services across a range of KPIs.
We are also helping third-party tool and service providers receive valuable information on how developer rate their services and their key decision criteria when selecting a service. If you're a tools vendor being benchmarked, now is the time to spread the word to your developers.
If you are a developer your input into this research is very valuable to us and we’d like to invite you to take the survey.
Feedback welcome, as always
- Andreas

Monday, October 15, 2012

Apply Code Changes (Edit & Continue)



One of the cool things in HTML development is the ability to just instantly reload and see your changes, its countered by lack of static typing and a proper compiler but the time saving is still pretty great.

Java has had something similar for years, in Netbeans its called Apply Code Changes and Eclipse has a similar feature which is even more seamless... Just change the code and apply the change. It just works and you don't need to rebuild and restart from scratch.
This is remarkably helpful during long debugging sessions where you step over a break point and think: "what if this line was X"... Now you can just  try that instantly.

Many J2ME/EE developers aren't familiar with this feature due to the emulator environment or complex EE deployment scenarios, but to me personally this is a remarkably helpful feature especially when tracking issues in the Codename One Designer but also within our Codename One applications.

I would like to apologize for the delay between posts, I will try to get back into the posting groove within the next few weeks as we recover from Java One.