Is it possible to use classic ASP components with nodejs?

972 views
Skip to first unread message

Umut Muhaddisoglu

unread,
Dec 25, 2012, 7:11:00 AM12/25/12
to nod...@googlegroups.com
Is there a way to use any classic ASP components (like http://www.aspemail.com/) with nodejs?

I'm running nodejs on a Windows machine, need to run ping command concurrently and forking new ping processes is pretty expensive.

As there are classic ASP components making ping requests using raw sockets, they can help me.

Any way to do that?

Thanks.


José F. Romaniello

unread,
Dec 25, 2012, 9:58:38 AM12/25/12
to nod...@googlegroups.com
Short answer no. 

Long answer you could write a native module, using c++ or maybe c++/cli to interact with the COM component. I wrote a blogpost about it 
http://joseoncode.com/2012/04/10/writing-your-first-native-module-for-node-dot-js-on-windows/

But it is not that easy and requires a some effort. If you just need to send mails, there are a lot of modules to do that on npm.
IMHO the ecosystem of libraries in node.js is biger than ASP3, just try npm search mail. 
Almost  everything is opensource, and you will find the documentation in the github page for the project.
--
Job Board: http://jobs.nodejs.org/
Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nod...@googlegroups.com
To unsubscribe from this group, send email to
nodejs+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Bert Belder

unread,
Dec 25, 2012, 5:32:20 PM12/25/12
to nod...@googlegroups.com


On Tuesday, December 25, 2012 1:11:00 PM UTC+1, Umut Muhaddisoglu wrote:
As there are classic ASP components making ping requests using raw sockets, they can help me.


I think you'd be better off by creating a native extension that binds IcmpSendEcho (http://msdn.microsoft.com/en-us/library/windows/desktop/aa366050(v=vs.85).aspx).

- Bert 

Umut Muhaddisoglu

unread,
Jan 16, 2013, 5:24:28 AM1/16/13
to nod...@googlegroups.com
Thanks so much for the responses.

Writing native modules is beyond my talents.

I'm trying to send PING commands without forking new processes but no such module exists for Windows-nodejs.

Thanks very much.

Angel Java Lopez

unread,
Jan 16, 2013, 5:31:42 AM1/16/13
to nod...@googlegroups.com
Ummm... as pointed in this thread, there is a dll with ping functionality.

One option it's using Node.js FFI


You can link a dll (in many operating systems, so Windows), and call it wo/writing C code (ok, with a performance penalty). But I'm not sure it could be applied to your use case.

Simon

unread,
Jan 17, 2013, 1:26:36 AM1/17/13
to nod...@googlegroups.com
Would it be relatively straightforward to use node-ffi to access OLE/COM objects on Windows without writing C? This would be useful in building a web app or CLI to interface with software like hMailServer which has an extensive COM API.

Umut Muhaddisoglu

unread,
Jan 24, 2013, 2:47:17 AM1/24/13
to nod...@googlegroups.com
This looks so good to be true. Seems hard to debug but will probably work.

Thanks so much and will give it a try.

Simon

unread,
Jan 25, 2013, 4:24:04 AM1/25/13
to nod...@googlegroups.com
If you do give it a try, please post your results. I'd be interested in if and how well this works for your use case.

Thanks.

Umut Muhaddisoglu

unread,
Jan 28, 2013, 6:27:47 AM1/28/13
to nod...@googlegroups.com
I actually failed on teh 2st step: installing node-ffi. Getting errors with it and considering workarounds for the task.
Reply all
Reply to author
Forward
0 new messages