• How to (re)schedule an alarm after an App upgrade in Android

    In one of my Apps I am using alarms to schedule notifications. Of course I also want to (re)schedule the alarm when the device is rebooted. Easy: Just set a BOOT_COMPLETED action in the intent-filter of the according schedule reciever: The problem now just is that when the app is upgraded, your alarm will not be…

  • Java 8 Streams: Collecting items into a Map of (Key, Item)

    Once in a while I come across the task where I have a list of Items that I want to filter and afterwards store in a map. Usually the key is a property of the Item: anItem.name -> anItem In the usual Java way this looked like the following: Nothing really special, but it somehow…

  • How to rename a GIT tag

    Once in a while (yet often enough) it happens that I have to change an already pushed git tag. Usually because I violated my own naming scheme. Yet I also somehow can’t keep the necesserry commands in mind: Basically it is just: copy/link newTag to oldTag, remove oldTag, delete remote oldTag. Also see the git…

  • Windows Tomcat start failed command 127.0.0.1 could not be found

    I just installed Tomcat 7 on my Windows machine and tried to fire it up through Netbeans. But instead of a running server, I just got an error message that command 127.0.0.1 could not be found (Localized error message: Der Befehl “127.0.0.1” ist entweder falsch geschrieben oder konnte nicht gefunden werden.). I remember that I…

  • Epson XP-205 Scanner in Windows 8.1 – How to get it back to work

    Now it’s time for a Epson XP-205 Scanner to work with Windows 8.1 It took me a while now to get the XP-205 scanner component to run on my new Windows 8.1 via WiFi: The problem is, that when you install the scan software, you might get a communication error telling you that the scanner…

  • How to fix Twitter share button in WordPress’ Huge-IT Share buttons

    I just tried the Huge-IT share plugin for wordpress and realized that the twitter share button seems to have a bug: When sharing, the tweet will not link back to the URL. Not cool :-/ Fix: changed the file (via edit plugin): wp-share-buttons/Front_end/share_front_end_view.php Now the URL is prepended with http and thus displayed in the…

  • Check internet connectivity in Android

    When programming an Android App you sometimes want to check, if you are connected to the Internet. The first thing that comes to mind is using the ConenctivityManager. Yet this solution has the problem that it only tells you that you are connected to .. something. With a WiFi connection this can mean, that you…

  • Scalding hiding NPEs in “operator Each failed executing operation”

    Yesterday I was surprised by a failing Scalding task. Everything worked fine locally and all I git was like “job failed, see cluster log”. In the cluster log I saw the following: 2014-10-24 14:38:41,222 INFO org.apache.hadoop.mapred.TaskInProgress: Error from attempt_201410101555_2230_m_000005_3: cascading.pipe.OperatorException: [com.twitter.scalding.T…][com.twitter.scalding.RichPipe.each(RichPipe.scala:471)] operator Each failed executing operation at cascading.flow.stream.FunctionEachStage.receive(FunctionEachStage.java:107) at cascading.flow.stream.FunctionEachStage.receive(FunctionEachStage.java:39) at cascading.flow.stream.FunctionEachStage$1.collect(FunctionEachStage.java:80) at cascading.tuple.TupleEntryCollector.safeCollect(TupleEntryCollector.java:145) at…

  • Enable output compression in Scalding

    I just wanted to enable final output compression in one of my Scalding jobs (because I needed to reorganize a some-TB-data set). Unfortunately scalding always produced uncompressed files. After some googling, I came across a github issue that adressed exactly this problem. Via some links I got the sample code from this repo which can…

  • Scalding Exception: diverging implicit expansion for type com.twitter.algebird.Semigroup[T]

    I was just doing a again some scalding jobs and again got an .. interesting exception: In a groupBy operation, I wanted to sum something up using: And was rewarded with this one: WTF?? Solution: Spot the mistake? It’s the missing type hint at sum: