CyberWorks-3 icon indicating copy to clipboard operation
CyberWorks-3 copied to clipboard

DataTable issue

Open Dunkstormen opened this issue 7 years ago • 6 comments

  • I'm submitting a ...
    • [x] bug report
    • [ ] feature request
    • [ ] support request

Please only submit the section relevant to what you are submitting.

Bug Report

  • What is the current behavior? When making a search on the "Players" page it would spit out an error using console.log stating that an error occured in DataTables (http://datatables.net/tn/7). When looking in the Network tab in the Developer Tools, I can see it reporting the error code 400 with the message "Failed CSRF check!"

  • What is the expected behavior? The expected behavior would be that it would finish it's query and display data matching the query.

  • Steps to reproduce?

    1. Sign into the panel
    2. Go to the "Players" page
    3. Type a search query in the search field.
  • Please tell us about your environment: Linux VPS running Ubuntu (16.04) [fully updated] PHP 7.0 Apache 2 MySQL (MariaDB 10.1.30)

  • Checklist

    • [x] Attached Relevant Logs
    • [x] Steps to reproduce
    • [x] Screenshots
  • Other information Error that gets displayed when searching: https://i.imgur.com/CucVItj.png https://i.imgur.com/SJwFW9s.png

Dunkstormen avatar Feb 17 '18 20:02 Dunkstormen

Was able to reproduce this slightly when internet connection is limited, will investigate further to implement solution.

cammygames avatar Feb 18 '18 15:02 cammygames

Just a bit curious, is there any progress regarding this issue?

Dunkstormen avatar Feb 26 '18 16:02 Dunkstormen

Not yet AFAIK its to do with CSRF checking and not noticeable with a good internet collection and fast DB server

MightySCollins avatar Mar 09 '18 14:03 MightySCollins

Been doing some thinking/research and have come to the conclusion that the problem may be in the connection between my VPS that is running the panel and our dedicated server.

Though the connections should be fast enoungh, I guess that the way packet has to travel has an impact on CSRF check.

Connection details: Dedicated server: 600Mbps/600Mbps (Located in DK) (Proxied with remote DDoS protection located in RO) Web server / VPS : 100Mbps/100Mbps (Located in NL) My own connection: 50Mbps/10Mbps (Located in DK)

I'll try get a VPS that can reach our DS over LAN and see if that resolves the issue. Will let you know when I've tried it out.

Dunkstormen avatar Mar 10 '18 14:03 Dunkstormen

UPDATE

System seems to be running faster now after I reinstalled my VPS, updated PHP to 7.1.15 and used the direct IP instead of proxied IP. Though issue still occurs when typing a search query fast in the search box. So I/we would need to wait for it to process in between each character when searching

Example: I want to find a player named "Steward Johnson". I go to the players page and start searching for him. Starting by pressing "S" and waiting about ½ a second for it to process, then continuing by pressing "T" and so on.

Dunkstormen avatar Mar 10 '18 16:03 Dunkstormen

If thats half fixed it I think your next problem is going to be your database. Is players a big table and is MySQL running well? Its still an issue but until we change how we do our entire CSRF system speeding up those requests should help/

MightySCollins avatar Mar 12 '18 11:03 MightySCollins