Scheduled Tasks Error

Posted: August 12, 2019 at 2:41 PM Quote #243605
Hi,

Since upgrading to Nop 4.2, I'm having issues with scheduled tasks like email sending, currency update, etc. It is giving me a parameter expiration error, as pasted below in full.

Please someone assist.

Error
Short message  
The "Update currency exchange rates" scheduled task failed with the "Specified argument was out of the range of valid values.
Parameter name: expiration" error (Task type: "Nop.Services.Directory.UpdateExchangeRateTask, Nop.Services". Store name: "Muriash eCommerce Limited". Task run address: "https://www.muriash.com/scheduletask/runtask").
Full message  
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Parameter name: expiration
   at EasyCaching.Core.ArgumentCheck.NotNegativeOrZero(TimeSpan argument, String argumentName)
   at EasyCaching.InMemory.DefaultInMemoryCachingProvider.BaseSet[T](String cacheKey, T cacheValue, TimeSpan expiration)
   at EasyCaching.Core.EasyCachingAbstractProvider.Set[T](String cacheKey, T cacheValue, TimeSpan expiration)
   at Nop.Core.Caching.MemoryCacheManager.PerformActionWithLock(String key, TimeSpan expirationTime, Action action) in C:\andrei\nopcommerce\sources\src\Libraries\Nop.Core\Caching\MemoryCacheManager.cs:line 105
   at Nop.Services.Tasks.Task.Execute(Boolean throwException, Boolean ensureRunOncePerPeriod) in C:\andrei\nopcommerce\sources\src\Libraries\Nop.Services\Tasks\Task.cs:line 143
IP address  
64.20.49.130
Customer  
Page URL  
https://www.muriash.com/scheduletask/runtask
Referrer URL  
Created on  
8/12/2019 10:33:48 PM
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Posted: August 13, 2019 at 12:23 PM Quote #244641
Seems error is thrown from .net framework. You may find your solution from here.

https://stackoverflow.com/questions/17772216/specified-argument-was-out-of-the-range-of-valid-values-parameter-name-site
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Jaber Kibria
Software Engineer | nop-station.com
Expertise in .NET Framework, Algolia, Plugins, Themes, Customization, Upgrade, API
Email: [email protected]
Posted: August 14, 2019 at 12:26 AM Quote #244651
set Schedule tasks Seconds (run period)  value more than 10second. its work for me.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Pls up-vote the answer, if it helps you!

Thank's,
Sangeet Shah
====================================================
NopAdvance - nopCommerce Solution Partner
Website: https://nopadvance.com
Posted: August 14, 2019 at 12:47 AM Quote #244655
Hi,

Have done that, and restarted the application, but still no change.

sangeetshah wrote:
set Schedule tasks Seconds (run period)  value more than 10second. its work for me.
This post/answer is useful
0
This post/answer is not useful

Please login or register
to vote for this post.

(click on this box to dismiss)
Premium support services
  • Dedicated premium support services provided by core developers are intended for persons who run mission critical websites, work on projects with tight deadlines, or want to get dedicated support.
Professional services
  • Want to open a new store? Want to take your store to the next level? Need a custom extension? We can customize nopCommerce to fit your store perfectly. Request a quote to get started.
eCommerce CONFERENCE 2019
Learn more