Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Wednesday, October 7, 2009 1:27:10 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

I'm not sure I understood the question correctly. Are you asking about our demo or you own application? Are you trying to use the same association from multiple threads? Did you try to loop the way I suggested?
Please give me more details about what you're trying to do.

 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Wednesday, October 7, 2009 11:30:59 PM(UTC)

guohy  
guohy

Groups: Registered
Posts: 3


hi,Adnan, thanks for your help. Maybe i didn't talk about my question clearly. In gerenally, i  have two questions.

The first is LEADTOOLS Dicom PACS Module Supports for TCP/IP multiple clients and multiple servers, working in Asynchronous or Synchronous mode. But i can't find any functions to set  the Asynchronous or Synchronous mode.For example,  if i want to set the Synchronous mode, which function should be used for? 

The second question is i modify the CStore Demo from the v15 (C++ class library) to store many Dicom files in a association connection.(At first, i modify the storeDemo to store one file once a associate connection, this demo run ok ,but store speed is too low and ineffective). As you Said before, i loop within the OnReceiveAssociateAccept and call SendCStoreRequest to store multiple DICOM files.For example, if i store five files, the program run five times of "OnReceiveAssociateAccept()" continuiusly and then run five times of "OnReceiveCStoreResponse()", the five files store successful. But, if i store many files (for example , 500 files), the program run many times the module of "OnReceiveAssociateAccept()", but doesn't run the module of "On ReceiveCStoreResponse()", and i  find no one file store successful.  i think the reason may be is the demo run in Asynchronous mode which the client don't waits for each request to complete before sending the next one. i modify the store module of ClientDemo is also very similar.

 
#3 Posted : Thursday, October 8, 2009 8:20:10 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

For more information about Synchronous/Asynchronous Operations, see the following help topics in our C++ Class Library DICOM help file:
LDicomAssociate::IsAsyncOperations
LDicomAssociate::SetAsyncOperations
LDicomAssociate::GetInvokedOperations
LDicomAssociate::GetPerformedOperations

About the second part, you should not perform the association multiple times. You can perform one association and do multiple CStore requests in that one association.
 
#4 Posted : Monday, October 12, 2009 2:21:01 AM(UTC)

guohy  
guohy

Groups: Registered
Posts: 3


Thank you for replying. i modify the store demo, it loop within the OnReceiveAssociateAccept and call SendCStoreRequest to store multiple DICOM files, please refer to the attachment file.But,  I am still having issues with it. For example, if i start storing N dicom files. Firstly, it will run N times of SendCStoreRequest, then run N times of OnReceiveCStoreResponse. how to keep the demo before send next file it run the OnReceiveCStoreResponse. what's reason for this ? maybe, i should use the synchronous mode or use the multithread mode? i am looking forward to your help.Thanks!

                                         guo

File Attachment(s):
demo.txt (9kb) downloaded 194 time(s).
 
#5 Posted : Tuesday, October 13, 2009 7:40:17 AM(UTC)

Adnan Ismail  
Guest

Groups: Guests
Posts: 3,022

Was thanked: 2 time(s) in 2 post(s)

As described in the help file, there's a limit to how many asynchronous functions you can actually send.  Also, the server is going to have to support it as well.  Since it worked for small batches of images but not large batches, probably one of two things is happening:
1. Either you're sending more asynchronous functions than are allowed in the association.
2. Or you're sending so many requests that that the server doesn't have a chance to send a response so the client times out.
In either case, I believe the solution is to implement some kind of waiting mechanism with threads inside the project. You can loop through files and send multiple requests on the same association, but they must wait/sleep after a CStore request until the CStoreResponse comes though.

 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.162 seconds.