Hi,
I have a web service that does database access and calculations
However it keeps falling over becuase its not multi threaded and each call to
it is not in its own space!!
I dont want to use com+ so is there any way of making it
Multi threaded
TIA
Stu 9 6090
Hello Stu,
It should be... what are you trying to do and how is it failing (error
message)
HTH
Regards,
Dilip Krishnan
MCAD, MCSD.net
dkrishnan at geniant dot com http://www.geniant.com Hi,
I have a web service that does database access and calculations However it keeps falling over becuase its not multi threaded and each call to it is not in its own space!! I dont want to use com+ so is there any way of making it Multi threaded TIA
Stu
Hi,
Its a calculator imagine it as a black box.
It grabs data then shoves everything into structures then process
and then writes back to the database
When Its called from a batch process to process thousands of clients
And then u call it from a web front end whilst its running you get
index out of bound errors
When the web service is called
I assumed that the structures defined etc are for each call ?
ie protected in its own apartment and hence thats why I asked the question
it works fine as a com+ component but want to move it away from there
without just wrapping a web service around the com+.ie pure web service
"Dilip Krishnan" wrote: Hello Stu, It should be... what are you trying to do and how is it failing (error message)
HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com
Hi,
I have a web service that does database access and calculations However it keeps falling over becuase its not multi threaded and each call to it is not in its own space!! I dont want to use com+ so is there any way of making it Multi threaded TIA
Stu
Hello Stu,
Every request is in its own thread/context, so making batch calls should
not interfere with your application. It could be you're running out of memory
or your aspnet wp is recycling because of the load or there is always this
possiblity :).... Could it be a problem with the logic?
HTH
Regards,
Dilip Krishnan
MCAD, MCSD.net
dkrishnan at geniant dot com http://www.geniant.com Hi,
Its a calculator imagine it as a black box. It grabs data then shoves everything into structures then process and then writes back to the database When Its called from a batch process to process thousands of clients And then u call it from a web front end whilst its running you get index out of bound errors
When the web service is called I assumed that the structures defined etc are for each call ? ie protected in its own apartment and hence thats why I asked the question it works fine as a com+ component but want to move it away from there without just wrapping a web service around the com+.ie pure web service
"Dilip Krishnan" wrote:
Hello Stu, It should be... what are you trying to do and how is it failing (error message) HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi,
I have a web service that does database access and calculations However it keeps falling over becuase its not multi threaded and each call to it is not in its own space!! I dont want to use com+ so is there any way of making it Multi threaded TIA Stu
Hi Dilip
The thing is it works as a com+ component
All ive done is call the same com+ call eg calcMyData(cust omer)
but exposed it as a web service and have made the whole thing a webservice
Its definatley something to do with appartments or variables
becuase if i kick the web service off on multiple threads from a test
program I get the same error
"Dilip Krishnan" wrote: Hello Stu, Every request is in its own thread/context, so making batch calls should not interfere with your application. It could be you're running out of memory or your aspnet wp is recycling because of the load or there is always this possiblity :).... Could it be a problem with the logic?
HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com
Hi,
Its a calculator imagine it as a black box. It grabs data then shoves everything into structures then process and then writes back to the database When Its called from a batch process to process thousands of clients And then u call it from a web front end whilst its running you get index out of bound errors
When the web service is called I assumed that the structures defined etc are for each call ? ie protected in its own apartment and hence thats why I asked the question it works fine as a com+ component but want to move it away from there without just wrapping a web service around the com+.ie pure web service
"Dilip Krishnan" wrote:
Hello Stu, It should be... what are you trying to do and how is it failing (error message) HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi,
I have a web service that does database access and calculations However it keeps falling over becuase its not multi threaded and each call to it is not in its own space!! I dont want to use com+ so is there any way of making it Multi threaded TIA Stu
Hi Dilip,
Could be something to do with that the
calculator is using a class which has shared properties on it ?
"Stu" wrote: Hi Dilip The thing is it works as a com+ component
All ive done is call the same com+ call eg calcMyData(cust omer) but exposed it as a web service and have made the whole thing a webservice
Its definatley something to do with appartments or variables becuase if i kick the web service off on multiple threads from a test program I get the same error
"Dilip Krishnan" wrote:
Hello Stu, Every request is in its own thread/context, so making batch calls should not interfere with your application. It could be you're running out of memory or your aspnet wp is recycling because of the load or there is always this possiblity :).... Could it be a problem with the logic?
HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com
Hi,
Its a calculator imagine it as a black box. It grabs data then shoves everything into structures then process and then writes back to the database When Its called from a batch process to process thousands of clients And then u call it from a web front end whilst its running you get index out of bound errors
When the web service is called I assumed that the structures defined etc are for each call ? ie protected in its own apartment and hence thats why I asked the question it works fine as a com+ component but want to move it away from there without just wrapping a web service around the com+.ie pure web service
"Dilip Krishnan" wrote:
> Hello Stu, > It should be... what are you trying to do and how is it failing > (error > message) > HTH > Regards, > Dilip Krishnan > MCAD, MCSD.net > dkrishnan at geniant dot com > http://www.geniant.com >> Hi, >> >> I have a web service that does database access and calculations >> However it keeps falling over becuase its not multi threaded and >> each >> call to >> it is not in its own space!! >> I dont want to use com+ so is there any way of making it >> Multi threaded >> TIA >> Stu >>
Hello Stu,
You're absolutely right. there is a problem in the com+ component and
the way its being used by ASP.net.
HTH
Regards,
Dilip Krishnan
MCAD, MCSD.net
dkrishnan at geniant dot com http://www.geniant.com Hi Dilip The thing is it works as a com+ component All ive done is call the same com+ call eg calcMyData(cust omer) but exposed it as a web service and have made the whole thing a webservice
Its definatley something to do with appartments or variables becuase if i kick the web service off on multiple threads from a test program I get the same error "Dilip Krishnan" wrote:
Hello Stu, Every request is in its own thread/context, so making batch calls should not interfere with your application. It could be you're running out of memory or your aspnet wp is recycling because of the load or there is always this possiblity :).... Could it be a problem with the logic? HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi,
Its a calculator imagine it as a black box. It grabs data then shoves everything into structures then process and then writes back to the database When Its called from a batch process to process thousands of clients And then u call it from a web front end whilst its running you get index out of bound errors When the web service is called I assumed that the structures defined etc are for each call ? ie protected in its own apartment and hence thats why I asked the question it works fine as a com+ component but want to move it away from there without just wrapping a web service around the com+.ie pure web service "Dilip Krishnan" wrote:
Hello Stu, It should be... what are you trying to do and how is it failing (error message) HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com > Hi, > > I have a web service that does database access and calculations > However it keeps falling over becuase its not multi threaded and > each > call to > it is not in its own space!! > I dont want to use com+ so is there any way of making it > Multi threaded > TIA > Stu
Hi Dilip
So if I remove the static class it will fix the problem
Its not a com+ component any more its a pure web service
"Dilip Krishnan" wrote: Hello Stu, You're absolutely right. there is a problem in the com+ component and the way its being used by ASP.net.
HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com
Hi Dilip The thing is it works as a com+ component All ive done is call the same com+ call eg calcMyData(cust omer) but exposed it as a web service and have made the whole thing a webservice
Its definatley something to do with appartments or variables becuase if i kick the web service off on multiple threads from a test program I get the same error "Dilip Krishnan" wrote:
Hello Stu, Every request is in its own thread/context, so making batch calls should not interfere with your application. It could be you're running out of memory or your aspnet wp is recycling because of the load or there is always this possiblity :).... Could it be a problem with the logic? HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi,
Its a calculator imagine it as a black box. It grabs data then shoves everything into structures then process and then writes back to the database When Its called from a batch process to process thousands of clients And then u call it from a web front end whilst its running you get index out of bound errors When the web service is called I assumed that the structures defined etc are for each call ? ie protected in its own apartment and hence thats why I asked the question it works fine as a com+ component but want to move it away from there without just wrapping a web service around the com+.ie pure web service "Dilip Krishnan" wrote:
> Hello Stu, > It should be... what are you trying to do and how is it failing > (error > message) > HTH > Regards, > Dilip Krishnan > MCAD, MCSD.net > dkrishnan at geniant dot com > http://www.geniant.com >> Hi, >> >> I have a web service that does database access and calculations >> However it keeps falling over becuase its not multi threaded and >> each >> call to >> it is not in its own space!! >> I dont want to use com+ so is there any way of making it >> Multi threaded >> TIA >> Stu
Hello Stu,
Oh sure that would certainly cause the problem! Any static class needs
to be thread safe
HTH
Regards,
Dilip Krishnan
MCAD, MCSD.net
dkrishnan at geniant dot com http://www.geniant.com Hi Dilip So if I remove the static class it will fix the problem Its not a com+ component any more its a pure web service "Dilip Krishnan" wrote:
Hello Stu, You're absolutely right. there is a problem in the com+ component and the way its being used by ASP.net. HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi Dilip The thing is it works as a com+ component All ive done is call the same com+ call eg calcMyData(cust omer) but exposed it as a web service and have made the whole thing a webservice Its definatley something to do with appartments or variables becuase if i kick the web service off on multiple threads from a test program I get the same error "Dilip Krishnan" wrote: Hello Stu, Every request is in its own thread/context, so making batch calls should not interfere with your application. It could be you're running out of memory or your aspnet wp is recycling because of the load or there is always this possiblity :).... Could it be a problem with the logic? HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com > Hi, > > Its a calculator imagine it as a black box. > It grabs data then shoves everything into structures then process > and then writes back to the database > When Its called from a batch process to process thousands of > clients > And then u call it from a web front end whilst its running you get > index out of bound errors > When the web service is called > I assumed that the structures defined etc are for each call ? > ie protected in its own apartment and hence thats why I asked the > question > it works fine as a com+ component but want to move it away from > there > without just wrapping a web service around the com+.ie pure web > service > "Dilip Krishnan" wrote: >> Hello Stu, >> It should be... what are you trying to do and how is it failing >> (error >> message) >> HTH >> Regards, >> Dilip Krishnan >> MCAD, MCSD.net >> dkrishnan at geniant dot com >> http://www.geniant.com >>> Hi, >>> >>> I have a web service that does database access and calculations >>> However it keeps falling over becuase its not multi threaded and >>> each >>> call to >>> it is not in its own space!! >>> I dont want to use com+ so is there any way of making it >>> Multi threaded >>> TIA >>> Stu
Hi,
Ive removed the static problem now took me ages.
So heres a summary
i have a dot net webservice in vb dot net say
objcalc.calcula te(customerId)
I know that web services are multi threaded but how do I ensure
my webservice can handle mutliple synchronous requests the web service
doesnt not need to be asynchronous.
Do I need to synchlock my parameter passed into the web service ?
What about thread pooling etc ?
Most samples seem to show how you kick off which I understand
But not in the webservice itself so Any code for this would be appreciated
"Dilip Krishnan" wrote: Hello Stu, Oh sure that would certainly cause the problem! Any static class needs to be thread safe
HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com
Hi Dilip So if I remove the static class it will fix the problem Its not a com+ component any more its a pure web service "Dilip Krishnan" wrote:
Hello Stu, You're absolutely right. there is a problem in the com+ component and the way its being used by ASP.net. HTH Regards, Dilip Krishnan MCAD, MCSD.net dkrishnan at geniant dot com http://www.geniant.com Hi Dilip The thing is it works as a com+ component All ive done is call the same com+ call eg calcMyData(cust omer) but exposed it as a web service and have made the whole thing a webservice Its definatley something to do with appartments or variables becuase if i kick the web service off on multiple threads from a test program I get the same error "Dilip Krishnan" wrote: > Hello Stu, > Every request is in its own thread/context, so making batch calls > should > not interfere with your application. It could be you're running out > of memory > or your aspnet wp is recycling because of the load or there is > always > this > possiblity :).... Could it be a problem with the logic? > HTH > Regards, > Dilip Krishnan > MCAD, MCSD.net > dkrishnan at geniant dot com > http://www.geniant.com >> Hi, >> >> Its a calculator imagine it as a black box. >> It grabs data then shoves everything into structures then process >> and then writes back to the database >> When Its called from a batch process to process thousands of >> clients >> And then u call it from a web front end whilst its running you get >> index out of bound errors >> When the web service is called >> I assumed that the structures defined etc are for each call ? >> ie protected in its own apartment and hence thats why I asked the >> question >> it works fine as a com+ component but want to move it away from >> there >> without just wrapping a web service around the com+.ie pure web >> service >> "Dilip Krishnan" wrote: >>> Hello Stu, >>> It should be... what are you trying to do and how is it failing >>> (error >>> message) >>> HTH >>> Regards, >>> Dilip Krishnan >>> MCAD, MCSD.net >>> dkrishnan at geniant dot com >>> http://www.geniant.com >>>> Hi, >>>> >>>> I have a web service that does database access and calculations >>>> However it keeps falling over becuase its not multi threaded and >>>> each >>>> call to >>>> it is not in its own space!! >>>> I dont want to use com+ so is there any way of making it >>>> Multi threaded >>>> TIA >>>> Stu This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Ganbold |
last post by:
Hi,
I'm new to multi-threaded programming and reading the book "Programming
with POSIX Threads" and
trying to understand concepts and coding.
What I'm trying to do is to rewrite mysql client application (which
calculates ISP dial-up customers' billing)
into multi-threaded version.
|
by: Rob Durant |
last post by:
Hi,
I have a multi-threaded application (have also tried as service - same
behaviour) that runs fine on XP, but not on 2003. Symptoms are:
Threads are started normally, locks acquired and released as needed,
runs fine for some time, then stops - Visual Studio detects no
exceptions, and I have placed break points on all the handling code to
catch them. No errors / failures are logged, but child threads have all
exited, and I am left...
|
by: Robert May |
last post by:
I have a windows service that spawns multiple threads running a thing that
does a bunch of processing. Here's the code that spawns the threads:
m_totalThreads=Convert.ToInt32(Settings.GetSetting("ProcessorThreads"));
m_executingThreads=new Thread;
for (int i=0;i < m_totalThreads;i++)
{
|
by: Mullin Yu |
last post by:
As subject. I have lots of VB6 dll and ocx files and they are
single-threaded as VB6 doesn't support multi-threaded indeed. Can I wrap
anything at .NET so that multi-threaded feature can be provided?
Thanks!
Mullin
|
by: BergRD |
last post by:
Salutations!
New to the forums but have gotten many an idea from lurking over the
past few months but alas it's time to begin positing; posting to a
problem I cannot seem to resolve. This is a long description but my
hopes are the more information the better someone may be able to help
:)
The Problem:
----------------------------------------------------------------------
| |
by: BergRD |
last post by:
For some odd reason my original post was double posted then removed
from the forums. Odd happenings but wanted to re-post incase no one
saw the original, thanks :D
> Salutations!
>
> New to the forums but have gotten many an idea from lurking over the
past few months but alas it's time to begin positing; posting to a
problem I cannot seem to resolve. This is a long description but my
hopes are the more information the better someone...
|
by: Stu |
last post by:
Hi,
i have a dot net webservice in vb dot net say
objcalc.calculate(customerId)
I know that web services are multi threaded but how do I ensure
my webservice can handle mutliple synchronous requests the web service
doesnt not need to be asynchronous.
Do I need to synchlock my parameter passed into the web service ?
What about thread pooling etc ?
|
by: Macca |
last post by:
Hi,
I have a multithreaded app which now needs database storage.
I am in the process of designing my Data Access Layer but and was wondering
what issues I should look for for in regards to a multi threaded app.
My app will be need to initiate access to the database from several places
in the Business logic. I'd appreaciate any advice/suggesstions on best
practices to avoid problems such as accessing the same method in the data
|
by: =?ISO-8859-1?Q?Tom=E1s_=D3_h=C9ilidhe?= |
last post by:
As far as I know, the C Standard has no mention of multi-threaded
programming; it has no mention of how to achieve multi-threaded
programming, nor does it mention whether the language or its libraries
are suitable for multi-threaded programming.
For people who are fond of portable C programming, what's the best way
to go about multi-threaded programming?
I've been reading up on POSIX threads a little, they seem pretty
ubiquitous....
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |