Can a web service be 'cached' ?

  • Thread starter Thread starter jabailo
  • Start date Start date
J

jabailo

I build a system where a Windows service iterates through a file and
sends each line in the file as a record to a database, by calling a web
service asynchronously. It runs on a w2k server.

What I notice is:

When the web service gets called, there seems to be a slowness and
potential for missed calls - my guess is because it's being moved into
memory. This causes problems as records are dropped. My solution is
to redo the load if it notices that records are missing.

One thought I had : Is it possible to force the web service to stay in
memory ( pre-cached, basically ) so that it's /always/ ready to serve?
 
I build a system where a Windows service iterates through a file and
sends each line in the file as a record to a database, by calling a
web service asynchronously. It runs on a w2k server.

What I notice is:

When the web service gets called, there seems to be a slowness and
potential for missed calls - my guess is because it's being moved into
memory. This causes problems as records are dropped. My solution
is to redo the load if it notices that records are missing.

One thought I had : Is it possible to force the web service to stay
in memory ( pre-cached, basically ) so that it's /always/ ready to
serve?

Yes, It's possible but you must use ISA Server in cache mode or in
integrated mode.

--
---
Giuseppe Nacci
Microsoft Certified System Engineer
Security Manager

--------------------------------------------------------------------
CONFIDENTIALITY NOTICE
This message and its attachments are addressed solely to the persons
above and may contain confidential information. If you have received
the message in error, be informed that any use of the content hereof
is prohibited. Please return it immediately to the sender and delete
the message. Should you have any questions, please contact us by
replying to (e-mail address removed)
Thank you
--------------------------------------------------------------------
 
Giuseppe said:
Yes, It's possible but you must use ISA Server in cache mode or in
integrated mode.

Can I just do this:

[WebMethod]
(
Description="mymethod",
CacheDuration=43200)
]

And set it to some incredibly high value ( like 48 hours ) ?
 
Giuseppe said:
Yes, It's possible but you must use ISA Server in cache mode or in
integrated mode.

Can I just do this:

[WebMethod]
(
Description="mymethod",
CacheDuration=43200)
]

And set it to some incredibly high value ( like 48 hours ) ?

Where? In IE or where do you 'll want to set cache duration?
--
---
Giuseppe Nacci
Microsoft Certified System Engineer
Security Manager

--------------------------------------------------------------------
CONFIDENTIALITY NOTICE
This message and its attachments are addressed solely to the persons
above and may contain confidential information. If you have received
the message in error, be informed that any use of the content hereof
is prohibited. Please return it immediately to the sender and delete
the message. Should you have any questions, please contact us by
replying to (e-mail address removed)
Thank you
--------------------------------------------------------------------
 
Giuseppe said:
Giuseppe said:
(e-mail address removed) wrote:


I build a system where a Windows service iterates through a file and
sends each line in the file as a record to a database, by calling a
web service asynchronously. It runs on a w2k server.

What I notice is:

When the web service gets called, there seems to be a slowness and
potential for missed calls - my guess is because it's being moved
into memory. This causes problems as records are dropped. My
solution is to redo the load if it notices that records are missing.

One thought I had : Is it possible to force the web service to stay
in memory ( pre-cached, basically ) so that it's /always/ ready to
serve?


Yes, It's possible but you must use ISA Server in cache mode or in
integrated mode.

Can I just do this:

[WebMethod]
(
Description="mymethod",
CacheDuration=43200)
]

And set it to some incredibly high value ( like 48 hours ) ?


Where? In IE or where do you 'll want to set cache duration?

Actually that's not what I want.

That will cache results that are to be reused.

I just want the whole service to reside in memory for fast access.

Do I have to buy a whole nother product just to do that?

Can't I just change a setting in IIS 5.0 ?
 
Hi,
I just thought I'll give my idea on this. Usually IIS is very efficient
in handling multiple requests. In your case the only problem might be IIS
throwing exception saying multiple users are connected(more than the expected
lmit). One way to handle this is, always keep the number of request to a lmit
say 20. For e-g start hitting asmx with 20 requests asychronously once the
call back gets a response span another request there by u maitain the number
of hits to your asmx.
Hope this give an idea.

Thanks,
Ravi
 
Ravi said:
Hi,
I just thought I'll give my idea on this. Usually IIS is very efficient
in handling multiple requests. In your case the only problem might be IIS
throwing exception saying multiple users are connected(more than the
expected lmit). One way to handle this is, always keep the number of
request to a lmit say 20. For e-g start hitting asmx with 20 requests
asychronously once the call back gets a response span another request
there by u maitain the number of hits to your asmx.
Hope this give an idea.

That's an excellent idea!

Right now I loop through all my records and launch async calls ( up to
1000 ) all at once, and then wait for completion.

What you're saying is to launch them 20 at a time, wait, and then launch
another 20.

That makes total sense!

Thanks for your help!!!
 
Ravi said:
Hi,
I just thought I'll give my idea on this. Usually IIS is very efficient
in handling multiple requests. In your case the only problem might be IIS
throwing exception saying multiple users are connected(more than the
expected lmit). One way to handle this is, always keep the number of
request to a lmit say 20.

PS -- although I'm sort of puzzled by the idea that IIS -- which is
supposedly scalable to very large sites, cannot handle thousands of async
requests simultaneously (!)

Or maybe it's w2k threading that's not up to scratch...
 
Back
Top