Uploaded image for project: 'JS - JobScheduler'
  1. JS - JobScheduler
  2. JS-1879

Path reaches beyond root (too many '..')

    XMLWordPrintable

Details

    Description

      Current Situation

      • An order is assign a schedule.
      • The schedule makes use of an include file ("holiday" file) like this:
        <include live_file="../../../../SCHEDULES/operations_calendar.xml">
      • The relative path is correct as the order is located at 4 levels in the folder hierarchy starting from ./live:
        ./live/A/B/C/D
      • Assignment of the include file with the above relative path works fine and is accepted by the Master. The orders start-time is calculated correctly.
      • After a restart of the Master the following error is reported:
         
        2020-04-23 16:09:40.426+0900 [ERROR]  (Job_chain /A/B/C/D/job_chain1) SCHEDULER-295  Error when loading order order1 from database: SCHEDULER-399  Error in <include live_file="../../../../SCHEDULES/operations_calendar.xml"/>:
        2020-04-23 16:09:40.426+0900 [ERROR]  (Job_chain /A/B/C/D/order1) SCHEDULER-461  Path reaches beyond root (too many '..'): /../../../../SCHEDULES/operations_calendar.xml
        

        The assumption that the path reaches beyond root is wrong. Possibly the Master calculates relative paths differently at run-time and on start-up. With the error message an additional / is pre-pended to the relative path.

      • As a result the order's start-time is not re-calculated. Users have to re-assign the schedule to the order to force re-calculation of the start-time.
      • The above observations are about use of <include live_file="..."> in "holiday" files of schedules. We should check if the problem is limited to this or if it could occur with other objects that make use of <include live_file="..."> attribute as well.

      Desired Behavior

      • Relative paths should be considered after restart in the same way as they are considered when being configured at run-time.

      Attachments

        Activity

          People

            jz Joacim Zschimmer
            ap Andreas PĆ¼schel
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: