Problem
The bundled Orthanc test servers only accept DIMSE requests from the AE title ADIT1DEV, which is the example.env default:
"DicomModalities": {
"ORTHANC2": ["ORTHANC2", "orthanc2", 7502],
"ADIT": ["ADIT1DEV", "receiver", 11112]
}
Every real deployment changes CALLING_AE_TITLE (the hospital PACS has to know ADIT's AE title). Nothing in example.env or the admin guide says that orthanc/orthanc1.json and orthanc/orthanc2.json must follow, so the Orthanc test servers silently stop working in such a deployment:
- Orthanc accepts the association (C-ECHO works, the admin proxy to the Orthanc UI works) but aborts every C-FIND / C-GET / C-MOVE from the unknown AE title.
- In ADIT this surfaces as
RetriableDicomError("Connection timed out, was aborted or received invalid response.") after ~80 s of retries (Selective Transfer, DICOMweb API, adit-client). That reads like a network problem and sends people debugging Docker networking.
- The real cause is only visible in the Orthanc log:
DICOM authorization rejected for AET ADIT1 on IP ...: This AET is not listed in configuration option "DicomModalities"
Rejected Find request from remote DICOM modality with AET "ADIT1" and hostname "..."
Reproduced with jodogne/orthanc-plugins:1.13.0 and the config from this repo:
| Calling AE title |
Result |
ADIT1DEV |
association established, C-FIND 0x0000 |
ADIT1 |
association established, C-FIND immediately aborted (empty status) |
The same coupling exists for RECEIVER_AE_TITLE: the ADIT entry doubles as the C-MOVE destination, so a changed receiver AE title breaks C-MOVE from the test servers as well.
On a Swarm deployment fixing it is not just an edit: the JSON files are Swarm configs, which are immutable, so the two Orthanc services and their configs have to be removed and the stack redeployed.
Suggestion
At minimum, a hint in the docs:
- In
example.env next to CALLING_AE_TITLE / RECEIVER_AE_TITLE: "The Orthanc test servers only accept the AE titles listed in orthanc/orthanc*.json (DicomModalities). Update them when you change these values."
- In the admin guide (Environment Variables / DICOM section), including how to apply it on Swarm (remove
<stack>_orthanc1/_orthanc2 services and their *_config objects, then stack-deploy).
Alternatives that would remove the trap entirely
- Derive the Orthanc config from
.env. Render orthanc*.json from a template in cli compose-up / cli stack-deploy, substituting CALLING_AE_TITLE and RECEIVER_AE_TITLE. Or switch the test servers to the orthancteam/orthanc image, which supports configuration through environment variables (ORTHANC__DICOM_MODALITIES=...), so the compose file can inject ${CALLING_AE_TITLE} directly.
- Relax the test servers. They are test-only, so
"DicomAlwaysAllowFind": true, "DicomAlwaysAllowGet": true, "DicomAlwaysAllowMove": true, "DicomAlwaysAllowStore": true would accept any calling AE title. The DicomModalities entry would then only matter as C-MOVE destination (host/port of the receiver), keyed by RECEIVER_AE_TITLE.
- Preflight check in the CLI, like the existing check for quoted
.env values: warn in compose-up / stack-deploy when CALLING_AE_TITLE or RECEIVER_AE_TITLE does not appear in orthanc/orthanc*.json.
- Better error message. In
DimseConnector.send_c_find (and the retrieve/store counterparts), an empty status right after a successful association almost always means the peer refused the calling AE title. Adding a hint such as "the DICOM server may not accept the calling AE title settings.CALLING_AE_TITLE; check its modality configuration" would have pointed straight at the cause.
Workaround without redeploying
Orthanc accepts new modalities at runtime via its REST API, e.g. from the web container:
PUT http://orthanc1.local:6501/modalities/ADITPROD {"AET": "ADIT1", "Host": "receiver", "Port": 11112}
PUT http://orthanc2.local:6502/modalities/ADITPROD {"AET": "ADIT1", "Host": "receiver", "Port": 11112}
This takes effect immediately but is lost on the next Orthanc restart, because DicomModalitiesInDatabase is left at its default false.
Problem
The bundled Orthanc test servers only accept DIMSE requests from the AE title
ADIT1DEV, which is theexample.envdefault:Every real deployment changes
CALLING_AE_TITLE(the hospital PACS has to know ADIT's AE title). Nothing inexample.envor the admin guide says thatorthanc/orthanc1.jsonandorthanc/orthanc2.jsonmust follow, so the Orthanc test servers silently stop working in such a deployment:RetriableDicomError("Connection timed out, was aborted or received invalid response.")after ~80 s of retries (Selective Transfer, DICOMweb API,adit-client). That reads like a network problem and sends people debugging Docker networking.Reproduced with
jodogne/orthanc-plugins:1.13.0and the config from this repo:ADIT1DEV0x0000ADIT1The same coupling exists for
RECEIVER_AE_TITLE: theADITentry doubles as the C-MOVE destination, so a changed receiver AE title breaks C-MOVE from the test servers as well.On a Swarm deployment fixing it is not just an edit: the JSON files are Swarm configs, which are immutable, so the two Orthanc services and their configs have to be removed and the stack redeployed.
Suggestion
At minimum, a hint in the docs:
example.envnext toCALLING_AE_TITLE/RECEIVER_AE_TITLE: "The Orthanc test servers only accept the AE titles listed inorthanc/orthanc*.json(DicomModalities). Update them when you change these values."<stack>_orthanc1/_orthanc2services and their*_configobjects, thenstack-deploy).Alternatives that would remove the trap entirely
.env. Renderorthanc*.jsonfrom a template incli compose-up/cli stack-deploy, substitutingCALLING_AE_TITLEandRECEIVER_AE_TITLE. Or switch the test servers to theorthancteam/orthancimage, which supports configuration through environment variables (ORTHANC__DICOM_MODALITIES=...), so the compose file can inject${CALLING_AE_TITLE}directly."DicomAlwaysAllowFind": true,"DicomAlwaysAllowGet": true,"DicomAlwaysAllowMove": true,"DicomAlwaysAllowStore": truewould accept any calling AE title. TheDicomModalitiesentry would then only matter as C-MOVE destination (host/port of the receiver), keyed byRECEIVER_AE_TITLE..envvalues: warn incompose-up/stack-deploywhenCALLING_AE_TITLEorRECEIVER_AE_TITLEdoes not appear inorthanc/orthanc*.json.DimseConnector.send_c_find(and the retrieve/store counterparts), an empty status right after a successful association almost always means the peer refused the calling AE title. Adding a hint such as "the DICOM server may not accept the calling AE titlesettings.CALLING_AE_TITLE; check its modality configuration" would have pointed straight at the cause.Workaround without redeploying
Orthanc accepts new modalities at runtime via its REST API, e.g. from the web container:
This takes effect immediately but is lost on the next Orthanc restart, because
DicomModalitiesInDatabaseis left at its defaultfalse.