Mercurial > hg > orthanc
changeset 5535:d3e8c599797f
ignore GenericGroupLength in C-Find
author | Alain Mazy <am@osimis.io> |
---|---|
date | Mon, 19 Feb 2024 18:26:38 +0100 |
parents | d7cca6fd3584 |
children | 7c372a95c7e9 |
files | NEWS OrthancFramework/Sources/DicomNetworking/Internals/FindScp.cpp |
diffstat | 2 files changed, 16 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/NEWS Mon Feb 19 18:22:44 2024 +0100 +++ b/NEWS Mon Feb 19 18:26:38 2024 +0100 @@ -1,6 +1,17 @@ Pending changes in the mainline =============================== +Maintenance +----------- + +* In C-Find queries including GenericGroupLength tags, Orthanc was still + extracting these tags from the storage although they were already ignored + and not returned in the response. + They are now removed from the query earlier to avoid this disk access that + could slow down the response time. Note that this seems to happen mainly + when the query originates from some GE devices (AWS). + + REST API --------
--- a/OrthancFramework/Sources/DicomNetworking/Internals/FindScp.cpp Mon Feb 19 18:22:44 2024 +0100 +++ b/OrthancFramework/Sources/DicomNetworking/Internals/FindScp.cpp Mon Feb 19 18:26:38 2024 +0100 @@ -174,11 +174,15 @@ // http://dicom.nema.org/medical/dicom/current/output/chtml/part04/sect_C.4.html#sect_C.4.1.1.3 // https://groups.google.com/d/msg/orthanc-users/D3kpPuX8yV0/_zgHOzkMEQAJ + // GroupLength are removed as well since they make no sense in the filtering as well as in the response. + // Note that it seems that only some GE devices include them. + DicomArray a(source); for (size_t i = 0; i < a.GetSize(); i++) { - if (a.GetElement(i).GetTag().GetGroup() >= 0x0008) + if (a.GetElement(i).GetTag().GetGroup() >= 0x0008 + && a.GetElement(i).GetTag().GetElement() != 0x0000) { target.SetValue(a.GetElement(i).GetTag(), a.GetElement(i).GetValue()); }