Hi Oleg,

Oleg Batrashev <[email protected]>:
> > declare
> > Client = {New Open.socket client(host:"google.com" port:80)}
> > in
> > {Client write(vs:"GET / HTTP/1.0\r\n")}
> > {Client write(vs:"\r\n")}
> > {System.showInfo {Client read(list:$ size:all)}}
> > {Client close}
> High level (Open module) uses blocking connect and read/write, if I
> remember it correctly the whole Mozart VM freezes.
> So I used low level OS interface with readSelect, writeSelect and
> undocumented connectNonblocking. I do not know if it works on windows,
> but it worked just fine in linux.

This might indeed be an issue for me, because I wanted to try it
in massive parallel accesses as a next step (it's for software testing
if it works, I don't want to send spam mail or the like ;) ).

> Look at URLTextSource function for example:
> http://dougdevel.org/cgi-bin/gitweb.cgi?p=WordFinder.git;a=blob;f=TextSources.oz;h=b16a8b715a2240dac60ad1705a957c81ee174c57;hb=b77b61c71ecee2038863f2691ad8ab8cdd0264df#l46
> 
> You may be interested in looking at the whole application, because I
> scan several pages and collect words. In this case agent diagram may
> be helpful
> http://courses.cs.ut.ee/2009/cpl/uploads/Main/oz-agents.pdf

Thank you very much! That's more than I expected..

Cheers,
Eckard

Attachment: signature.asc
Description: PGP signature

_________________________________________________________________________________
mozart-users mailing list                               
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users

Reply via email to