Maybe it depends on the object itself.
When you pass an object the .toString() method of that obj is invoked. I suspect that's where most of the time is spent. The trace() method uses log4j to log data, which is not that expensive in terms of cpu time.
Cheers
Search found 22668 matches
- 27 Jan 2024, 17:52
- Forum: SFS2X Questions
- Topic: trace(object) is extremely slow?
- Replies: 1
- Views: 589
- 27 Jan 2024, 07:38
- Forum: SFS2X Questions
- Topic: Message not sent from server / received by client due to data size?
- Replies: 1
- Views: 600
Re: Message not sent from server / received by client due to data size?
Hi, it would help to see an example of a message that doesn't go through. If you can identify one it would also help to try and reproduce the issue. In any case here are a couple of thoughts: 1- unless you're sending data via UDP (which requires a specific flag in the send() method) all packets are ...
- 26 Jan 2024, 16:54
- Forum: SFS2X Questions
- Topic: SSL for
- Replies: 6
- Views: 1018
Re: SSL for
Hi,
it depends on what level of security you want to achieve.
The basic level is to at least use SSL on the Lobby server to protect chat and user data. On Game cluster nodes it may be needed or not depending on what kind of data is transmitted.
Cheers
it depends on what level of security you want to achieve.
The basic level is to at least use SSL on the Lobby server to protect chat and user data. On Game cluster nodes it may be needed or not depending on what kind of data is transmitted.
Cheers
- 26 Jan 2024, 10:21
- Forum: SFS2X Questions
- Topic: SSL for
- Replies: 6
- Views: 1018
Re: SSL for
1. " if you need SSL the certificates": means that SFS2x works without SSL and the data is still safe? To protect the communication you will need to deploy an SSL certificate, as usual with every server. What is different is how the encryption is implemented compared to a regular web stac...
- 26 Jan 2024, 08:13
- Forum: SFS2X Questions
- Topic: SSL for
- Replies: 6
- Views: 1018
Re: SSL for
Hi, I don't think this setup would work. SmartFoxServer doesn't work like a regular web-server because it's based on a custom protocol on top of TCP and UDP. You can use a layer-4 load balancer but if you need SSL the certificates must be deployed on the SFS2X instances rather than the load balancer...
- 25 Jan 2024, 14:18
- Forum: SFS2X Questions
- Topic: How to reference a RoomExtension inside a normal zone from a global __lib__ extension?
- Replies: 2
- Views: 706
Re: How to reference a RoomExtension inside a normal zone from a global __lib__ extension?
If you need direct interaction between Room and Zone Extensions and the Zone Extension is already deployed in the top class loader (__lib__), I would just suggest to also deploy the Room Extension there.
Cheers
Cheers
- 23 Jan 2024, 08:10
- Forum: SFS2X Questions
- Topic: dbManager automatically handle disconnections?
- Replies: 2
- Views: 767
Re: dbManager automatically handle disconnections?
Hi, connections to the database are normally run in a local network so disconnections are highly unlikely. If you get disconnected in the middle of a DB transaction you will get a SQLException. Is it any problem if I run multiple functions in a row with dbManager like this? No it's not a problem. Is...
- 22 Jan 2024, 08:04
- Forum: SFS2X Questions
- Topic: Dropped outgoing messages and a client's consistency
- Replies: 11
- Views: 12705
Re: Dropped outgoing messages and a client's consistency
Hi, there isn't an equivalent option in SFS2X as the original feature in SFS PRO was rarely (if ever) used. In theory making the server intolerant to packet drops would result in a worse user experience, since players with a slow/bad connection would also start disconnecting more often. Generally sp...
- 19 Jan 2024, 17:31
- Forum: SFS2X Questions
- Topic: Keeping ServerTime in milliseconds?
- Replies: 1
- Views: 788
Re: Keeping ServerTime in milliseconds?
Hi, a millisecond resolution for the uptime doesn't make sense. I was thinking to just use System.currentTimeMillis(); which returns a long milliseconds, depending on system time. Yes that's correct. It uses System Time, and SFS doesnt have built in server time? No, you can obtain the server time di...
- 17 Jan 2024, 16:07
- Forum: SFS2X Questions
- Topic: Correct way to reference/call shared extensions that reside in __lib__ folder?
- Replies: 5
- Views: 1149
Re: Correct way to reference/call shared extensions that reside in __lib__ folder?
The ChatGPT example makes no sense :shock: :D Interop with Extension can be tricky because they are segregated in different class loaders. To avoid class loader headaches we have introduce the simple "message" system where you invoke the handleInternalMessage() method. I would just recomme...
- 17 Jan 2024, 13:15
- Forum: SFS2X Questions
- Topic: Hook into Connect before Login
- Replies: 3
- Views: 980
Re: Hook into Connect before Login
Hi,
no sorry there isn't a mechanism to invoke Extension prior to having logged in. It would open a whole pandora's box of security exploits and attacks.
The only allowed interaction is the login request.
Cheers
no sorry there isn't a mechanism to invoke Extension prior to having logged in. It would open a whole pandora's box of security exploits and attacks.
The only allowed interaction is the login request.
Cheers
- 16 Jan 2024, 14:57
- Forum: SFS2X Questions
- Topic: Logout users from databse, cannot get data because user and session already destroyed?
- Replies: 6
- Views: 12200
Re: Logout users from databse, cannot get data because user and session already destroyed?
I would start by checking the logs and looking for exceptions. If the postProcess class is not invoked I'd expect some error to prevent it from running.
Cheers
Cheers
- 15 Jan 2024, 08:32
- Forum: SFS2X Questions
- Topic: Firebase cloud messenging problems
- Replies: 4
- Views: 11000
Re: Firebase cloud messenging problems
May I ask why it doesn't work for deployment? We tried that, but sadly it is not good for deployment, are there any plans to upgrade the jackson jar files from your side? Not at the moment. We have plans to transition to Java 21 LTS at some point and we'll likely have to update a number of dependenc...
- 15 Jan 2024, 08:10
- Forum: SFS2X Questions
- Topic: Firebase cloud messenging problems
- Replies: 4
- Views: 11000
Re: Firebase cloud messenging problems
Hi, I am not familiar with either of those sdks. It is possible that there's a jar conflict and you should be able to ascertain it by checking which version are the "colliding" jar files. If either of those sdks contain more recent versions of the jackson parser then I'd suggest to try and...
- 15 Jan 2024, 08:06
- Forum: SFS2X Questions
- Topic: Logout users from databse, cannot get data because user and session already destroyed?
- Replies: 6
- Views: 12200
Re: Logout users from databse, cannot get data because user and session already destroyed?
Hi,
from your snippets it looks like you're handling the USER_DISCONNECT event.
The event passes a bunch of parameters, one is the User itself, from which you can obtain the name:
I am not sure what's the need for the workaround you have described.
Cheers
from your snippets it looks like you're handling the USER_DISCONNECT event.
The event passes a bunch of parameters, one is the User itself, from which you can obtain the name:
Code: Select all
String name = user.getName()
I am not sure what's the need for the workaround you have described.
Cheers