Hi,
a few hours ago, I stopped my EventStore instance (to replicate environment locally, but thats not important). Since then, my application misbehaved which I could narrow down to my one EventStore projection.
It seems to be in “Starting” status for hours and I can’t seem to find a way to fix that, restarting EventStore again doesn’t solve it.
The ES log shows the following:
» 15:42:27.961 [PID:00652:017 2014.07.18 13:41:53.088 ERROR ProjectionManager ] The ‘per-context’ projection faulted due to 'Cannot create a projection state handler.
» 15:42:27.961
» 15:42:27.961 Handler type: JS
» 15:42:27.961 Query:
» 15:42:27.961
» 15:42:27.961 options({});fromAll() .when({$any: function (s, e) { if(e.metadata && e.metadata.AssociatedBoundedContext) {linkTo(“context-”+e.metadata.AssociatedBoundedContext, e);}}})
» 15:42:27.961
» 15:42:27.961 Message:
» 15:42:27.961
» 15:42:27.961 Failed to compile script. Terminated?’
» 15:42:27.968 EventStore.Projections.Core.v8.Js1Exception: Failed to compile script. Terminated?
» 15:42:27.968 at EventStore.Projections.Core.v8.CompiledScript.CheckResult(IntPtr scriptHandle, Boolean terminated, Boolean disposeScriptOnException) in c:\BuildAgent1\work\oss\windows\releasebuilds\src\EventStore\EventStore.Projections.Core\v8\CompiledScript.cs:line 78
» 15:42:27.968 at EventStore.Projections.Core.v8.PreludeScript…ctor(String script, String fileName, Func
2 getModuleSourceAndFileName, Action
2 cancelCallbackFactory, Action`1 logger) in c:\BuildAgent1\work\oss\windows\releasebuilds\src\EventStore\EventStore.Projections.Core\v8\PreludeScript.cs:line 69
» 15:42:27.968 at EventStore.Projections.Core.Services.v8.V8ProjectionStateHandler…ctor(String preludeName, String querySource, Func
2 getModuleSource, Action
1 logger, Action`2 cancelCallbackFactory) in c:\BuildAgent1\work\oss\windows\releasebuilds\src\EventStore\EventStore.Projections.Core\Services\v8\V8ProjectionStateHandler.cs:line 54
» 15:42:27.968 at EventStore.Projections.Core.Services.Management.ProjectionStateHandlerFactory.Create(String factoryType, String source, Action
2 cancelCallbackFactory, Action
1 logger) in c:\BuildAgent1\work\oss\windows\releasebuilds\src\EventStore\EventStore.Projections.Core\Services\Management\ProjectionStateHandlerFactory.cs:line 75
» 15:42:27.968 at EventStore.Projections.Core.Services.Management.ManagedProjection.<>c__DisplayClass42.b__41() in c:\BuildAgent1\work\oss\windows\releasebuilds\src\EventStore\EventStore.Projections.Core\Services\Management\ManagedProjection.cs:line 741
The projection code is trivial, just linking all events of a bounded context to a combined stream, nothing fancy, and worked fine for months now.
The current data is not that important, so I could reset my EventStore, but I’d rather fix it than just ignore it if it happens again.
Is there a way to fix this projection?
Regards,
Nicolas