DcmSCP methods removed in 3.6.1

All other questions regarding DCMTK

Moderator: Moderator Team

Post Reply
Message
Author
martinrame
Posts: 347
Joined: Mon, 2009-02-23, 19:57

DcmSCP methods removed in 3.6.1

#1 Post by martinrame »

Hi, I'm upgrading an app which was compiled against 3.6.0 and now I'm moving to 3.6.1, in this app I used this code:

Code: Select all

if(m_scp.enableMultiProcessMode(argc, argv) == EC_Normal)
  {
    if(lForkedChild == true)
    {
      if(m_scp.markAsForkedChild() == EC_Normal)
      {
        DCMNET_DEBUG("forked child");
      }
    }
}
As you can see there are two methods enableMultiProcessMode and markAsForkedChild used there. Those methods no longer exist on 3.6.1, does that mean in Win32 there's no more fork, or it is handled differently?.

Regards,
Leonardo.

J. Riesmeier
DCMTK Developer
Posts: 2504
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: DcmSCP methods removed in 3.6.1

#2 Post by J. Riesmeier »

The old-fashioned multi-process mode has been removed from the DcmSCP class with the following commit: http://git.dcmtk.org/web?p=dcmtk.git;a= ... 855e40453b
Those methods no longer exist on 3.6.1, does that mean in Win32 there's no more fork, or it is handled differently?.
The fork mechanism for Windows was more a quick hack than a well-designed feature, so the new approach of a threaded SCP class is now the preferred way of handling multiple associations at a time.

The command line tool "storescp" still supports the fork mechanism (on both Unix and Windows systems) but that's another story...

martinrame
Posts: 347
Joined: Mon, 2009-02-23, 19:57

Re: DcmSCP methods removed in 3.6.1

#3 Post by martinrame »

Ok. My app implements the handleIncomingCommand method for handling requests, should I still use this method?.

Also, in the former version I implemented a ConnectToDb method in my DcmSCP inherited constructor and disconnect in the destructor, this way I had a database connection on every association, when the association finishes the database is disconnected. With the new method where should I connect/disconnect to preserve the same mechanism (connect on assocciation) ?.

The last question is, here http://support.dcmtk.org/docs-snapshot/ ... onfig.html is mentioned an SCP configuration file, where can I find an example of that file and/or a description of its structure?.

Regards,
Leonardo.

J. Riesmeier
DCMTK Developer
Posts: 2504
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: DcmSCP methods removed in 3.6.1

#4 Post by J. Riesmeier »

I personally never used the DcmSCPPool and DcmThreadSCP classes so far, so I could only recommend to look into the source and read the documentation (this would be the same that I would have to do).

Regarding the configuration file, you can find a sample in the "dcmnet/etc" subdirectory of the DCMTK source code package. The documentation is available in "dcmnet/asconfig.txt". This is the same configuration file that is also used by storescp and dcmrecv.

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest