Server side of the InstantScore project
llaki / instantscore Goto Github PK
View Code? Open in Web Editor NEWServer side of the InstantScore project
Server side of the InstantScore project
Change every System.out.println
to java.util.logging
methods
Sometimes we send more than one message to the user, which is not desired.
When we choose a future match, the functionality does not work.
Some parts of the code are unused, they should be removed.
The file containing the data is saved without providing the directory path that should contain the file. The result is:
Linux: \usr\share\tomcat7\scores
Windows: D:\eclipse_enterprise\scores
The result is java.io.FileNotFoundException
when running Linux code on Windows.
The code should be platform-independent.
If the user submits the same data multiple times, the subscription record should be kept only once.
My opinion: submitting user data causes IOException. Server code can't handle client requests.
scores writing... done writing TEST GETTING MATCH INFOS... scores CHANGES TO GOINT MATCHES BEING INVOKED... writing... IOException done writing scores scores IOException done writing TEST GETTING MATCH INFOS... scores CHANGES TO GOINT MATCHES BEING INVOKED... writing... writing... IOException done writing scores scores IOException done writing TEST GETTING MATCH INFOS... scores CHANGES TO GOINT MATCHES BEING INVOKED... writing...
When the server is down, application stops working automatically. We should instead show the message that the server is down or something like that.
Android users will get match list with their local time. Think the solution. Where should the time be converted: server or user side.
We are having lots of non necessary logs. We can remove at least some of them, or log them into special file which gets cleared sometimes (for example, we can always delete the logs that have been generated 2 days ago).
The names of some classes should not be changed, because in some cases the name doesn't really correspond to what the class is really responsible for.
When server stops working, we should save the existing data somewhere. In current code, the users may have already chosen some matches, then the server has failed and on restart the previous data are lost. The users are still waiting for messages as they've registered, but they won't get anything. This scenario should be impossible.
As a solution, we might have a separate file where we save the necessary information. If the server breaks and then we restart it, we should be able to recover the data from that file.
In the current code, after each refresh of the livescore page, we copy all existing matches (together with their users, so it can be potentially a really large data). That can cause problems when we'll have a large amount of users.
If the match ends in penalties, we're missing the last message that notifies the final winner of the game.
User subscribed to match A. Later he sends data that does't contain match A. The user should be removed from the subscription list for math A.
Currently the code assumes only one user. The getPhoneNumber() method inside the user is "STUB" and always returns the same (my :) ) phone number. We should definitely change this later so that multiple users can use our service.
com.twilio.sdk.TwilioRestException: The 'To' number +null is not a valid phone number.
at com.twilio.sdk.TwilioRestException.parseResponse(TwilioRestException.java:74)
at com.twilio.sdk.TwilioRestClient.safeRequest(TwilioRestClient.java:589)
at com.twilio.sdk.resource.list.MessageList.create(MessageList.java:70)
at twillio.Twilio.send(Twilio.java:44)
at securitycode.CodeGenerator.sendSecurityCodeToUser(CodeGenerator.java:36)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.