For months (years) now, I've been thinking of creating a small blog to share some less-common .NET development and DevOps problems I come across at work, and in particular those that are uncommon or have less-documented solutions. I figure I cant possibly be the only one coming across these problems - so why not share my solutions. Some of these probably belong in Stack Overflow, but then sometimes the question doesn't exist, and answering your own questions to comply with their guidelines seems awkward. So, what simpler micro-blogging platform than Github Gist? It seems fitting for a developer. So here goes!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
IMPORTANT: | |
To enable the persist operation, you need to add an AppSetting in your web.config file: | |
<add key="persistFormsOnChange" value="true" /> | |
This should only be set to true on the Admin/BackOffice server. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
You will need to get install these two nuget libraries: | |
WindowsAzure.Storage | |
CsvHelper | |
*/ | |
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; |
When working on our git repositories, this is the general workflow / branching strategy we follow:
-
Development happens on the master branch (this way new developers can start writing code as soon as they've clone the repository)
-
Long-running development on a features/feature_name branch and then merged into master
-
Work to be done by vendors happen on a vendors/vendor_name branch and merged into master after being checked over (use pull requests).
-
Merge master into deploy/production or deploy/qa to trigger the respective deployment in the CI/CD tool.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// EpiServer implementation of an ImageProcessor IImageService - provides the episerver image blobs to ImageProcessor for resizing etc. | |
/// </summary> | |
public class EpiServerImageService : IImageService | |
{ | |
/// <summary> | |
/// Gets or sets the prefix for the given implementation. | |
/// <remarks> | |
/// This value is used as a prefix for any image requests that should use this service. | |
/// </remarks> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Add a required star (*) to fields marked as required */ | |
.Sleek .epi-form-container__section__row label span.edit-required { | |
font-weight: bold; | |
color: red; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log("1"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log("1"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.ServiceModel; | |
using System.ServiceModel.Activation; | |
namespace Web.IndexingService | |
{ | |
/// <summary> | |
/// Replacing the logic found in the IndexingService.svc to try and address a bug at where the run-time compiled assembly has a file-change causing the | |
/// App Domain to shutdown/restart. In some cases the shutdown failed, resulting in two AppDomains to be running. More details here: | |
/// https://world.episerver.com/forum/developer-forum/Problems-and-bugs/Thread-Container/2019/8/application-restart-loop-because-of-buildresult-change-cache-keycindexingservice-svc-1f180bcd/ |
OlderNewer