AI OnAI Off
Ps. It only happens if the line in bold is included.
Type type = null;
if (Context.Repository.SchemaForType(typeof(NewContentItem)) == null)
{
type = typeof(NewContentItem);
EPiServer.Implementation.Serialization.TypeSchemaBuilder.RegisterSchemaAndType(type.ToString(), type);
}
if (Context.Repository.SchemaForType(typeof(List<NewContentItem>)) == null)
{
type = typeof(List<NewContentItem>);
EPiServer.Implementation.Serialization.TypeSchemaBuilder.RegisterSchemaAndType(type.ToString(), type);
}
Hi,
I've created a new workflow very similar to the ready for translation workflow. But as soon as the workflow is added to the web.config (even it is not link to any events) the cpu max out (w3wp takes all the processing power)
I've tracked it down to the following line in the code
EPiServer.Implementation.Serialization.TypeSchemaBuilder.RegisterSchemaAndType(type.ToString(), type);
As soon as this line is added, the cpu goes crazy but obviously without it, the workflow doesn't work.
Can't find schema System.Collections.Generic.List`1[Business.Workflows.NewContentItem] to deserialize against
Does anyone have any idea why this might be the case. The functionality of the workflow is fine, it is all doing what it is suppose to do except the cpu issue.