Getting startedFrom the description and instructions page you can read:"Android Market offers a licensing service that lets you enforce licensing policies for paid applications that you publish through Android Market. With Android Market Licensing, your applications can query Android Market at run time to obtain their licensing status for the current user, then allow or disallow further use as appropriate"."The License Verification Library (LVL) handles all of the licensing-related communication with the Android Market client and the licensing service. With the LVL integrated, your application can determine its licensing status for the current user by simply calling a library checker method and implementing a callback that receives the status".

That page is quite elaborate and definitely a good starting point for integrating the LVL into your project. Note that your app needs to support SDK 1.5 or higher (API level 3 and onwards).

The LVL I did not set up as a Library Project in Eclipse because it messed up my Subversion. It got totally confused, indicating stuff wasn't checked in, but I also could not check anything in even after a cleanup. Or it kept indicating there were waiting changes to check in, even though I had it checked in. Maybe it's Eclipse Ganymede, maybe it's me :). So I just imported the source code in my project. Disadvantage is I'll have to update each project that uses the LVL when an update of the LVL arrives.

Furthermore I used the ServerManagedPolicy and changed the salt for the AESObfuscator (which is used to securely obfuscate data written to and read from storage).Note that the AESObfuscator has been reported to be quite slow.

Setting up a test response for license checks works fine for brand spanking new apps like mine was. On my emulator I used my developer account, on the real device (a Nexus One) another gmail account as test-account.

Quite essential in the documentation is the line "Signing in using a publisher account offers the advantage of letting your applications receive static test responses even before the applications are uploaded to the publisher site".It took me (and apparently others) quite a while to figure out that that means that the test accounts only get the Test response when you've uploaded the app to the market and saved it! Otherwise they will get ERROR_NOT_MARKET_MANAGED.

To obfuscate or not to obfuscateI decided not to obfuscate my application. Main reasons being:

It won't prevent hackers from decompiling your code for 100% sure.

It gets a real pain in the @ss to figure out the real line of the code when you get an error report or exception.

You should do a full regression test after obfuscation. Of course :) you have that all automated but still...

Note also that the post explaining ProGuard obfuscation requires a fix (it obfuscates too much). It might be updated now.Here's a tip when you're using Proguard obfuscation to easily indicate which classes shouldn't be obfuscated (in short: by letting those implement a specificly named interface and put that as a keep-rule in the proguard config).

Great tip here to even more minimize the number of classes/interfaces you shouldn't obfuscate.

For another nice introduction and more in-depth details on why you could use Proguard for obfuscation, shrinking and optimization, see this post.

Server Response ExtrasDuring testing on the emulator I found out that the Server Response Extrasare never set for the test responses, so it's quite hard to test different behaviour here on different values. On the other hand, the default implementation seems to handle it quite ok. If you don't like it, you'll have to dive into the LVL code...

Testing new versions of an appI also found out that if you increase the versionCode of your app, and try to test that app on a real phone with a test account, you'll get back ERROR_NOT_MARKET_MANAGED. Most likely this is because of the new versionCode, which the market licensing service does not recognize/accept. I have not seen the ability to just upload a new version of an app and only save it, it seems you can only publish it... And this thus means your test accounts can't test the app before release...

Looking at a reply in this post it seems you don't even want to save a newer version because the current version of your app disappears from the market! Another report of this here.

As mentioned in the first post, the only way to test a newer version seems to set the versionCode to the currently published version and use that during testing on a real device with test accounts. Sounds doable, there's not too much risk of forgetting to increase the versionCode when publishing: the market won't let you upload an app with the same versionCode as already published.

Note: Maybe the new "draft upload" feature fixes the above issues (see sixth item in this post), didn't try that out yet.

Some answers from Trevor Johns in the post clarify things re: responses a bit but not all:

"If an app is not published AND not draft, then you'll get ERROR_NOT_MARKET_MANAGED."Yes, but if your testing with your developer account on the emulator, you get back whatever is set in the test response. Even for an app with a newer versionCode.

"If an app is in draft (never published), then we send LICENSED for all requests for that app."Is it? It seems it sends back to test accounts on a real device what's set in the Test response. Not tested yet for increased versionCode.The reply on 6aug10 from Trevor Johns in this thread says it too. Unless I did something wrong, I noticed different behaviour.

"If an app is published (or has been published then unpublished), then the response is driven by the dev console settings for the developer/testers, and purely by purchase history for everyone else."Yes, but if you have increased the versionCode, test accounts on a real phone get back ERROR_NOT_MARKET_MANAGED.

I also wanted to test what happens when I publish a new version, would people with an older purchased version of the app still get verified successfully, and what does the provided LVL code do when it gets back LICENSED_OLD_KEY?My conclusion: that combination seems only testable on the emulator for the developer account before publishing the app (note I didn't try the scenario on a real device with the developer account). After really publishing the app you can test it of course, but that's a bit late, you want to try it before publishing, before the world can download it.For an app never published before, you can test the LICENSED_OLD_KEY as described here.

WishesWhat would be great to have available in the developer console is to see how many verification requests failed, and with what error. This way you can get an indication on how many people try to illegally use your app, and get an indication whether something might be competely wrong with your app (e.g nobody gets correctly verified anymore).You could then also see how many people haven't upgraded yet via distinct the OLD_LICENSE_KEY responses.As long as this kind of statistics is not provided by the market, but you still want to know about these kind of failures, what you could do is report any error results to your own separate server (though of course a skilled hacker could prevent that from being sent).

Saturday, October 16, 2010

Pretty annoying that you only have 325 characters in the description field when submitting an app right? You really have to use the space wisely.

One of the things you usually want to put in what you have added/changed in the current release, so people who want to update know what to expect. That takes up precious space of those 325 characters. But from now on you don't need to worry about that anymore because... it turns out you can put any text in the android:versionName attribute in the AndroidManifest.xml!

So what I usually do is put in versionName the digits from the android:versionCode attribute separated by dots, then a space and then a short description of what has changed since the last version. For example, suppose android:versionCode="103" then androidName becomes:

android:versionName="1.0.3 Preferences are now correctly stored"

So what does it look like? Well here's first a screenshot of an app that only puts in a version number in the android:versionName attribute:

And here's an example of an app that fully uses that attribute:

I do not know what the maximum lenght is of the versionName field, but apparently you can put quite some text in there, as can be seen from above screenshot.

Update: well, putting the version information in the versionName is not necessary anymore, since from now on there's a separate field to put the recent changes into. What now quickly comes to mind to put into the versionName could be the minimal SDK version number your app supports. That can be useful for people who want/need to get your app on non-Google markets. This way they get at least an indication whether the app can run on their phone or not.

Update: and recently (definitely since 23 Feb 2011) they have limited the length of the versionName field to 30 characters, because if you exceed that, at apk-upload time you'll see: "The versionName in AndroidManifest.xml exceeds maximum (30)."

Sunday, October 3, 2010

On one of my last projects I had to integrate JBoss ESB 4.5 GA with ActiveMQ 5.4.0 and Spring 3. NOTE: the fixes below also work for integration with JBoss 5.1 Application Server.

My starting point was of course this post: Integrating Apache ActiveMQ with JBoss. (Or is this the original?)Part of the requirements mentioned in that article (Apache ActiveMQ 4.0.1+ and JBoss 4.0.4+) got me worried that the steps described might not work for my version of JBoss and ActiveMQ. Even though there's a '+' after the version numbers :)

First I had quite a hard time finding the .rar file! Finally found it in \lib\optional in the ActiveMQ zip: activemq-rar-5.4.0.rar

After that I followed the steps including up to 'Configuring JBoss'. In there you also have to start JBoss again.I didn't see any exceptions fly around so thought all was fine, so I started the consumer ('ant consumer').But there I got:

Strrrange, because I thought the server started fine. After quite some searching, I figured out the error message probably indicates that there's just nothing listening at localhost:61616.After carefully checking the startup log (searching for 'activemq') I found out it hadn't started!

17:27:42,265 WARN [ActiveMQResourceAdapter] Could not start up embeded ActiveMQ Broker 'xbean:broker-config.xml': Line 49 in XML document from class path resource [broker-config.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'persistenceAdapter'.

So journaledJDBC is unknown. There must be something with a wrong namespace version or something. From the XSDs from here it seemed there was an element in the wrong place. So I just removed the whole persistenceAdapter element.

I also noted that there is a persistenceFactory element in the AMQ 450 broker-config.xml, which is not present in the Integrating Apache ActiveMQ with JBoss post.So I also changed that one's dataDirectory to be the same as in the (just removed) persistenceAdapter:

This blogpost is the last of the 'Best of this Week Summary' series. Looking at the number of subscribers, I decided it's too low to be worth the effort.

Therefore, from now on I'll only post "real" blogposts written by myself, no more weekly summaries.Those posts will contain lessons learned, tutorials etc.This change of format also implies that the posts will be less frequent but hopefully much more interesting and relevant to a greater audience.

For the fans, here's the last set of items for "Best of this Week Summary", 27 September - 3 October 2010:

And lastly: a couple of summaries on Thomas Kurian's keynote of last week's JavaOne 2010 on Oracle's plans with Java, and a summary of the General Technical Session regarding the future of Java SE, EE and embedded.

Sunday, September 12, 2010

Nice: "HTML5 Boilerplate is the professional badass's base HTML/CSS/JS template for a fast, robust and future-proof site.After more than two years in iterative development, you get the best of the best practices baked in: cross-browser normalization, performance optimizations, even optional features like cross-domain ajax and flash. A starter apache .htaccess config file hooks you the eff up with caching rules and preps your site to serve HTML5 video, use @font-face, and get your gzip zipple on.Boilerplate is not a framework, nor does it prescribe any philosophy of development, it's just got some tricks to get your project off the ground quickly and right-footed."

Sunday, September 5, 2010

A "series of (currently 5) articles introduces Contexts and Dependency Injection for Java EE (CDI), a key part of the Java EE 6 platform. Standardized via JSR 299, CDI is the de-facto API for comprehensive next-generation type-safe dependency injection as well as robust context management for Java EE. Led by Gavin King, JSR 299 aims to synthesize the best-of-breed features from solutions like Seam, Guice and Spring while adding many useful innovations of its own".

Sunday, August 29, 2010

A tutorial in which you will "create Pingstream, a small notification tool that uses PHP (sorry ;), jQuery and RSS to communicate over the Extensible Messaging and Presence Protocol (XMPP), a set of XML technologies designed to support presence and real-time-communications functionality."

and you're done.
But no! It only runs one time, or 1.5 times or whatever; definitely not endlessly.

This pretty basic requirement of looping a set of animations indefinitely is apparently a known bug. I haven't been able to find out if it's still an outstanding issue today (August 2010) but unless I implemented it incorrectly, it is definitely present in SDK 1.6.
Based on the answers in that thread and the example code here, I came up with the following solution:

XML
A fadein.xml and a fadeout.xml. See the end of this post for the complete code.

Pretty strange, the CPU doesn't seem to be pegged... It says it recovers, but I guess the warning is there for a reason. Can the code be modified to avoid these warnings?
It might be a platform bug. Indeed I do see it appear in 1.6 but not in 2.1.

Sunday, August 22, 2010

Of course I have to mention Oracle's Java lawsuit against Google. Several viewpoints can be found here (more on the profit/free markets) and here (more elaborate and technical details) and here (Android == Java?).

A Big Data analytics equivalent for LAMP (Linux, Apache HTTP Server, MySQL and PHP) architecture based on Hadoop. Mentions Adobe and Facebook using several components. Interesting is the mentioning of Facebook which created a web-based tool, HiPal, that enables non-engineers to run queries on large data sets, view reports, and test hypotheses using familiar web browser interfaces. More details on how Facebook uses Hadoop can be found here.

Gartner released their new 2010 Hype Cycle. Always useful to see if you missed any new trends :)

An extensive tutorial on how to work with XML, JSON and Google's protocol buffers within Android applications. It shows how to "develop a Web service that converts CSV data into XML, JSON, and protocol-buffers formats. Then you'll build a sample Android application that can pull the data from the Web service in any of these formats and parse it for display to the user". Assumes Froyo 2.2. Also shows a short comparison in performance between the three protocols.

Evolutionary architecture and emergent design: Leveraging reusable code, Part 1 and Part 2.

A Spring MVC 3 Showcase, which should give you have a good idea of what the technology can do.It includes a sample project, along with a supporting slide presentation and screencast. After digging in, you should have a good understanding of what Spring MVC can do and get a feel for how easy it is to use.

Sunday, July 18, 2010

How Google App Engine does session affinityexplained. In short: as long as the requests from the client are within minutes (it seems) of each other, the requests will get send to the same node. If the time between two requests is longer, it might get sent to another node, potentially causing a noticable delay. A solution to prevent this is to send a 'ping' every minute from the client.

The CERT (Oracle) Secure Coding Standards for Java: "rules and recommended practices for secure programming in the Java Platform Standard Edition 6 environment. This is a work-in-progress and they actively seek your feedback and involvement in making this effort a success."

18:27: getItemViewType() is used to make sure convertView is of the correct type in getView().

19:06: Make sure getViewTypeCount never changes. Note that it doesn't hurt performance if you always return say 10 even if you only have 2 different view types returned by getItemViewType().

30:13: Shows how to create a custom list selector in xml.

40:40: android:smoothScrollbar to prevent scrollbar changing size. Especially useful for listviews with items of which height can differ greatly

41:00: Use fill_parent instead of wrap_content in a ListView

53:10: If refreshing the whole screen via notifyDataSetChanged() is too much of a performance hit, you can try to get the visible position and use getChildAt() to figure out what view to update. Example code for that is here.

53:50: Use inflate(item, parent, false) to prevent relative layout attributes being ignored in a listview.

In general: don't try to outsmart the ListView by building your own caching, nor depend in any way on the order of getView(position) getting called.

Writing zippy Android apps

Zippy means non-janky which means sluggish, slow etc.

08:00: example apk of how not to do things/see how stuff performs. Includes small Perl sqllite wrapper script to see how much is being read from sqlite

15:00: read/writes I/O on emulator is a lot faster than on a real device

19:00: An AsyncTask can get killed before it finishes, e.g if the user hits the Home key. If it's important that the task finishes, use IntentService.

Below are a couple of lessons learned which I remembered to write down:

Wicket

In a ModalWindow you'd probably want to use a AjaxSubmitLink, not a SubmitLink, if you want to use modalWindow.setWindowClosedCallback(). See here for explanation.

ajaxrequesttarget.addComponent: addComponent name might be a bit confusing for beginners. It means "add the component to the list of components be re-rendered/refreshed".

An AjaxSubmitLink doesn't update the model when setDefaultFormProcessing() is set to false. Not totally illogical, but you still might run it to it when you don't expect it.

Here are tips to validate related fields. (In the original the example code is missing.)

AjaxSubmitLink: if you get a "Component-targetted feedback message was left unrendered. This could be because you are missing a FeedbackPanel on the page" warning in your Tomcat server console, it seems you have to tell in the onError() of the AjaxSubmitLink which feedback panel(s) you want to have updated.You get the warning even when you have feedback panels higher up in the tree of the (Base)Page. An example to update those panels could be:Component infoFeedback = getPage().get("infoPanel"); target.addComponent(infoFeedback); Component warnFeedback = getPage().get("warningPanel"); target.addComponent(warnFeedback); Component errorFeedback = getPage().get("errorPanel"); target.addComponent(errorFeedback);

To show/hide any HTML markup block dynamically, just wrap it with a WebMarkupContainer. In the code create that wrapper and make it visible or not depending on your requirements:boolean makeVisible = false;WebMarkupContainer blockContainer = new WebMarkupContainer("blockWrapper");blockContainer.setVisible(makeVisible);add(blockContainer);

Sometimes you might get a popup when using a ModalWinow that says "Reloading this page will cause modal window to disappear" when you don't expect it. Check the logs/console, you might just got an exception in your app (after which Wicket tries to redirect to the error page, which causes the popup to show; at least that's my reasoning).

JUnit

If JUnit can't find the Spring context.xml in the resources directory, then you have to add the resources dir to your Build path

Mod4J

Does not really support LazyLoading so not very efficient for large "graphs" of data/dependencies. In those cases you could decide to skip the DTO layer and directly access the domain model.

The Maven plugin IAM in Eclipse can be turned off for the Mod4J models project in Eclipse, otherwise it runs twice: once by Mod4J features, once by Maven (plugin).

Sunday, June 13, 2010

Carnegie Mellon University's CERT (Computer Emergency Response Team) has released the Basic Fuzzing Framework (BFF), which is a simplified version of automated dumb fuzzing and includes a Linux virtual machine that has been optimized for fuzz testing and a set of scripts to implement a software test. It helps identify and eliminate security vulnerabilities from software products.

"Nokia's set of learning and teaching materials on Java in Mobile Devices (JME/MIDP). In fact, it is Forum Nokia’s most comprehensive set of information ever. Included are five courses, 23 lectures, 25 lab exercises with source code, and more than 1,200 slides with notes. The material has been designed for university instructors and students, developers, and self-learners. Five main topics are covered:

Java ME basics

Multimedia

Networking and messaging

Games and graphics

Security

Of course JME is not so sexy as Android these days, but Nokia still has the largest number of mobile phones out there. And most (even quite low end) support JME, so from a market perspective the potential is much higher than building apps for Android phones...

Sunday, June 6, 2010

Google Web Toolkit vs. Smart GWT: Which should you choose as front-end? Start immediately with Smart GWT, or start with GWT and pick SGWT components when needed? Some insights here.Related to that, you might want to check Vaadin: "Vaadin is an open source web application framework for rich Internet applications. In contrast to Javascript libraries and browser-plugin based solutions it features a server-side architecture, which means that the majority of the logic runs on the servers. Ajax technology is used at the browser-side to ensure a rich and interactive user experience. On client-side Vaadin is built on top of and can be extended with Google Web Toolkit. Vaadin utilizes Google Web Toolkit for rendering the resulting web page. While Google Web Toolkit operates only client-side (i.e. a browser's JavaScript engine) – which could lead totrust issues – Vaadin adds server-side validation to all actions. This means that if the client data is tampered with, the server notices this and doesn't allow it.Historically, Vaadin has been compared to Echo and ZK frameworks that use similar of server-side programming model. The server-side APIs are quite similar providing both events and GUI components, but the client-side (i.e. web browser) interaction differs in the way that Vaadin uses Java programmed GWT widgets, while ZK is jQuery based, and Echo has its own implementation. Currently, the most frequently compared frameworks include Adobe Flex, Google Web Toolkit, Apache Wicket and ICEfaces."

A new open spec collaboration has started: OExchange, which is an open protocol for sharing any URL with any service on the web. Bigger parties involved are LinkedIn, Microsoft, Google.

Google announced a partnership with VMWare (and thus SpringSource and thus Spring) at I/O by adding its (GTW) widgets to Spring and deployment to the VMWare cloud. In marketing speak: "This is VMware and Google's view of the power of using Spring along with Google's presentation widgets to get apps started in hours, delivered in days, and deployed in minutes". Below it's shown in a diagram:

The iPad isn't without "errors" in its usability (UI) according to Jakob Nielsen. For example: cross-app UI experience is inconsistent, and for some reason almost no app supports scrolling and shows information only per page.

Show Slow: an open source tool that helps monitor various website performance metrics over time. It captures the results of YSlow and Page Speed rankings and graphs them, to help you understand how various changes to your site affect its performance

Sunday, May 23, 2010

Codelab ("tutorial") from Google that "shows how web application vulnerabilities can be exploited and how to defend against these attacks. The best way to learn things is by doing, so you'll get a chance to do some real penetration testing, actually exploiting a real application. The codelab is built around Jarlsberg, a small, cheesy web application that allows its users to publish snippets of text and store assorted files. "Unfortunately," Jarlsberg has multiple security bugs ranging from cross-site scripting and cross-site request forgery, to information disclosure, denial of service, and remote code execution. The goal of this codelab is to guide you through discovering some of these bugs and learning ways to fix them both in Jarlsberg and in general."

A new IBM Redbook on WebSphere Messaging and High Availability has just been released.

Oracle's ADF is starting to support mobile clients too with ADF Mobile Client. The technology preview for Blackberry is available now. Here's a tutorial PDF that shows how to develop a basic mobile browser application and a native app.

Tuesday, May 4, 2010

In the last two years I had to get my harddisk replaced twice by a new one.To minimize effort of setting up the new disk, I investigated which harddisk-copy program would best fit my needs, without complex setup things or complex instructions to create a bootable/live CD.

Creating a bootable live DVD was easiest with Clonezilla, and it's standalone, so no OS disks like Windows XP needed. The actual steps to make a backup a bit difficult for non-unix/linux people, but not impossible.Below are the steps I now use to make a complete backup of my harddisk (including Windows) to a networked external disk via Samba.Whether you can use these steps for your setup completely depends on your setup. Main reason for listing the steps here is so I have an easy reference to them :)

Prerequisites

Make sure you have an external harddisk connected to your network.

Make sure you have its IP address. If you're normally using DHCP, you might want to give it a fixed IP.

Make sure you have enough diskspace left on that external harddisk

To minimize network errors during the copying, you might want to use a network cable instead of a wireless connection. I definitely did that.

I used it for Windows XP, but any OS should do (it makes a byte-by-byte copy of the source disk

Steps to make copy

Put the bootable CD/DVD in the drive to boot from it. Choose F8 or F12 at startup if you manually need to select your machine to boot from it.

Wait until the boot sequence is done

Choose language, and Don't touch keymap

Choose Start Clonezilla

Now you have to get the network card to get activated. That happens in the next steps

Choose as Mount dir: samba_server

Choose eth0. Choose DHCP

Enter the IP of the networked external disk. E.g: 192.168.1.70

I canceled the Domain configuration option

Enter the account to use to connect to the networked external disk

Pay attention when you enter the directory where the image must be stored. It is the directory in which the directory with the image information will be put. If you enter a non-existing directory, the mount (happens when you hit OK) will fail. Not a problem, just that you know. If the mount fails, just restart the process, this time with an existing path. Example path:

/public/home/partimag

Hit OK. This will start the mount command. It will ask you for a password if applicable. When the command is successful, you'll see the filesystem mount points listed.

Choose Beginners Mode. Choose savedisk.

Enter a name for the image. I usually append some more identifying information to the prefilled filename, which is something like: 2010-05-02-18-img

Then choose the disk from the machine you want to make a backup for. For me it's only one: sda. Hit OK.

Hit ENTER. That should start the backup. No errors should occur. My 500G harddisk with about 100G of data took about 4,5 hours to get backed up. One time I had an error in the output, saying something like the eth0 NIC was "gone". But the backup continued, and no other official errors were shown. It was not clear whether Clonezilla recovered successfully from the connection being away for a little while. Still, to be on the safe side, I made another backup, that had no network errors at all.

Steps to restore copyThese steps are about the same as making the copy, except that you select restoredisk instead of savedisk. But for completeness, here are the steps:

Sunday, May 2, 2010

Google's Chief Java Architect Josh Bloch "discusses many of the problems facing the Java community, including the ineffectiveness of J2ME, licensing problems, Java 7's late ship date, and even the JCP issues that James Gosling often opined about. He points out that these problems predate the Oracle acquisition of Sun, so everyone should just stop pointing their fingers at Larry Ellison."

An article "which looks at various storage mechanisms - JDBC, JPA, JavaSpaces, Java Content Repository, MongoDB, and DB4O, primarily - from the perspective of how good they are at CRUD operations and queries". The conclusion is that there is no one "best" mechanism, each has its own best application.

Sunday, April 25, 2010

An introduction to Gizzard, an open sourced sharding framework (store data across multiple computers instead of on just one) which is used by Twitter.

A hands-on tutorial of creating a Spring application that uses Hibernate as JPA provider and JTA for transaction demarcation. A simple Order Processing Message Driven Bean is implemented that showcases this integration. It is deployed on a WebLogic 10.3 server.

Last week Jira from the Apache Foundation was compromised. Here's a description of how the hackers gained access via XSS.

John Resig on improving the Javascript in your web app. Video & full transcript, including new features now available in jQuery 1.4. Mentioned are: delegation, live events, html fragments, javascript from CDN, additional header in Ajax calls, custom events, special events, themeability and customizability, i18n, and IE6 support.

Sunday, April 11, 2010

Google recently released SkipFish, a free, open source, fully automated, active web application security reconnaissance tool/scanner. "It prepares an interactive sitemap for the targeted site by carrying out a recursive crawl and dictionary-based probes. The resulting map is then annotated with the output from a number of active (but hopefully non-disruptive) security checks. The final report generated by the tool is meant to serve as a foundation for professional web application security assessments."

Sunday, April 4, 2010

A short overview on what the differences are using Java in Google App Engine (and shortly mentioned in MS Azure) compared to "regular" JEE apps.

Three Java serialization options compared: Java Serialization, JSON Serialization and Google Protocol Buffers. Check also the comments here. Another benchmarking set can be found here.The protocol buffers solution was fastest in this test.

Interesting read on the IT infrastructure (most of the article) in F1 racing.Some quotes: "each car has roughly 100 sensors placed in key data capture positions and send anywhere up to 20 gigabyes of data back to the pits during a race.""They are collecting four to six megabytes per lap. It depends on the track layout and the quality of the coverage but we transfer about 70 per cent in real time to the garage or the pits". And, did you know there's a connection with the factory during the race?

Sunday, March 28, 2010

Whatever happened to programming? These days it is seems only glueing together a bunch of libraries... Where's the creativity? Well, I think you can now more and more focus on what your app can/should do, instead of re-inventing the wheel all the time. And if you have a real unique idea, you still will have to write those libs too :)

Sunday, March 21, 2010

Trying to get an overview of the possible combinations of Android SDKs and screensizes and resolutions, *and* what physical devices are comparable, I came to the below overview. If you know some more comparable hardware, please let me know, I'll update the tables.

Android has organized the screensizes and resolutions into three generalized sizes and three generalized densities, see here.

To support all these resolutions, you don't have to create icons/images for all possible combinations. By default Android tries to scale resources. Up to a certain limit it could be acceptable to let it do it for you, minimizing the number of images to create.

An example setting is minSdkVersion = 3, targetSdkVersion = 4 (where 3 = 1.5, 4 = 1.6). Targeting 1.6 ensures that different screensizes can be supported if the device has 1.6 or higher.

Cool skins you can find here. If you look at the configuration files, you can validate whether the screensize and resolutions are actually what you expect.

About Me

I'm a professional software designer/architect/developer with over 20 years of experience. For many years I've been a Technical Team Lead for complex ICT projects. My main area of focus is Java application architectures and related challenges (scalability, performance etcetera), but I'm interested in any software application architecture. Currently Android has got a lot of my attention. I will be posting lessons learned, and lessons that I'll be learning during the coming years :-)