ThreadAbortException and long running scheduled jobs

We were experiencing some weirdness, seemingly random thread death of long-running scheduled jobs and background worker threads, in our development environments. This was bad.

Looking through the IIS event log I found

A worker process with process id of ’7156′ serving application pool ‘dev.pool’ was shutdown due to inactivity. Application Pool timeout configuration was set to 20 minutes. A new worker process will be started when needed.

What was happening was that because we were waiting for the background tasks to complete the worker idle timeout was being exceeded, as it defaults to 20 minutes, and there was no site activity. [No requests! Though the background process was doing some work.]

The way to fix this is simple. We kill the Batman. Ahem, I mean, we disable the worker process idle timeout. As the app pool was set to recycle at a set time there should be no reason to recycle due to ‘idleness’. [On the prod environments, with their various monitoring apps, it would never happen. But on our QA machine and dev machines this was an issue for testing these kinds of long running jobs]

In IIS go to the app pool that you are using for EPiServer CMS and click the Advanced Settings link. Then scroll to Process Model and set Idle Time-out (minutes) to 0.
This will ensure that in your testing environments it never times out.

EPiServer Commerce and using the CartHelper class

During development of an EPiServer Commerce 1R3 based ecommerce platform we encountered a strange problem.

If the end-user decided to leave the checkout flow and return, the taxes and shipping costs doubled, then tripled, then … you can see where this is going.
Of course, the client was not happy with my suggestion that it increases revenue so I looked into what was happening.
Continue reading

I am still going to Japan on vacation

Torii at sunset

This is curenty a relatively bold thing to say.

As tempus is want to fugit it is likely this post will lose both its impact and meaning very quickly.

Japan has suffered its biggest earthquake ever. It triggered a huge Tsunami that wrecked even more damage, death and destruction.
Currently over 10,000 are dead and further 10,000 are missing.
It is a horrible tragedy.

And on top of this there has been an accident at a nuclear facility north of Tokyo that has pumped radioactive Iodine into the environment.

So why on earth would I still be going to Japan on vacation?
Continue reading

5 simple tips to staying a little safer online

The Web
The web has been likened to the wild west, a lawless and truly anarchistic place.
But most of the problems people encounter online are caused mostly by their own behaviour and attitude rather than any inherent nastiness of the technology.
Widespread digital iliteracy leads many to think they are safe when they are not and to fear things that are totally innocuous.

Below are 5 simple tips to help you stay a little safer online;
Continue reading

General rants and observations of an Amsterdam based web technologist


Get every new post delivered to your Inbox.

Join 159 other followers