I cannot see the issue on your example AdvanceCaht because
if i restart the server while client is logged in,
the client goes on :
** Socket connection failed. Trying BlueBox **
[ Send ]: connect
Error opening URL "http://127.0.0.1:8080/BlueBox/HttpBox.do"
and it doesn't seem to moove from that position when the server is started up again.
the problem I have is not this, by the way....
the problem is that when i connect again (and I do that attempting reconnection every X seconds if disconnected) ANY KIND of function to call the server DO NOT WORK !!!
this after having installed 1.6
this problem was not on 1.5 !!! it was perfectly working.
I'm trying to empty the project to provide you my login function, because filled with many not usefull things.
smartConnect not working on sfs 1.6
** Socket connection failed. Trying BlueBox **
[ Send ]: connect
Error opening URL "http://127.0.0.1:8080/BlueBox/HttpBox.do"
This can be normal if the connection attempt is done right after the server has been restarted. In fact it takes 10-20 seconds (or more depending on your extension) before the server comes back again.
The socket connection would fail anyways and the bluebox does too.
If you take an older version of the server you'll notice the same problem. If you attempt a connection immediately after a disconnection it may fail due to the fact that the server is not ready yet.
The AS 2.0 API have a parameter called socketConnectionTimeout which controls how much time the client should wait before trying the BlueBox connection.
Defualt value is 5000ms. (5 seconds).
If you raise this to 10-15 you will probably be able to reconnect between server restarts... if the server comes back within that time.
Btw, you didn't tell me what is happening when you kick the user or use the exit button. This is related with the problem you mentioned: reconnecting within the same application instance.
I try reconnection every x seconds after disconnection, and I always get (when the server is on again) the domain policy etc...
so it communicates regularly with the server.
i think i must be more clear about the problem:
in case BB is ON and i'm NOT under proxy:
i connect 1° time on socket and it's ok (i log in, play etc...)
then i stop the server.
When the connection is newly established the client reconnects via bluebox, also if I'm not firewalled or proxied. It should go on proxy
this is problem 1
then being on BB if the server stops the disconnection is not detected by client.
this is problem 2
so i have turn it off (bad because it could be very useful)
in case BB is off (by setting smartConnect= false;) always without proxy.
i connect 1° time on socket and it's ok (i log in, play etc...)
then i stop the server.
When the connection is newly established the client seems to reconnect perfectly, but any action performed calling the server (starting with login) is not answered by the server !
this is problem 3
--------------------------------------------
i sent you an email with my fla.
flash8
as2
thanks
so it communicates regularly with the server.
i think i must be more clear about the problem:
in case BB is ON and i'm NOT under proxy:
i connect 1° time on socket and it's ok (i log in, play etc...)
then i stop the server.
When the connection is newly established the client reconnects via bluebox, also if I'm not firewalled or proxied. It should go on proxy
this is problem 1
then being on BB if the server stops the disconnection is not detected by client.
this is problem 2
so i have turn it off (bad because it could be very useful)
in case BB is off (by setting smartConnect= false;) always without proxy.
i connect 1° time on socket and it's ok (i log in, play etc...)
then i stop the server.
When the connection is newly established the client seems to reconnect perfectly, but any action performed calling the server (starting with login) is not answered by the server !
this is problem 3
--------------------------------------------
i sent you an email with my fla.
flash8
as2
thanks
i have the same problem but with as3
this is the error
cannot load data from
http://127.0.0.1:8080/BlueBox/HttpBox.do.
at it.gotoandplay.smartfoxserver.http::LoaderFactory()
at it.gotoandplay.smartfoxserver.http::HttpConnection()
at it.gotoandplay.smartfoxserver::SmartFoxClient()
this is the error
cannot load data from
http://127.0.0.1:8080/BlueBox/HttpBox.do.
at it.gotoandplay.smartfoxserver.http::LoaderFactory()
at it.gotoandplay.smartfoxserver.http::HttpConnection()
at it.gotoandplay.smartfoxserver::SmartFoxClient()
0jes. - Jose Jimenez
In order for us to check these issues we need all the details.
Please read the posting rules -> viewtopic.php?t=3307
Thank you
Please read the posting rules -> viewtopic.php?t=3307
Thank you
I am adobe AIR (Flex) developer with FMS background and new to SFS I have just downloaded the 1.6.6 and trying out the samples.
While I was exploring SFSTemplate(flex) example and using the action script code to my custom AIR application (I was able to compile & run my application successfully) I found the SmartFoxClient.logout() is not working correctly.
When I invoke logout for the first time it works and I receive
[ RECEIVED ]: <msg t='sys'><body action='logout' r='0'></body></msg>, (len: 54)
But without quitting the application if I connect again and try to log out nothing happens
All I can see is
[Sending]: <msg t='sys'><body action='logout' r='-1'></body></msg>
sfs.isConnected returns true even after invoking sfs.logout() and the listener function [sfs.addEventListener(SFSEvent.onLogout, onLogout);] onLogout never invokes.
Can you let me know what is going wrong ?
While I was exploring SFSTemplate(flex) example and using the action script code to my custom AIR application (I was able to compile & run my application successfully) I found the SmartFoxClient.logout() is not working correctly.
When I invoke logout for the first time it works and I receive
[ RECEIVED ]: <msg t='sys'><body action='logout' r='0'></body></msg>, (len: 54)
But without quitting the application if I connect again and try to log out nothing happens
All I can see is
[Sending]: <msg t='sys'><body action='logout' r='-1'></body></msg>
sfs.isConnected returns true even after invoking sfs.logout() and the listener function [sfs.addEventListener(SFSEvent.onLogout, onLogout);] onLogout never invokes.
Can you let me know what is going wrong ?
But without quitting the application if I connect again and try to log out nothing happens
Connection and LogIn are two different things.
The connection takes care of the socket connection between your client and server. The login process allows your client to join one of the Applications running in the server.
If you log in Zone A and then logout you are still connected.
All you need to do is performing a new login in a new Zone.
Hi,
I'm so new at SFS and I thought the problem mentioned in this topic is so similar with mine. So I decided to write here.
I installed SFS Pro on my machine -WindowsXP- working for about 3 weeks on it. But I could never make a socket connection with server for now. I can only connect with BB. I disabled the firewall, and tested the port via Telnet if it's open. All seems ok but, i couldn't find how to make a socket connection with server. I read almost all the similar topics in forum.
I'm using custom login on my extension but, the example files can't connect with socket too.
What am I doing wrong?
I'm so new at SFS and I thought the problem mentioned in this topic is so similar with mine. So I decided to write here.
I installed SFS Pro on my machine -WindowsXP- working for about 3 weeks on it. But I could never make a socket connection with server for now. I can only connect with BB. I disabled the firewall, and tested the port via Telnet if it's open. All seems ok but, i couldn't find how to make a socket connection with server. I read almost all the similar topics in forum.
I'm using custom login on my extension but, the example files can't connect with socket too.
What am I doing wrong?
Telnet connects if I write "Telnet 127.0.0.1 9339" but it doesn't connect if I write "Telnet 127.0.0.1 5339 -or something else-".
I figured it out by the way. I disabled the firewall of the router and It connects now. I still don't understand why Telnet connects before but I don't care
Thanks for reply...
I figured it out by the way. I disabled the firewall of the router and It connects now. I still don't understand why Telnet connects before but I don't care
Thanks for reply...
Who is online
Users browsing this forum: No registered users and 28 guests