12 Nov 2011

IE6 & Google Chrome Frame

IE6 is still an annoying part of a developers life. A workaround for this problem is Google Chrome Frame. html5boilerplate.com has updated to version 2.0 recently including support for Chrome Frame. Even better, html5boilerplate.com prompt IE 6 users to install Chrome Frame. It's a showcase how to migrate the user seamlessly without administrator privileges.

Now imagine that you have a set of Internet Explorer 6 machines and it was possible to deploy Google Chrome Frame to render everything by default except a few intranet sites that work only with IE6, what would you get?

  • The enhanced security of sandboxed renderer, sandboxed flash/PDF, effectively replacing IE with Google Chrome’s rendering engine whilst browsing the wild, wild Internet.
  • Legacy compatibility of Internet Explorer whilst accessing intranet sites.
  • Industry-leading response rate for high and critical risk reported vulnerabilities.
  • Google Chrome’s auto update strategy that is speedy and easy to administer.

Interested? Check it out!

 

8 Jul 2011

"warning: regexp match /.../n against to UTF-8 string" when running Cucumber

You probably have updated your environment lately and now getting the error "warning: regexp match /.../n against to UTF-8 string" when running Cucumber.

This is an encoding problem in the rack gem. This problem has already been fixed in version 1.3.0 but some of us are not able to update due dependencies issues e.g. rails. A simple monkey-patch based on pull request can solve the issue.

Create the file "config/initializers/rack_hotfix.rb" with the following content:

6 Jul 2011

Run Cucumber with Selenium RC and a custom Firefox profile

Proxy, proxy, proxy ... My head is spinning and it took me quite a while to figure out how to get Firefox and Selenium working behind a proxy. Guess what, it's quite simple.

Global environment configuration

First i tried the unix environment variable http_proxy and no_proxy but it seems Firefox doesn't respect those (Issue, Addon).

Use a firefox profile

Second i tried to create a Firefox profile with the correct proxy settings and started Selenium RC with the parameter "webdriver.firefox.profile" and the name of the created profile. The problem here is that the Selenium Webdriver for Ruby always creates an anonymous profile for Firefox.

I've created an issue for that.

The workaround

At the moment Selenium RC and the tests for our Ruby on Rails project are running on the same machine and the Selenium configuration for Capybara is flexible enough to apply a workaround for our problem.

Open features/support/env.rb in your Ruby on Rails project and add the following:

This snippet will configure Capybara based on the Firefox profile "default" but you could use any profile you want. The environment variable SELENIUM_REMOTE ensures that this configuration will not apply for any of your team members.

You can enable the configuration by running cucumber like this: SELENIUM_REMOTE=1 bundle exec cucumber

1 Jul 2011

Headless Testing for Continuous Integration with Ruby and Selenium

A headless system is a computer system or device that has been configured to operate without a monitor (the missing "head"), keyboard and mouse.

This is something you probably want when you're running a continuous integration server and having a bunch of integration tests for your website / application.

Using Firefox on Debian

Web Links

16 Dec 2010

Disable VMware Fusion's vmnet-* daemons on Mac OS X

VMware Fusion initializes some daemons (vmnet-bridge, vmnet-dhcpd, vmnet-netifup, vmnet-natd) at startup. The number of processes depends on the number of network interfaces you have configured. This might slow down your system startup.

Why is it necessary for them to load at system startup rather than application startup?

You need administrator privileges to load kernel extensions (which really makes sense), and these really do need to be kernel extensions (running a virtual machine at acceptable speed requires low-level access), so rather than prompting users for this when they start Fusion (and remember, they might not even know/have the password), we have the kexts get loaded at boot time. Advanced users can certainly disable this and manually start the services when needed.

Source

Here is an example how it could look like:

I don't use VMware Fusion often and want the daemons only to start up if it's necessary. The script to initialize the daemons is located at /Library/Application Support/VMware Fusion/boot.sh and is invoked by the LaunchDaemon script which is located at /Library/LaunchDaemons/com.vmware.launchd.vmware.plist.

  1. deactivate the LaunchDaemon script: "sudo launchctl unload -w /Library/LaunchDaemons/com.vmware.launchd.vmware.plist"
  2. use an apple script to start the boot.sh-script and VMware Fusion:

Here is a short how-to to get the script runnning:

(download)

21 Nov 2010

My first Mac OS X project

I have some projects for Mac OS X in mind where I still have not found anything suitable on the web. Most of this projects are tools for developers/administrators as myself to simplify life. A couple of days ago I started to work on one of this projects and over the next weeks I want to share some of the experiences.

Development

Tutorials:

Libraries:

Maintenance

Distribution

How to sell your product, secure it against crackers, handle license keys, etc.?

17 Nov 2010

Doctrine - Versionable behavior configuration for use in symfony

If you use doctrine's Versionable behavior you might notice some performance issues, especially if you use a large number of models. The behavior generates a second model for each model. This second model represents the history log. It happens on demand and in memory for each request. The lazy generation can be turned off by option generateFiles: true. The generated model is then written to the location specified by generatePath.

Everything is fine except you're using symfony. The generated models are not extended from sfDoctrineRecord and written to another directory because of the default configuration of Doctrine_Import_Builder inside of Doctrine_AuditLog. It took me a while to figure out how to configure doctrine's Versionable behavior for symfony's directory structure.

Here is the result:  

3 Nov 2010

Eclipse PDT - Install hotfix for broken compare view

The current stable release has a broken compare view. This bug is annoying as you can not compare your changes. There is an unofficial fix available. 

(download)

25 Aug 2010

Reality

What is reality? Are you real, are the people around you real?

If you have some spare time I recommend those articles about theoretical and philosophical theories about our reality or what we call so ;-)

8 Aug 2010

fast as lightning - again

2010-08-06_1803

I have a lot of stuff on my Mac Book Pro. Especially for my
work i need a lot of applications and services running at the same
time, e.g. VMWare, MSSQL Server, PostgreSQL, MySQL, Apache, Eclipse,
Firefox, Safari, Xcode, and so on, not forgetting the applications
that make you feel comfortable at work like iTunes :-) . And because
it's a Mac, you'll never turn it off. I'm actually wondering why this
device has an on-off switch - probably it's just an on switch (just
kidding).

However, for a long time I was very excited how well everything
performs, but at some point you notice the latency gaps between a
click and the application response. Sooner or later, depending to your 
personal threshold of discomfort, you will decide to do something
against these latency issues.

I got 8GB RAM and guess what ... it's fast as lightning - again :)