Guaranteeing complete study transfers to Orthanc

Orthanc has no single flag that says a DICOM study is finished, so you need to combine stability timing, series status and transfer method to decide when downstream work can start.

On this page

Knowing when a study has fully arrived in Orthanc

A PACS, modality or remote site often sends a study in pieces, and an automated step that fires on a partial study produces errors such as missing series, incomplete routing or premature deletion. To decide when a study is safe to act on, you must combine three signals: the stability timing that Orthanc applies to a study, the completion status Orthanc reports for each series, and the transfer method used to move the data. No single one of these answers the question on its own. This section explains why teams need that combination and what the rest of this page covers, including the controls to design and the checks to run before any downstream workflow is trusted.

The need is sharpest when Orthanc feeds routing, AI tools, deletion after forwarding, viewers that expect complete series, or peer-to-peer replication. Each of these reads a study at a moment you choose, so the moment has to be defined rather than assumed. Stability timing tells Orthanc when no new instances have arrived for a study, which is a signal of quiet, not proof of completeness. Series completion status is the stronger check, but the status is usually Unknown because no generic DICOM tag gives the number of instances in a series, so you cannot rely on it alone. Confirm with your modality and PACS vendors how they send multi-series studies, whether they resend, and whether they ever pause mid-study.

Transfer method also changes the answer. Some methods move a study in a way that is all-or-nothing from the receiver's view, while others deliver instances one at a time, so a partial arrival is possible. Check how each source sends data before choosing a trigger, and record the assumptions in your design. The sections that follow explain the stability settings, the series status checks, and which transfer methods give you a clean boundary, and they show how to hold downstream steps until those conditions are met.

Transfer methods and completion signals compared

This table compares the main ways studies reach Orthanc against atomicity, sender retries and the completion signal that fits each one. Read the atomicity and retry columns as questions to answer in your own environment, since the cells name what to confirm instead of promising behavior. The main takeaway is that no method should be assumed to deliver a whole study atomically, so downstream workflows should wait on a stable study signal backed by an instance count check.

Transfer methodAtomicity to confirmSender retriesCompletion signal that fits
C-STORE from a modality or PACSInstances arrive over one association, so an interrupted send can leave earlier instances stored. Confirm per device.Depends on the sending device or PACS. Confirm its retry behavior with the vendor.Stable study event, checked against the series and instance counts the sender reports.
C-MOVE or C-GET pull from a remote nodeOrthanc requests the study, so a broken pull can leave a partial study. Test an interrupted retrieve locally.Retry behavior depends on configuration and version. Confirm it in your environment.Stable study event after the pull job ends, checked against the expected instance count.
Peer-to-peer REST transfer to another OrthancTransfer is driven through the REST API. Confirm whether a failed transfer is rolled back or left partial.Confirm whether the sending Orthanc retries failed instances and reports per-instance errors.Job status on the sender, then the stable study event on the receiver.
DICOMweb STOW-RS into OrthancInstances travel in multipart POST requests. Confirm how a partial multipart failure is reported to the sender.Depends on the client library. Confirm that the sender resends the full batch after an error.HTTP response for each request, then the stable study event on the receiver.
Orthanc-to-Orthanc DICOM transferSent as DICOM operations. Confirm the behavior when the association drops mid-study.Confirm whether the sending job retries failed instances.Job status on the sender, then the stable study event on the receiver.
Any method, judged at study levelNo method should be treated as study-atomic by default. Judge completeness by what was received.Set by the sender in every case. Record the sender's behavior in your runbook.Stable study event plus series and instance counts from the source system.

Why series completion status is usually Unknown

Orthanc gives each series one of four completion statuses: Unknown, Missing, Inconsistent or Complete. Most series in a real archive stay at Unknown, and that is a property of DICOM rather than a fault in Orthanc. The status depends on knowing how many instances a series should contain, and no generic DICOM tag states that number. A series does not carry a header that says "this series has 240 slices." Orthanc can only compare what has arrived against an expected count if something outside the image data supplies that count, so it defaults to Unknown when nothing does.

The practical consequence is that you cannot rely on the built-in status to tell you a study is complete. Treat Unknown as the normal state and design your own checks instead. For each modality and protocol you receive, record the expected instance count per series, or the expected series count per study, from the scanner's protocol definitions, the modality vendor, or the sending site's documentation. Confirm these with the people who operate the scanners, because protocol changes and reconstruction options can alter counts without any visible notice. Store the expected values in a place your downstream jobs can read, such as a configuration file or database table keyed by modality and protocol.

Test the assumption before you build on it. Take a set of sample studies that a radiographer or physicist has confirmed as complete, export them from the source, and count instances per series in Orthanc through the REST API. Then send a deliberately interrupted transfer and check that your count-based rule flags it. Repeat the test for each modality family you receive, since multi-frame objects, localizers, dose reports and secondary captures often break simple per-series counting. The results should tell you which series your rules can judge reliably and which ones need a different signal, such as a study-level rule or an explicit end-of-study message from the sender.

Setting up a completeness gate for downstream workflows

This sequence turns the completeness rules from this page into a working gate, so that downstream steps such as routing, AI analysis or notifications start only after a study has fully arrived. Each step ends with a check you can run before the gate goes live.

  1. Inventory every sender and its transfer method

    List each modality, PACS, peer Orthanc and upload script that sends studies into Orthanc, and record how each one transfers data: DICOM C-STORE, DICOMweb STOW, the REST API, or Orthanc peer transfers. Note whether a sender can send a study as one unit or sends instances one at a time, and whether it sends a completion signal. Senders that transmit series or instances separately need the strictest gate. The inventory is done when every sender has a row with its method, its ordering behavior and the person who owns it. Confirm the details of each method with the sender's vendor or your own configuration, not from memory.

  2. Choose the stability window and series rules

    Decide how long a study must stay unchanged before it counts as stable, and which series must be present before the study is passed on. Orthanc exposes a study's age since its last change, which you can compare against your window in a hook. Because the series completion status is usually Unknown (no generic DICOM tag gives the number of instances in a series), you cannot rely on it alone. Write the rule down as a short table: sender, stability window, required modalities or series descriptions, and what happens if a required series never arrives. Check the rule with the clinical or research owner of the workflow before you encode it.

  3. Wire a Lua or Python hook that waits for stable studies

    Implement the gate in the Lua or Python scripting interface, reacting to stable study events rather than to each stored instance. The hook reads the study's series, applies your rules, and only then calls the downstream action (for example, a forward to an AI tool or a call to a notification service). If rules are not met, the hook does nothing and leaves the study in place for a later check. Keep the downstream call behind a single function so it is easy to test. The step is complete when the hook loads without errors in the Orthanc log and the downstream function is reachable only through the gate.

  4. Confirm the script execution and export routes stay disabled

    Before testing, check that the Orthanc configuration keeps the /tools/execute-script and export routes disabled, as the Orthanc security FAQ recommends. A gate that depends on scripts or exports must not open a path that lets a user run system commands or overwrite files. Verify this by calling those routes with a test account and confirming they are refused. Record the result alongside the gate configuration so reviewers can see it. Do not proceed to testing until this check passes.

  5. Send a test study with a deliberately missing series

    Use a test study, ideally a copy of a representative study with its own identifiers, and send it from one sender while withholding one required series. Let the stability window elapse without the missing series and watch the Orthanc log to confirm the hook evaluated the study and declined to pass it on. Then send the missing series and confirm the gate releases the study once it is complete and stable. Repeat with a second sender if you have more than one transfer method. The test is done when you have a logged record of both outcomes for each sender.

  6. Confirm the downstream step does not fire on partial studies

    Check the downstream system directly, not only the Orthanc log. Confirm that the step (for example, an AI analysis queue, a routing target or a notification) received nothing for the partial study during the test window, and received exactly one request for the completed study. Also confirm that a late series does not trigger a second run for the same study, or that you have a deliberate rule for re-running it. Capture the downstream logs as evidence. The gate is ready for pilot use only when this check passes for every sender in the inventory.

  7. Document the gate and schedule a retest after changes

    Write a short runbook that records the sender inventory, stability and series rules, the hook's source version, the test results and the owner of each rule. Add a retest to the change process so that any sender update, Orthanc upgrade or new series type triggers the same two-outcome test again. Ask your partner or internal team to confirm how the hook behaves after an upgrade, since Orthanc release notes can change internal behavior. The step is complete when the runbook is stored with the workflow's configuration and the retest trigger is assigned to a named owner.

How a study moves from sender to a gated downstream step

The diagram starts with modalities and peer sites that push instances to Orthanc or have Orthanc pull them. Orthanc indexes each instance under its study, and a stability timer decides when the study has stopped changing. A series completion check then reads each series status, which is usually Unknown, so the gate must rely on evidence beyond that field. Only studies that pass the gate reach downstream steps; the rest wait for review.

Studies reach downstream workflows only after the stability timer and completion checks pass.

Security and operational considerations for transfers

Transfer completeness depends on more than the import logic. The access settings, encryption of DICOM traffic, and the administrative routes an Orthanc server exposes all decide whether a study can be moved safely and whether a failed move can be found and repeated. The cards below cover the settings to check before a transfer design goes live.

Control remote access

By default Orthanc accepts HTTP connections only from localhost. If RemoteAccessAllowed is enabled for peers that use the REST API, set AuthenticationEnabled to true and define each peer account in RegisteredUsers. Confirm that peer credentials are rotated and that no anonymous route is reachable from the network segment where transfers originate. Open access lets anyone with network reach push or pull studies.

Orthanc security FAQ

Encrypt peer traffic with HTTPS

Peer-to-peer transfers over the REST API carry patient images and credentials, so they should run over HTTPS. Place the Orthanc endpoint behind a reverse proxy with a valid certificate, and confirm the sending site validates that certificate. Where the setup requires client identity, check whether mutual TLS is needed for your peer configuration before you rely on it.

Use DICOM TLS for classic exchanges

Classic DICOM associations between sites are not encrypted by default. Orthanc supports DICOM TLS for inter-site exchanges starting with version 1.9.0. Both ends must be configured, and certificate expiry and trust chains should be tracked, because an expired certificate can stop a transfer that otherwise looks healthy. Test the association with a C-ECHO before relying on it for complete study delivery.

Keep script and export routes disabled

The security FAQ warns that the /tools/execute-script route can let a malicious user run any system command, and that the export route can overwrite files. Both should stay disabled on any server that receives or forwards studies. Transfer workflows that need scripting should run from a controlled automation layer, not through an exposed REST route. Treat these two routes as closed unless a documented need and a review say otherwise.

Log rejected and failed transfers

A transfer that fails silently leaves a partial study that downstream systems may treat as complete. Record every rejected association, failed C-STORE or peer send, and series that stay in an Unknown or Incomplete state, with study identifiers and the time of the attempt. Review these logs on a schedule and keep a list of studies to resend. Confirm which log level and destination your deployment uses, and where those logs are retained.

Questions teams ask before building a completeness gate

Can our own team build a completeness gate for Orthanc without a partner?

Yes, a capable team with Orthanc experience can build one, but the work is more than a script. Your team must decide what counts as a complete study for each sender, test the rules against real transfers, and keep them working after upgrades. Orthanc assigns each series a completion status of Unknown, Missing, Inconsistent or Complete, and that status is usually Unknown because no generic DICOM tag gives the number of instances in a series, so the gate usually rests on stability timing and sender-specific rules rather than on a built-in check. Teams that want outside help can also ask Orthanc Team SRL, which sells support hours on request and offers pre-paid dedicated hours valid for 12 months.

What drives the effort of a completeness gate project?

Effort rises with four factors: the number of senders, the transfer methods in use, the series rules you need, and the testing required before go-live. Each additional modality or PACS may send studies differently, with different series ordering, retries and C-STORE behavior. Mixing DICOM push, C-MOVE pulls and peer transfers means more paths to verify. Series rules grow when some protocols legitimately have fewer images than others. Testing covers both normal and interrupted transfers, so the more failure cases you want to exercise, the more work it takes. Ask any provider to break its quote down by these four factors.

What do we need to provide for the work to go smoothly?

The work needs three inputs from your side. First, sample studies from each sender, including complete studies and any known partial or failed transfers, so rules can be tested against real behavior. Second, access to sender configuration, such as the DicomModalities entries, transfer settings and any retry policies, so the team can see how each source sends data. Third, clinical sign-off on what a complete study means for each protocol, because only clinical staff can confirm which series and image counts are expected. Ask the provider to list these inputs in the written scope before work starts.

How long does a completeness gate take to deliver?

Duration depends on the number of senders, the transfer methods involved, how many series rules must be agreed and how much testing is required. No single duration applies across environments, so treat any figure you hear before a scope review with caution. Most engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts. Ask for a timeline that maps to specific deliverables and to the sender testing they depend on, and confirm which dependencies sit with your clinical and sender teams.

What should a quote for this work include?

A useful quote states the scope in writing and lists each sender, transfer method and series rule covered. It should name the deliverables, such as the gate logic, test results, operating notes and any handover training. It should say what is excluded, for example sender reconfiguration or clinical rule design. It should identify who is responsible for each input, the testing approach and what happens if a sender changes behavior later. Finally, it should separate one-time build work from any recurring support, upgrades or retesting. Support hours from Orthanc Team SRL are quoted on request, so request that quote separately if you want vendor-level support alongside the build.

Can we tune the stability window after go-live?

Yes, a stability window is a setting you can adjust once you observe real traffic, but changes should be tested rather than made by feel. A window that is too short may start downstream workflows on partial studies. A window that is too long delays processing for every study, including the many that arrive complete. When you tune it, review sender logs and sample studies from each source, change one sender or rule at a time, and record the before and after behavior. Ask the provider how tuning is handled in the handover and whether it is covered by any ongoing support agreement.

Who is responsible when a sender changes how it transmits studies?

Your organization remains responsible for its senders, but the completeness gate must be retested whenever a sender changes. A firmware update on a scanner, a new PACS version or a change in transfer settings can alter series order, retry behavior or image counts. Assign an owner for each sender, keep the sample studies and rules documented, and set a retest step in your change process. If you use a provider, agree in writing who reruns the tests, who approves updated rules and how long you expect that to take.

Where to read the official series completion guidance

The primary reference for series completion statuses is the Orthanc Book's series completion FAQ, which explains what the statuses Unknown, Missing, Inconsistent and Complete mean and how Orthanc assigns them. Read it before writing any downstream logic that depends on a status, because the meaning of each value is what your workflow will test against. Note that the status is usually Unknown, since no generic DICOM tag gives the number of instances in a series. That means a series-level Complete check is often unavailable to you, and your completeness rule will need to rely on study-level signals and your own knowledge of what each modality should send.

Stability behavior is a separate question from series status, and the settings that control it can change between releases. Confirm the stability-related options, including how the study stability age is measured and which events fire when a study is considered stable, against the documentation for the exact Orthanc version you run. Pull the version from your own deployment rather than from memory, and keep a copy of the matching documentation with your change records. The Orthanc NEWS file is the place to check whether a release altered this behavior before you upgrade.

Ask your vendor or partner to show, for your version, which fields and events they used to decide that a study is ready, and to document the test cases that prove a partial study is held back. If the documentation for your version is ambiguous, test the behavior in a non-production environment with a deliberately incomplete study before relying on it in production.

How DeployOpen scopes and delivers complete-transfer controls

DeployOpen plans, implements, tests and documents Orthanc deployments inside the client's own infrastructure. For complete study transfers, the work starts with a written scope that names the modalities, peers and downstream workflows that depend on knowing a study is whole.

How we scope

  • Inventory every sending modality, PACS and peer, with the transfer method each one uses to deliver studies to Orthanc.
  • Define which downstream workflows must wait for a complete study and which can act on partial data.
  • Agree the completeness signals, such as stable study events and StableAge settings, in a written scope before build work starts.

How we build

  • Configure stability thresholds and stable study event handling for the agreed workflows, then test them against real sender behavior in a staging environment.
  • Build gating logic so downstream routing, export or AI steps only trigger after the agreed completeness check passes.
  • Test incomplete, interrupted and retried transfers to confirm that partial studies are held back and later completed correctly.

How we hand over

  • Deliver configuration, scripts and runbooks that show how each completeness signal is defined and where it is checked.
  • Document the known limits of each transfer method, including where a sender can deliver instances without an atomic study boundary.
  • Provide a test record and a retest plan so the client's team can rerun the completeness checks after upgrades or sender changes.

How we support

  • Fixed-scope engagements have written deliverables and timelines agreed before work starts, with changes handled through the same written process.
  • Ongoing support, upgrades and continuous testing are available as a retainer for teams that add senders or workflows over time.
  • Ask for a quote based on the written scope, which states each sender, workflow and test that the price covers.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.