Editing Custom Schedule Task

Vote:
 

Hello all

If anyone can help me on another issue I have found with my server migration that would be great! I now also need to edit a range of custom schedules that have been created and have stopped working. Have researched some but cna only find creating custom scheduled jobs but no information out there on amending.

As always thank you in advance.

#61102
Sep 06, 2012 22:59
Vote:
 

If you have problem running them automatically but manually works?

1. Check that the new version of the SchedulingService is running on the machine so that it hasn't been switched off.

2. Try setting all time values for all scheduled jobs when they should run somewhere in the future and save them. Having an activated scheduled job set to a time in the past seems to mess up scheduling sometimes. Running the job manually once also seems to correct the problem usually.

3. If you can't even run them manually, set up logging with log4net, hunt and kill that bug. Might be some settings that is wrong in appsettings, access rights etc


Good luck :)

 

#61115
Sep 07, 2012 11:42
Vote:
 

Hello

Thank you for taking to time to reply. I believe it is actually the scheduled job itself that is failing as the server has moved from one box to another so a lot of environment variables have had to be changed including directory paths. Overall the server is working and I can see the schedule itself running but it doesn't do as expected. Question I guess is where would I find the code the schedule is executing?

#61121
Sep 07, 2012 13:29
Vote:
 

Ah ok. Then you will need to open the source code for the site and search for classes that have the attribute

[EPiServer.PlugIn.ScheduledPlugIn]


All scheduled jobs have a matching class in the source code that has this attribute.

Either debug these classes with visual studio if possible and see what seems to be the problem / what settings are wrong. Otherwise you will need to modify code and add logging of all exceptions etc to see what happens if you are not able to debug with VS. I would recommend using log4net for this since it is already included in the EPiServer solution.

For integrations and scheduled jobs and similar, having good logging functionality saves a lot of time when searching for errors :)

 

#61122
Sep 07, 2012 13:36
Vote:
 

That's excellent, now all I have to do is find where the developer placed the code! Not obvious by looking and doing a texcrawl through the directories doesn't produce a find either. Any thoughts on where Episerver places the classes it looks for?

#61126
Sep 07, 2012 14:52
Vote:
 

Do you have the actual source code including Visual Studio project etc or are you just searching in the files on the website. You will need to have the actual source to find it...

#61127
Sep 07, 2012 14:57
Vote:
 

Sorry typing slower than my brain allows, that should be 'can't find the source files as the developer has put them some where that can't be found'.

Would you know where the classes are stored so I can tell them which classes we are requiring? Or does it simply update a generic class file and store the task there such as a .pdb file?

 

#61130
Sep 07, 2012 15:27
Vote:
 

Before you have source code including Visual Studio project files etc + a .NET developer, there is nothing you can do to fix this sorry.

#61132
Sep 07, 2012 15:36
Vote:
 

No apologies needed, appreciate your time here and your responses has given me some support in raising the issue internally.

#61136
Sep 07, 2012 15:57
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.