Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.
This repository was archived by the owner on Nov 24, 2025. It is now read-only.

Creating a DSR with an ID causes weird behavior #6788

@ocket8888

Description

@ocket8888

This Bug Report affects these Traffic Control components:

  • Traffic Ops

Current behavior:

When creating a DSR (in both APIv3 and APIv4) you may optionally specify an ID. In doing so, Traffic Ops will treat it as a PUT request for the purposes of validation. This means that it will look for an existing Delivery Service with that ID, and try to verify that the status of the DSR to be created is in a status that is a valid transition from the status of the existing Delivery Service - which can lead to false negatives in the validation of the DSR. Or, if the ID is not one that matches any existing DSR, a 400 Bad Request error is returned to the client with no real information about what went wrong (unknown error in v3 and simply Bad Request in v4).

Expected behavior:

Fields that aren't required should be ignored, and should not affect validation.

Steps to reproduce:

$ topost -kp deliveryservice_requests '{"status": "submitted", "changeType": "create", "deliveryService": {}, "id": 10000}'
{
	"alerts": [
		{
			"text": "unknown error",
			"level": "error"
		}
	]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Traffic Opsrelated to Traffic Opsbugsomething isn't working as intendedlow difficultythe estimated level of effort to resolve this issue is lowlow impactaffects only a small portion of a CDN, and cannot itself break one

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions