locked
Query regarding StandardErrorFileName and StandardOutFileName RRS feed

  • Question

  • Hi,

    Can anyone please explain me in which scenario we don't happen to find the file StandardOutFileName and StandardOutFileName.

    In few cases we dont happen to find this file and it throws 404 exception.

                foreach (CloudTask task in job.ListTasks())
                {
                    Console.WriteLine("Task " + task.Id + " says:\n" + task.GetNodeFile(Constants.StandardErrorFileName).ReadAsString());
                    Console.WriteLine("Task " + task.Id + " says:\n" + task.GetNodeFile(Constants.StandardOutFileName).ReadAsString());
                }

    I have written aforementioned code piece which works absolutely fine in few scenarios but fails at some times.

    Thanks

    Manish

    Wednesday, January 13, 2016 9:59 AM

Answers

  • A couple scenarios come to mind:

    1. Cloudtask.State != Common.TaskState.Completed.  In this case the task has not yet completed and the file/files might not yet have been created.
    2. The CloudTask specifies a ResourceFile that does not exist, fails during download or has other problems.

    CloudTask.ExecutionInformation.SchedulingError can contain information from the service on some issues as well.


    daryl

    Wednesday, January 13, 2016 8:38 PM

All replies

  • A couple scenarios come to mind:

    1. Cloudtask.State != Common.TaskState.Completed.  In this case the task has not yet completed and the file/files might not yet have been created.
    2. The CloudTask specifies a ResourceFile that does not exist, fails during download or has other problems.

    CloudTask.ExecutionInformation.SchedulingError can contain information from the service on some issues as well.


    daryl

    Wednesday, January 13, 2016 8:38 PM
  • In addition the tasks may be queued (state of active) and have not executed yet; the task should at least be in the Running state.

    Also note that Batch flushes to these files every 3 minutes.

    Tuesday, January 26, 2016 8:05 PM