Søren Kruse | Sitecore and .NET

Søren Kruse's picture

Søren Kruse

Sitecore developer with an interest in the more advanced stuff and elegant solutions to complex problems.

  1. Sitecore release notes made searchable!

    If you're like me you've probably (more than once) had to read/search through several pages of release notes to find out if the issue you are currently having (or a bug you have reported earlier) has been fixed in any of the latest Sitecore releases. Well, at some point…

  2. Sitecore 9 with Solr and SQL Server running in Docker

    With Solr now being the default and recommended search provider in Sitecore 9 for all setups except XM1 (and required for xConnect) I wanted to look at how to run Solr with Docker. My requirements/reasons for wanting to run Solr in a Docker container: Not having to install Java…

  3. MongoDB, C# and DateTimeOffset

    The MongoDB driver for C#/.NET can currently be serialized/deserialized in three different ways - as an array, object or string. You can control the BSON representation of your property by adding the [BsonRepresentation] attribute or set it on your class map. [BsonRepresentation(BsonType.String)] public DateTimeOffset EventStart { get;…

  4. Octopus C# script step not finishing unawaited async Tasks

    You might find yourself wanting to start an async Task either through Task.Run(() => ...) or something like Task DoSomethingAsync() or Task.Delay() where you don't want to await the completion of the task. You just want the step to complete and the task to continue running in the background.…

  5. ErgastApiClient - C# library for querying the Ergast Developer API (Formula 1 data)

    The Ergast Developer API (http://ergast.com/mrd/) is an awesome (experimental) web service which provides a historical record of Formula 1 data for non-commercial purposes. The API contains data all the back to the beginning in 1950. Some time ago I wanted to query some of this data and…

  6. Octopus Script Step Error: "Common Language Runtime detected an invalid program"

    You might run into the following error when deploying with Octopus and one of your tasks is executing a C# script (ScriptCS) on the target machine. ERROR: Script execution failed. [InvalidProgramException] Common Language Runtime detected an invalid program. Exit code: 1 The remote script failed with exit code 1 This…