Add Fleet Routing Breaks (Network Analyst)

Summary

Creates breaks in a Vehicle Routing Problem (VRP) layer.

Legacy:
This tool was named Add Vehicle Routing Problem Breaks prior to ArcGIS Pro 3.5.

Usage

  • This tool appends rows to the Breaks sublayer of a vehicle routing problem layer.

  • Only one type of break can be added at a time, but multiple breaks of the same type can be added with a single run of the tool. Leave the parameters associated with other types of breaks unspecified.

  • If the Target Route Name parameter value is not specified, breaks are created for each existing route.

  • To delete all existing breaks and create new breaks, uncheck the Append To Existing Routes parameter.

Parameters

LabelExplanationData Type
Input Vehicle Routing Problem Layer

The vehicle routing problem analysis layer to which the breaks will be added.

Network Analyst Layer
Target Route Name
(Optional)

The route the breaks will apply to.  If this parameter is not specified, breaks will be created for each existing route.

String
Break Type
(Optional)

Specifies the type of breaks that will be added.

  • Time Window Break Breaks will take place during a specific time window. This is the default.
  • Maximum Travel Time Break Breaks will take place after a certain amount of travel time. These values are either the amount of time until the first break or the amount of time between breaks.
  • Maximum Work Time Break Breaks will take place after a certain amount of cumulative time. These values are an amount of elapsed time since the start of the route.
String
Break Properties
(Optional)

Specifies a time range within which the break will begin. To set up a time window break, use two time-of-day values.

The properties below are enabled when the Break Type parameter is set to Time Window Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Time Window Start—The start time of the time window.
  • Time Window End—The end time of the time window.
  • Maximum Violation Time—The maximum allowable violation time for a time window break in the units of the layer's Time Field Units property. A time window is considered violated if the arrival time falls outside the time range. A zero value indicates that the time window cannot be violated, that is, the time window is hard. A nonzero value indicates the maximum delay time. For example, the break can begin up to 30 minutes beyond the end of its time window, but the delay is penalized pursuant to the Time Window Importance setting, which rates the importance of honoring time windows without causing violations.

Value Table
Break Properties
(Optional)

Specifies how long a person can travel before the break is required.

The properties below are enabled when the Break Type parameter is set to Maximum Travel Time Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Maximum Travel Time Between Breaks—The maximum amount of travel time that can be accumulated before the break is taken in the units of the layer's Time Field Units property. The travel time is accumulated either from the end of the previous break or, if a break has not yet been taken, from the start of the route.

    If this is the route's final break, The MaxTravelTimeBetweenBreaks field also indicates the maximum travel time that can be accumulated from the final break to the end depot.

    This field limits how long a person can drive until a break is required. For example, if the layer's Time Field Units property is set to Minutes, and the MaxTravelTimeBetweenBreaks field has a value of 120, the driver will get a break after two hours of driving. To assign a second break after two additional hours of driving, the second break's MaxTravelTimeBetweenBreaks field value must be 120.

Value Table
Break Properties
(Optional)

Specifies how long a person can work before a break is required.

The properties below are enabled when the Break Type parameter is set to Maximum Work Time Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Maximum Cumulative Work Time—The maximum amount of work time that can be accumulated before the break is taken in the units of the layer's Time Field Units property. Work time is accumulated from the beginning of the route. Work time is the sum of travel time and service times at orders, depots, and breaks. However, it excludes wait time, which is the time a route (or driver) spends waiting at an order or depot for a time window to begin.

    The MaxCumulWorkTime field also indicates the maximum amount of work time that can be accumulated before the break is taken.

    This field limits how long a person can work until a break is required. For example, if the Time Field Units parameter (time_units in Python) is set to Minutes, the MaxCumulWorkTime field has a value of 120, and the ServiceTime field has a value of 15, the driver will get a 15-minute break after 2 hours of work.

    Continuing with this example, assume a second break is needed after 3 additional hours of work. To specify this break, you would enter 315 (5 hours and 15 minutes) as the second break's MaxCumulWorkTime field value. This number includes the MaxCumulWorkTime and ServiceTime field values of the preceding break, along with the 3 additional hours of work time before granting the second break. To avoid taking maximum work time breaks prematurely, remember that work time is accumulated from the beginning of the route and it includes the service time at previously visited depots, orders, and breaks.

Value Table
Append To Existing Breaks
(Optional)

Specifies whether new breaks will be appended to the existing breaks attribute table.

  • Checked—New breaks will be appended to the existing set in the breaks attribute table. This is the default.
  • Unchecked—Existing breaks will be replaced with new breaks.

Boolean

Derived Output

LabelExplanationData Type
Output Vehicle Routing Problem Layer

The updated network analyst layer.

Network Analyst Layer

arcpy.na.AddVehicleRoutingProblemBreaks(in_vrp_layer, {target_route}, {break_type}, {time_window_properties}, {travel_time_properties}, {work_time_properties}, {append_to_existing_breaks})
NameExplanationData Type
in_vrp_layer

The vehicle routing problem analysis layer to which the breaks will be added.

Network Analyst Layer
target_route
(Optional)

The route the breaks will apply to.  If this parameter is not specified, breaks will be created for each existing route.

String
break_type
(Optional)

Specifies the type of breaks that will be added.

  • TIME_WINDOW_BREAK Breaks will take place during a specific time window. This is the default.
  • MAXIMUM_TRAVEL_TIME_BREAK Breaks will take place after a certain amount of travel time. These values are either the amount of time until the first break or the amount of time between breaks.
  • MAXIMUM_WORK_TIME_BREAK Breaks will take place after a certain amount of cumulative time. These values are an amount of elapsed time since the start of the route.
String
time_window_properties
[time_window_properties,...]
(Optional)

Specifies a time range within which the break will begin. To set up a time window break, use two time-of-day values.

The properties below are enabled when the Break Type parameter is set to Time Window Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Time Window Start—The start time of the time window.
  • Time Window End—The end time of the time window.
  • Maximum Violation Time—The maximum allowable violation time for a time window break in the units of the layer's Time Field Units property. A time window is considered violated if the arrival time falls outside the time range. A zero value indicates that the time window cannot be violated, that is, the time window is hard. A nonzero value indicates the maximum delay time. For example, the break can begin up to 30 minutes beyond the end of its time window, but the delay is penalized pursuant to the Time Window Importance setting, which rates the importance of honoring time windows without causing violations.

Value Table
travel_time_properties
[travel_time_properties,...]
(Optional)

Specifies how long a person can travel before the break is required.

The properties below are enabled when the Break Type parameter is set to Maximum Travel Time Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Maximum Travel Time Between Breaks—The maximum amount of travel time that can be accumulated before the break is taken in the units of the layer's Time Field Units property. The travel time is accumulated either from the end of the previous break or, if a break has not yet been taken, from the start of the route.

    If this is the route's final break, The MaxTravelTimeBetweenBreaks field also indicates the maximum travel time that can be accumulated from the final break to the end depot.

    This field limits how long a person can drive until a break is required. For example, if the layer's Time Field Units property is set to Minutes, and the MaxTravelTimeBetweenBreaks field has a value of 120, the driver will get a break after two hours of driving. To assign a second break after two additional hours of driving, the second break's MaxTravelTimeBetweenBreaks field value must be 120.

Value Table
work_time_properties
[work_time_properties,...]
(Optional)

Specifies how long a person can work before a break is required.

The properties below are enabled when the Break Type parameter is set to Maximum Work Time Break.

  • Is Paid—A Boolean value indicating whether the break is paid.
  • Break Duration—The duration of the break in the units of the layer's Time Field Units property. This property can't contain null values and has a default value of 60.
  • Maximum Cumulative Work Time—The maximum amount of work time that can be accumulated before the break is taken in the units of the layer's Time Field Units property. Work time is accumulated from the beginning of the route. Work time is the sum of travel time and service times at orders, depots, and breaks. However, it excludes wait time, which is the time a route (or driver) spends waiting at an order or depot for a time window to begin.

    The MaxCumulWorkTime field also indicates the maximum amount of work time that can be accumulated before the break is taken.

    This field limits how long a person can work until a break is required. For example, if the Time Field Units parameter (time_units in Python) is set to Minutes, the MaxCumulWorkTime field has a value of 120, and the ServiceTime field has a value of 15, the driver will get a 15-minute break after 2 hours of work.

    Continuing with this example, assume a second break is needed after 3 additional hours of work. To specify this break, you would enter 315 (5 hours and 15 minutes) as the second break's MaxCumulWorkTime field value. This number includes the MaxCumulWorkTime and ServiceTime field values of the preceding break, along with the 3 additional hours of work time before granting the second break. To avoid taking maximum work time breaks prematurely, remember that work time is accumulated from the beginning of the route and it includes the service time at previously visited depots, orders, and breaks.

Value Table
append_to_existing_breaks
(Optional)

Specifies whether new breaks will be appended to the existing breaks attribute table.

  • APPENDNew breaks will be appended to the existing set in the breaks attribute table. This is the default.
  • CLEARExisting breaks will be replaced with new breaks.
Boolean

Derived Output

NameExplanationData Type
out_vrp_layer

The updated network analyst layer.

Network Analyst Layer

Environments

This tool does not use any geoprocessing environments.

Licensing information

  • Basic: Yes
  • Standard: Yes
  • Advanced: Yes

Related topics