Posted on October 11th, 2008 by Reiner.
Categories: Grails, English, Computers.
Never before in my life I had the opportunity to learn a new technology and put it into productive use within just a couple of days. Grailswill changeis changing the Java and framework landscape right now. Using Grails, within less than 3 weeks, an application has been developed that accepts NFC-scans from mobile devices (i.e. Nokia 6131 NFC), sends notifications by email and by SMS, and renders a live view of scans as well. None of the staff involved had any previous experience with Grails whatsoever (I started implementing the domain classes and services, a colleague of mine then took over to implement the GUI while I was on vacation on the Canary Islands). Our work was targeted towards NetBeans, GlassFish and PostgreSQL.
Listed here are the links that helped us jump on the track to wealth, glory and wisdom
Pet stores, sort of:
The web service side:
Still more advanced:
Slightly off topic:
Tiddlers:
Deutsche Ecke (German corner, don’t hold your breath yet):
Posted on September 4th, 2008 by Reiner.
Categories: English, at other Locations, Computers.
In Germany there is a saying “Don’t praise the day before dusk”.
Two days after having published my praise for Yoigo here, they may have uncovered my “excessive” service usage. The bright coach has now turned into a dull pumpkin: Gone are the the 80 MB for EUR 1.20. Instead, soon after having reached the first Megabyte (and having paid EUR 1.20), my connection is now slowed down to 8 kBit/s, making it next to impossible to use the data service at all (e.g. Google Mail complaining about broken network, downloading a 375kB PDF taking more than 5 minutes).1 MB per day at decent download speeds for EUR 1.20 no longer looks as if it were a bargain.
The main problem is, that there’s no reliable information on precise traffic amounts and conditions. This even applies to the status SMS you’ll receive after each session. It just states how much you paid for the session (0.000 Euros after having used up the first megabyte of traffic) but does not indicate your actual traffic usage. For my Nokia E90, 1 MB is next-to-nothing (e.g. opening Adobe’s home page just twice).
So I reverted to Vodafone and bought me a Vodafone prepaid SIM at a local Vodafone outlet, added an additional charge of EUR 60 and spent it on a month of “unlimited” Internet access. Of course, even with Vodafone, “unlimited” has certain - and in this case well documented - limits: Your first Gigabyte will fly in at maximum network speeds - up to several MBits/s (provided both, the mobile network station and your device support UMTS third genaration standards). Any excess traffic will be slowed down to 128 kBits/s. That’s still not too bad at all. Provided you’ll use up your Gigabyte, you’ll pay 6 Eurocents / Megabyte of traffic. A great value in my opinion with the added benefit of cost transparency. Vodofone as well offers other data packages, e.g. 1 GB of traffic without set time periods (but of cource nothing left, once your package has been used up).
A word of caution: Don’t even think of browsing without buying a data package first: You would end up paying 2 Euros for each Megabyte of traffic from your prepaid balance.
Being a computer nerd on a tight budget and spending a vacation on the Canary Islands, I chose to get a Yoigo Prepaid Mobile Card in order to avoid excessive roaming costs.
Yoigo offers excellent coverage, using Vodafone (including Vodafone’s UMTS coverage) to fill in their network gaps. Rates are quite competitive, about 14 Euro Cents per minute for domestic calls.
There’s a hidden secret in their offering though: Yoigo won’t charge you more than 1.20 Euros per day for Internet access. If you have a state-of-the art Nokia mobile and want to browse from your notebook, tha fastest way to gain Internet access is to enter “internet” within your mobile’s packet access point settings, enable infrared on both your mobile and your XP/Vista notebook and use *99# for the dial-in number.
However, precise conditions of use are not being divulged to customers, so it took a couple of sessions to find out what you’ll get for your money: 1.20 Euros will buy you up to 80 MBytes at download speeds of 384 kBit/s (using UMTS coverage), your daily allowance being renewed at exactly midnight “Peninsula” time. Any excess traffic will be crippled down to about 16 8 kBit/s, eventually coming to a complete halt at about 100 MBytes (mobile unit forcibly removed from the network and unable to reconnect for a couple of minutes). It appears as though once you try to use anything near 80 MB/day, your daily allowance will be reset to just 1 MB (before your connection will be slowed down to 8 kBit/s). See Update above.
All in all, if you’re looking for a mobile provider in Spain who offers reasonable rates, and provided your mobile Internet traffic averages around 40 MB/day (perfect for email and browsing, but inadequate for uploading YouTubes), right now Yoigo may be your best bet. They sport several tariffs, e.g. one that has a monthly minimum of about 6 Euros and has lower call charges, and another one that has no monthly minimum, but incurrs slightly higher call charges. On the Canary Islands, you’ll find Yoigo at local Post Offices (services not offered by Correos themselves, but by privately owned enterprises that operate within the vicinities of Los Correos). If you need more (prepaid) traffic, you may want to take advantage of one of Vodafone’s offerings (e.g. 1 month of unlimited Internet access for 60 Euros - traffic beyound the first GB slowed down to 128 kBit/s).
Disclaimer: The information provided in this post is based on personal experience and given as is. No warranty of any kind regarding its fitness of correctness can be given. Stay googled to keep informed ![]()
Posted on August 20th, 2008 by Reiner.
Categories: Grails, English.
Grails injects a log object for each artifact, but these loggers are not accessible within static methods.
Here’s a quick-and-dirty code snippet sample that demonstrates how to log from a static method within domain class Account. The trick is to get the Logger by invoking org.apache.commons.logging.LogFactory.getLog(this):
import org.apache.commons.logging.LogFactory
static Account createOrFindByImei(String imei)
{
Account result = Account.findByImei(imei)
return result ? result :
saved(new Account(
imei:imei,
email:Login.getCurrentLogin().email,
name:"* New Account ($imei) created at " + new Date()))
}
private static Account saved(Account account)
{
if(account.save())
{
return account
}
LogFactory.getLog(this)
.error("!saved: $account.errors", new Throwable("*STACKTRACE*"))
}
Posted on August 14th, 2008 by Reiner.
Categories: English, Computers.
Half an hour ago I wanted to chat with a colleague of mine. I’m not that much into chatting, but into moving all and everything to Google Apps, so I’m on Google Talk (on my mobile as well), but my colleague is registered with Skype and MSN.
Bad luck, maybe hours of installation work ahead (I’m using a Thin Client which normally reverts to its clean boot settings on each power-up - keeping out stray viruses), tedious efforts to bar SuperChat applications from damaging the VOIP client built into my Nokia E90, forgotten passwords and other chores ahead
For immediate anonymous chats, there’s a quick solution: Just add Google Chatback to your website. Chats are anonymous, but they’re not public, i.e. I’ll receive a separate window for each user. So they’re quite safe, unless someone successfully pretends to be my daughter, inquiring about my credit card details.
This one uses iframes, but the badge comes in customizable flavors that don’t require iframes. Provided your mailer program sends html you can even include the chatback badge in your mails. Sadly enough, Google Mail does not allow html in your signature, so you’d have to cut-and-paste each time again.
![]()
Posted on July 3rd, 2008 by Reiner.
Categories: Deutsch, ThisNThat, La Palma.
Nicht schlecht gestaunt - ein Freund bucht fuer mich bei Air Berlin gerade Urlaubsfluege nach La Palma (Kanarische Inseln, Spanien) und fragt mich inquisitorisch nach den Daten meines Personalausweises, die bei der Buchung auf Grund des Advance Passenger Information Systems erhoben werden.
Es hat den Anschein, als seien neben den USA inzwischen auch viele weitere Staaten verkrakt, wie z.B. die Volksrepublik China oder hier Spanien. Also: Keep your ID cards ready!!!!
Posted on May 4th, 2008 by Reiner.
Categories: English, Computers.
I’d like to present a free solution for Windows XP that reliably records incoming and outgoing SIP phone calls. I’m currently using it to record traditional conference calls for a team of software developers.
By default, Oreka will produce .WAV-files using GSM compression. GSM is widely used for mobile phones, thus files are very small (about 100kBytes/minute), but sound quality is a little bit on the dull side and older applications might fail to understand GSM encoding. If space is of lesser concern, I’d recommend the plain old uncompressed pcmwav format (about 1MByte/minute) that can be read by virtually any program, or the ulaw (best in USA + Japan) or alaw (best in Europe and for international calls) encodings (about 500kBytes/minute) that are commonly used for SIP voice data and can be read by most programs.
With Oreka, audio file storage format can be set up within Oreka’s config.xml (Caution: do not choose native):
<!– Audio file storage format: choose from: native, gsm, ulaw, alaw, pcmwav –>
<StorageAudioFormat>pcmwav</StorageAudioFormat>
When publishing recordings, I’d suggest to produce .mp3-files. Oreka can’t do this on its own (at least the free version). I’m using WavePad to do the job: Drag your .wav file to WavePad, then click Effects, Dynamic Wave Compressor…, Threshold -24dB, Ratio 5:1, Limit 4dB, OK, then Save File As…, MP3, Constant Bitrate, 16kbps, Mono. You’ll end up with tiny files whose quality is superior to the one produced by commercial conference recording systems.
When using an external SIP phone (my favorite is the Thomson Speedtouch ST2030), for Oreka to successfully record your phone calls, it is required that Oreka “hears” all the data being sent from and to your SIP phone. That’s quite easy when using a soft phone on the very same PC that Oreka is running on, but will be more complicated when using an external hardware SIP phone. Current computer network equipment uses network switches to interconnect devices. Switches are smart. They know how to direct network data packets, so that reach their intended receivers - and only those. Let’s assume you’ve connected three devices to your switch (the switch itself possibly having been integrated within your DSL router):
Now, when you place a phone call, your switch will forward voice data from the internet to your phone (and vice versa). Your PC however will not receive any data sent from or received by your phone, effectively deafening Oreka. Although Oreka has instructed the network card within your PC to listen for any traffic (including the traffic that’s not destined for your PC), you won’t be able to record any phone call at all.
So are we stuck yet? Depends. If you are using a VOIP-DSL router where you have plugged your analog phone(s) into, the answer is yes. Read no further. Either look for conferencing services (e.g. Basement Ventures Free Conference Call Services) or analog taps that go in between the cable from your phone and to its handset (e.g. the Radio Shack Mini Recorder Model 43-1237 or the JK Audio THAT-1). However, if you are using a VOIP phone (one that uses Ethernet and does the SIP itself), you’ll get away by replacing your switch with a hub.
Provided you are using a SIP VOIP phone, you’ll either need a switch that features port mirroring (quite expensive) or a network hub, which forwards any data received on one of its ports to all other ports. As far as I know, hubs are no longer being manufactured at all, so you’ll either have to snatch one from a museum or get a used one from eBay. I’ve successfully tested the Netgear FE 10x and DS 10x hubs, both readily available and very inexpensive.
Tom Keating’s article VoIP Call Recording within his VoIP & Gadgets Blog has provided a plethora of invaluable information and thus served as an ideal starting point - a must have!
Posted on March 16th, 2008 by Reiner.
Categories: Deutsch, ThisNThat, Uncategorized.
![]()
Ein Artikel ohne Bilder ist wie ein Redner ohne Stimme - langweilig bis lästig.
Aber woher nehmen und nicht stehlen?
Über 3 Millionen legale Bilder zu bezahlbaren Preisen gibt es z.B. von http://www.fotolia.com/. In dieser (kleinsten) Auflösung (z.B. 412×292) für nur ca. 0,83€ (wenn man über http://us.fotolia.com/ in USD bezahlt).
Posted on March 15th, 2008 by Reiner.
Categories: Deutsch, Computers.
English article at Bad Habits Die Hard - How to Prepare Java Apps for Full Speed Debugging.
Beim Instrumentieren einer Java Anwendung für (auch Remote) Debugging werden oftmals VM-Parameter verwendet, die die Anwendung spürbar verlangsamen, da sie den Just-In-Time Compiler der Java VM ausschalten, z.B.:
-Xdebug
-Xnoagent
-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n
-Djava.compiler=NONE
Ab Java 1.4 ist es weder erforderlich noch per se ratsam, den Java Just-In-Time Compiler auszuschalten.
Die Anweisung -Djava.compiler=NONE sollte einfach entfallen:
-Xdebug
-Xnoagent
-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n
So kann eine Anwendung für das Debuggen vorbereitet werden, ohne dass ihre Performance darunter leidet, solange sie nicht aktiv debugged wird. Und selbst während des Debuggens wird die Anwendung durch den Just-in-Time Compiler beschleunigt. Dies ist in Test- (oder sogar Produktions-) Umgebungen sehr willkommen, die sowohl performant ausgeführt werden sollen, als auch eine bei Bedarf zu öffnenende Hintertür enthalten sollen, durch die Probleme untersucht werden können.
Sogar in aktuellen Posts wird das -Djava.compiler=NONE Antipattern verbreitet, wie z.B. bei ImageJ Plugins in Eclipse entwickeln.
Und das böse -Djava.compiler=NONE versteckt sich nicht nur in vielen Konfigurationsdateien und Werkzeugen, sondern hat es sogar geschafft, bis in Java 6 selbst vorzudringen. Siehe -Djava.compiler=NONE and -Xdebug anachronisms unanachronistically disable full-speed debugging in Suns Bug Database.
Posted on March 15th, 2008 by Reiner.
Categories: English, Computers.
Deutsche Fassung bei Debuggen von Java Anwendungen - auf der Überholspur!
When instrumenting your Java application for remote debugging, a commonly used set of VM parameters brings your application to a crawl, as it disables just-in-time compiliation and enforces interpeter-only mode, e.g.:
-Xdebug
-Xnoagent
-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n
-Djava.compiler=NONE
Starting with Java 1.4, it is neither required nor advisable to disable the Java just-in-time compiler,
so just remove the -Djava.compiler=NONE:
-Xdebug
-Xnoagent
-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n
Thus, you are able to prepare your application (e.g. JBoss) for debugging, and there will be no perceivable overhead unless you actually connect your debugger to the debuggee (using remote debugging). And even while debugging, the Java just-in-time compiler will speed up your application. That may be handy for test (or even production) environments that are supposed to both deliver full speed and still supply a back door for debugging once the need arises.
Even recent posts still promote the -Djava.compiler=NONE antipattern, as in See how maven works inside - remote debugging plugins or Debugging your Maven Project in Eclipse.
And the bad -Djava.compiler=NONE habit may still be hidden within numerous configuration files or tools, as it even made its way into Sun’s Java 6 itself. See -Djava.compiler=NONE and -Xdebug anachronisms unanachronistically disable full-speed debugging at Sun’s Bug Database.
Posted on March 15th, 2008 by Reiner.
Categories: English, at Home, Computers.
The Acoustic Energy WIFI Internet Radio
The AE 100 was one of the first devices that, in a stand-alone unit, receives radio broadcasts from all around the world using Reciva technology and firmware.
AE 100 users are well aware of a common pitfall of this unit. When the volume is low your listening experience is impaired by frequent crackling noises.
Where do those crackling sounds come from?
Inside the AE 100 there is a WIFI USB stick, that implements the connection to your wireless LAN. The RF energy of its transmitter leaks into the wires which connect the loadspeakers to the analog amplifier circuit, where it is rectified and causes transmission packets to be heard. Well, it’s not a Sony
How to avoid them?
There are some work-arounds for this bug, notably the one provided at AE 100 crackle problem : yet another fix. Philippe gives detailed instructions on how to dismantle the unit and how to shield the loadspeaker wires using shielding foil from STP computer cabling.
My no materials approach: Just twist them wires
Losely following Philippe’s instructions (I put the unit flat on its side, so I would not need three hands to handle the housing parts), I opened the case and unplugged the loudspeaker wires. Then I twisted them gently, so that they looked similar to the ones found in UTP cabling. I then reconnected the wires and reassembled the unit, trying to put as much of the wires near the loadspeakers as possible.
Less noise in almost no time at all
The crackles can still be heard with the volume set to 1 bar and your ear next to the front grid, but they are no longer perceivable at all during normal use
The actual noise level may be more or less random depending on the position the wires will take when closing the unit.

