Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Mon Jul 15, 2019 3:53 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: Problem with HTTPSecureSocket speed.
PostPosted: Wed Jul 18, 2012 7:09 am 
Offline

Joined: Fri Dec 01, 2006 9:39 pm
Posts: 180
My application communicates witch a sat/cable receiver via a HTTPSecureSocket.
The code I'm using is simple:
Function getUrlTextFromBox(theURL As String, ReturnTime As Integer = 60) As String
dim s, t, IP As String
dim h As new HTTPSecureSocket

h.Secure = BoxUsingHTTPS // User decides
h.SetDreamboxLogin // login with name and password

if BoxUsingHTTPS then
t = "https://"
else
t = "http://"
end if

t = t + BoxIP + theURL
s = h.get( t ,ReturnTime )

Return s

End Function


This worked perfectly until now.
The receiver made an update of its OS (I don't no what they did) and the connection speed dropped down extremely. The processor reach nearly 100% (when using https)
When using http the speed is good as ever...

Other applications (that communicates with that box) seems not to have any problems, so there might be a way to fix this.

Does anybody know, how I can improve my code to come back to normal connection speed?

Any help is highly appreciated!


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Sun Jul 22, 2012 8:15 pm 
Offline

Joined: Thu Dec 02, 2010 10:17 pm
Posts: 75
I am also having speed issues with HTTPSecureSocket but I don't know the root of the cause. I have a really fast connection.


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Mon Jul 23, 2012 2:33 am 
Offline

Joined: Mon May 31, 2010 5:35 am
Posts: 2412
Location: Netherlands
trice wrote:
I am also having speed issues with HTTPSecureSocket but I don't know the root of the cause. I have a really fast connection.


Maybe the certificate authority is slow if the conn is secure.

_________________
SWORT™
- Windows Vista, Windows XP, Windows 7, Linux Mint 11 and Mac OSX Lion
- REAL Studio Enterprise(latest) and WEB Edition(latest)
- Plugins (MBS Complete, ToringoLib, Einhugur, VanHoek + Some open source plugins)
For Dutch User Groups ask me to enter!


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Mon Jul 23, 2012 2:55 am 
Offline

Joined: Fri Dec 01, 2006 9:39 pm
Posts: 180
I could solve my problem. The solution was quite simple by changing HTTPSecureSocket .ConnectionType
Everything is back to normal here. :)


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Mon Jul 23, 2012 12:53 pm 
Offline

Joined: Thu Dec 02, 2010 10:17 pm
Posts: 75
relaht wrote:
I could solve my problem. The solution was quite simple by changing HTTPSecureSocket .ConnectionType
Everything is back to normal here. :)


Was the problem you had that it was slow on some sites and fast on others?


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Mon Jul 23, 2012 1:02 pm 
Offline

Joined: Fri Dec 01, 2006 9:39 pm
Posts: 180
trice wrote:
Was the problem you had that it was slow on some sites and fast on others?

No, my application communicates with just one site. For details, please read my first post.


Top
 Profile  
Reply with quote  
 Post subject: Re: Problem with HTTPSecureSocket speed.
PostPosted: Mon Jul 23, 2012 1:07 pm 
Offline

Joined: Thu Dec 02, 2010 10:17 pm
Posts: 75
relaht wrote:
trice wrote:
Was the problem you had that it was slow on some sites and fast on others?

No, my application communicates with just one site. For details, please read my first post.


Sorry didn't notice you were the poster :) I did find that changing the connection type for certain sites is a lot faster but it didn't solve my other problem. Go ahead and try this

Dim nHTTPSecureSocket As New HTTPSecureSocket

Dim nJSONItem As New JSONItem

Dim Start As Integer=Ticks/60

nJSONItem.Load(nHTTPSecureSocket.Get("https://api.plivo.com/",0))

Dim Stop As Integer=(Ticks/60)-Start

Break


Once you try that then try to change the timeout of nHTTPSecureSocket to 1 and watch it return data right away


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group