Error redirecting to nodes after upgrading Umbraco from 7.2.8 to 7.3.0
I have been using version 3.9 of the 301 URL Tracker on Umbraco 7.2.8 without any problems, but after upgrading to Umbraco 7.3.0 I am getting errors for any redirect (custom and automatically created) that are linking to a node instead of a hardcoded url.
I get the following exception:
********** 14-10-2015 10:19:58 **********
Exception Type: System.NullReferenceException
Exception: Object reference not set to an instance of an object.
Source: http://www.domain.dk/test
Referrer:
Stack Trace:
at Umbraco.Web.Routing.DefaultUrlProvider.GetUrl(UmbracoContext umbracoContext, Int32 id, Uri current, UrlProviderMode mode)
at Umbraco.Web.Routing.UrlProvider.<>c__DisplayClass3.<GetUrl>b__0(IUrlProvider provider)
at System.Linq.Enumerable.WhereSelectArrayIterator`2.MoveNext()
at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
at Umbraco.Web.Routing.UrlProvider.GetUrl(Int32 id, Uri current, UrlProviderMode mode)
at InfoCaster.Umbraco.UrlTracker.Helpers.UmbracoHelper.GetUrl(Int32 nodeId) in d:\kipusoep\Documents\GitHub\UrlTracker\Helpers\UmbracoHelper.cs:line 137
at InfoCaster.Umbraco.UrlTracker.Modules.UrlTrackerModule.LoadUrlTrackerMatchesFromDatabase(HttpRequest request, String urlWithoutQueryString, Boolean urlHasQueryString, String shortestUrl, Int32 rootNodeId, String& redirectUrl, Nullable`1& redirectHttpCode, Boolean& redirectPassThroughQueryString) in d:\kipusoep\Documents\GitHub\UrlTracker\Modules\UrlTrackerModule.cs:line 412
at InfoCaster.Umbraco.UrlTracker.Modules.UrlTrackerModule.UrlTrackerDo(String callingEventName, Boolean ignoreHttpStatusCode) in d:\kipusoep\Documents\GitHub\UrlTracker\Modules\UrlTrackerModule.cs:line 199
at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
Is there anything I can do to fix this, or perhaps a workaround?
However a new release hasn't been made yet and Stefan is on holiday for a few more weeks. For now you'll have to clone the github repo and build it to get a dll that works.
potentially affect the 7.1.8? I have installed 3.9 which contains these fix, and not sure if its related with it. Redirects are not working until Force Redirect is checked in 7.1.8 with 301 tracker version 3.9.
the redirects are working without requiring to check Force Redirect.
Without further insight, i suspect the 3.9 update of 301 tracker is breaking existing redirect functionality for pre 7.3 (again, only tested on 7.1.8, for now).
Not sure what else is changed but my previous redirect entries like
/oldpage.asp to /new-page-url
are not working anymore in 3.9, even with the above changes being reversed. Not sure if there is anything else related.
Would be interested to hear your thoughts on this.
Error redirecting to nodes after upgrading Umbraco from 7.2.8 to 7.3.0
I have been using version 3.9 of the 301 URL Tracker on Umbraco 7.2.8 without any problems, but after upgrading to Umbraco 7.3.0 I am getting errors for any redirect (custom and automatically created) that are linking to a node instead of a hardcoded url.
I get the following exception:
Is there anything I can do to fix this, or perhaps a workaround?
This has been fixed: https://github.com/kipusoep/UrlTracker/issues/90
However a new release hasn't been made yet and Stefan is on holiday for a few more weeks. For now you'll have to clone the github repo and build it to get a dll that works.
Sebastian, this has been fixed in UrlTracker? I'll get the latest code from there then. Thank you.
Yes, that's what I was linking to ;-)
Sebastiaan, do you think these changes at
https://github.com/nul800sebastiaan/UrlTracker/commit/78db283f19ff5bb832f5937507cc496bb4e842c6
potentially affect the 7.1.8? I have installed 3.9 which contains these fix, and not sure if its related with it. Redirects are not working until Force Redirect is checked in 7.1.8 with 301 tracker version 3.9.
Quick update, for pre 7.3 (tested on 7.1.8):
if i download the 3.9 sources and change those lines back ;
and
the redirects are working without requiring to check Force Redirect.
Without further insight, i suspect the 3.9 update of 301 tracker is breaking existing redirect functionality for pre 7.3 (again, only tested on 7.1.8, for now).
Not sure what else is changed but my previous redirect entries like
are not working anymore in 3.9, even with the above changes being reversed. Not sure if there is anything else related.
Would be interested to hear your thoughts on this.
We are getting a similar error under these circumstances in a load balanced (new method) environment on 7.3.3:
Go to a non-existent page which should give a nice 404 page on a sub directory on the LB domain.
If the page is accessed directly on each of the web servers it's fine. If it's accessed in the root it's fine. e.g.
http://www.loadbalanced.com/xxx/page-does-not-exist - 404 page does not work http://www.loadbalanced.com/page-does-not-exist - 404 page works
http://www.web1.com/xxx/page-does-not-exist - 404 page works http://www.web2.com/xxx/page-does-not-exist - 404 page works http://www.web1.com/xxx/page-does-not-exist - 404 page works http://www.web2.com/xxx/page-does-not-exist - 404 page works
Umbraco.Web.Routing.DefaultUrlProvider.GetUrl(UmbracoContext umbracoContext, Int32 id, Uri current, UrlProviderMode mode) +260 Umbraco.Web.Routing.<>cDisplayClass3.0(IUrlProvider provider) +49 System.Linq.WhereSelectArrayIterator
2.MoveNext() +81 System.Linq.Enumerable.FirstOrDefault(IEnumerable
1 source, Func`2 predicate) +214 Umbraco.Web.Routing.UrlProvider.GetUrl(Int32 id, Uri current, UrlProviderMode mode) +235 umbraco.library.NiceUrl(Int32 nodeID) +72 InfoCaster.Umbraco.UrlTracker.Modules.UrlTrackerModule.UrlTrackerDo(String callingEventName, Boolean ignoreHttpStatusCode) in d:\kipusoep\Documents\GitHub\UrlTracker\Modules\UrlTrackerModule.cs:178 System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +91 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +164is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.