On 30/07/2016 6:38 pm, Monte Goulding wrote
What is tsNet ?
A curl external we have licensed from Tech Strategies
Does it just happen ?
Yes
Or do I need to do something to use it ?
If so, what ?
No, you don’t need to do anything unless you are explicitly selecting inclusions
during the standalone build. Then if you don’t have the internet library (libURL)
included you need to include it as an extra inclusion. tsNet is resolved as a
dependency of libURL. At the moment we don’t have a facility for turning tsNet off
in the event you want to use libURL (not really sure why you would want that but I
guess it’s possible). You can turn tsNet off if you want to with `dispatch
“revUnloadLibrary" to stack “tsNetLibURL”`
To add to what Monte has said, the tsNet external wraps around the
existing libURL library as well as providing its own set of commands and
functions. This provides two ways of using the external.
Using the standard networking commands (put x into URL y, post x to URL
y, load URL x, etc... ) will now automatically use the tsNet external in
DP3 when using the internet library.
There are a quite a number of benefits of tsNet, however the four most
obvious benefits you will see by using it in this fashion are:
1. you can use SFTP URLs in the format of
"sftp://user:p...@host.domain.com".
2. multiple asynchronous requests to the same server (for example when
using "load URL x" commands) are processed immediately rather than
sequentially as would happen previously
3. a significant performance improvement particularly noticeable on
large file transfers, or when executing multiple requests to the same
server one after another
4. all processing of data is offloaded to the external, improving
responsive of the LC application to other tasks during transfers (for
example, other handlers being triggered)
However, this only gives you access to a subset of the features of the
tsNet external.
There are a range of commands and functions available in the tsNet
external, all starting with "tsNet", that can be found in the LC
dictionary. These give you access to the additional features like
sending e-mails via SMTP(S) and comprehensive asynchronous request types
that are not available using the standard internet library (for example,
firing off multiple HTTP POST requests asynchronously).
I will be adding more documentation and examples over the coming weeks
to assist with using this external. In the mean time, I have uploaded a
very simple sample stack that demonstrates how to send multiple HTTP
POST requests in an asynchronous manner here:
https://downloads.techstrategies.com.au/tsnet/sample_async_post.livecode
Hope that helps,
Regards,
Charles
Where is it documented ?
In the documentation stack.
Cheers
Monte
Thanks
Alex.
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode