DSN Connection - WeOnlyDo Discussion board

DSN Connection (General questions)

by jasnew1969, Monday, January 09, 2012, 16:41 (4700 days ago)

Ok, I'm stumped. I've coded in the tunnel and it starts and works fine. If I stop once the tunnel is started I can connect to my MySQL server no problem using another program. If I start the tunnel using your sample and forward the connection in, I can open my program and it will use the tunnel to forward the connection. Problem happens when I use the tunnel and the sql connection in the same program it locks up. If I start a tunnel, and then issue the ncsqltest.open it locks up. If I start the tunnel with the sample, skip the code I wrote to start the tunnel and issue the same open command, works. I'm stumped.

Re: DSN Connection

by woddrazen, Monday, January 09, 2012, 16:56 (4700 days ago) @ jasnew1969

Hi,


Problem you are receiving is with many dababase clients because they block the thread when you use them. wodSSHTunnel lives is same thread where database client is and cannot process windows messages. So everything freeze.

Here are suggestions you can try to solve this issue:
- move database client to separate thread
- or you can use EXE version of wodSSHTunnel (wodTunnel.EXE) wodSSHTunnel.exe is out of process COM object that can work in separate process
- or set Threads Property to True. Please make sure that your programming environment supports multithreading

Let us know how it goes.


Regards,
Drazen

Re: DSN Connection

by jasnew1969, Monday, January 09, 2012, 19:17 (4700 days ago) @ woddrazen

That explains a lot. Was getting a little frustrated with it all. Is there code showing how to use the EXE versions?

Re: DSN Connection

by woddrazen, Monday, January 09, 2012, 19:27 (4700 days ago) @ jasnew1969

Hi,


You need to import wodSSHTunnel EXE inside your programming environment. Code is same as using ActiveX or COM version of wodSSHTunnel.

Let us know if you need more help.


Drazen

Re: DSN Connection

by jasnew1969, Monday, January 09, 2012, 21:04 (4700 days ago) @ woddrazen

well, that didn't work. It still locks up even after loading wodtunnel.exe. Just have to shell a seperate program to start and stop the channels I guess.

Re: DSN Connection

by jasnew1969, Monday, January 09, 2012, 21:43 (4700 days ago) @ jasnew1969

If I send you the test project I have, do you have a way of testing to see if something I'm doing? It's just a simple 1 form project just to test this out.

Re: DSN Connection

by woddrazen, Monday, January 09, 2012, 22:22 (4700 days ago) @ jasnew1969

Hi,


Yes, you can send us sample to techsupport@weonlydo.com


Drazen