[erlang-questions] Erlang and the TDS protocol

42 views
Skip to first unread message

Marcel Meyer

unread,
Jun 3, 2012, 5:38:43 PM6/3/12
to erlang-questions
Dear list,

I am curious why there isn't a native Erlang TDS protocol implementation. Even /otp/lib wraps a C ODBC implementation using a port.
Would this not be simpler and more concise using bit syntax, since the TCP datagram unpacks in 1 line of code (more for readability, of course)?
It just seems like extra work: C wraps the msg, port wraps C, ODBC app wraps port etc. There is a lot of 'wrapping' going on.

Any input would be much appreciated.

Kind regards,
Marcel

David Mercer

unread,
Jun 6, 2012, 1:07:06 PM6/6/12
to Marcel Meyer, erlang-questions

Just checking to see if anyone replied to you on this and did not reply-all the list.  I would be interested in hearing the answer, too, if one is available.

 

Cheers,

 

DBM

Marcel Meyer

unread,
Jun 6, 2012, 2:22:59 PM6/6/12
to David Mercer, erlang-questions
Hi David,
No replies yet. I was wanted to see how other db wire protocols were implemented, and saw that 'dizzyd' did the mysql driver natively. I spoke to a colleague of mine and we wondered if there might be performance issues with bit syntax and that the ODBC app wanted to go straight to the metal. 
The reason I was asking this is that we're talking about how you would build a proxy to a cluster of Sql Servers (not a Sql Server Cluster).
Jan Kneschke of lighttpd fame is working on a MySql proxy, with failover/load balancing properties. Could be interesting for Sql Server...

Regards,
M

CGS

unread,
Jun 7, 2012, 9:31:46 AM6/7/12
to Marcel Meyer, erlang-questions
Hi Marcel,

I suppose the reason for using C wrappers is coming from the compatibility with the native language in which that particular SQL application is developed.

I do agree that a solution based on TCP server would be at least more readable and maybe more suitable for clustering SQL servers. Nevertheless, that's the choice of developers. Speaking for myself only, I would go with your option because I see no downfall to that and it would provide a less dependable interface.

This is my 2c opinion. If someone has a better explanation/suggestion, please, by all means, correct me.

CGS




_______________________________________________
erlang-questions mailing list
erlang-q...@erlang.org
http://erlang.org/mailman/listinfo/erlang-questions


Tim Watson

unread,
Jun 7, 2012, 9:57:09 AM6/7/12
to CGS, erlang-questions
On 7 Jun 2012, at 14:31, CGS wrote:

Hi Marcel,

I suppose the reason for using C wrappers is coming from the compatibility with the native language in which that particular SQL application is developed.

I do agree that a solution based on TCP server would be at least more readable and maybe more suitable for clustering SQL servers. Nevertheless, that's the choice of developers. Speaking for myself only, I would go with your option because I see no downfall to that and it would provide a less dependable interface.


I prefer a wire protocol implementation on the whole. The existing FreeTDS library, for example, doesn't support MARS which is pretty useful for connecting to MSSQL. If you decide to go native and open source, let me know as I'll be interested in participating, even if only it's to do some testing.
Reply all
Reply to author
Forward
0 new messages