Commit Graph

92 Commits

Author SHA1 Message Date
Risto Lahtela 4da7497d82
Player Hostname PieChart Added (#1679 #1786)
Affects issues:
- Close #783

Co-authored-by: Arnold Hamstra <youtube@minecraftercity.com>
Co-authored-by: Arnold <a_hamstra@hotmail.com>
2021-03-09 10:01:09 +02:00
Rsl1122 94c9dd3f95 Username change Rsl1122 -> AuroraLS3 2021-02-13 15:16:03 +02:00
Risto Lahtela 0769ddc3d4 Removed some unused variables I missed 2021-02-12 11:08:53 +02:00
Risto Lahtela 95af3f5f8b Removed JSONCache and its invalidation uses 2021-02-12 10:56:48 +02:00
Risto Lahtela b660c3b57b Moved JSON storage to delivery.webserver.cache 2021-02-10 13:11:12 +02:00
Risto Lahtela 3619ff814a JSON File storage clean task
- Cleans query files
- Cleans other json files that are old
2021-02-10 13:11:01 +02:00
Risto Lahtela aac7bdc632 Begun work on Filters:
- Filter interface
- Wrote 5 filters
- Wrote QueryFilters that manages different Filters

Plan is to link the QueryFilters to Resolvers:
- One that returns all filters and their options as json
- One that users the query parameters (eg ?q={json}) and gets the filters
  - FilterQuery has a static method to parse the json
2021-01-29 11:02:31 +02:00
Risto Lahtela 76fe304dbd Replaced old links to repository with new one 2021-01-29 09:51:44 +02:00
Risto Lahtela c8fb39ada5 Replaced TaskSystem implementations with dagger modules
- Removes the need for duplicate code in 5 places in charge of registering
  the tasks for different platforms, as all the delays were the same too.

Affects issues:
- Close #1387
2021-01-01 10:00:38 +02:00
Risto Lahtela 68ce65b4d5 Moved some abstraction of ImporterSystem to Dagger
Removes 2 unnecessary classes
2021-01-01 10:00:37 +02:00
Risto Lahtela 6292ef5f4d Extracted TestSettings utility 2021-01-01 10:00:36 +02:00
Rsl1122 6effdbec39 Full System no longer required for database tests
- Extracted ErrorLogger interface
- Created a new Component for Database tests
- Added TestAPFModule and TestSystemObjectBindingModule
- Database tests no longer enable the full system

Affects issues:
- Close #1401
2020-11-08 11:46:44 +02:00
Risto Lahtela 7420e46df2 Fixed SonarCloud code smells
- Redundancies:
  - MySQLDB: Removed null check
  - DeathEventListener: Removed warning suppression
  - several Test classes: Removed public class identifier
  - Unused private fields
- Constructors of abstract classes should be protected x31
- Added missing Parameterized types x2
- "throws" declerations for runtime EnableException
- Prevented Boxed Boolean from causing NPE in the future x15
- Renamed lesser scope variables that were hiding variables x12

- Some smaller ones that I was too tired to write down
2020-11-05 23:16:01 +02:00
Risto Lahtela 58e674badb Fixed velocity builder using wrong method for appending 2020-10-11 14:53:21 +03:00
Risto Lahtela eff5faba44 Improved code a bit for errors 2020-10-06 10:59:59 +03:00
Risto Lahtela 7087aa2f78 Removed old PlanCommand classes 2020-10-06 10:59:41 +03:00
Risto Lahtela 8939148f95 Fixed Confirmation by implementing equals & hashcode methods 2020-10-06 10:59:40 +03:00
Risto Lahtela a52e467e01 Register the nukkit messagebuilder 2020-10-06 10:59:39 +03:00
Risto Lahtela 007e5bf1fb Implemented Nukkit MessageBuilder
- Added CMDSender#supportsChatEvents because Nukkit players don't support
  hover or click events. This means that isPlayer method is not sufficient
  for finding out if the sender can produce these events.
2020-10-06 10:59:38 +03:00
Rsl1122 4699fd8af2 Implemented nukkit command adapter 2020-10-06 10:59:37 +03:00
Risto Lahtela 01fb4c7d84 Registered plan export command
- Fixed dagger compile error
- Fixed checkstyle errors
2020-10-06 10:59:32 +03:00
Risto Lahtela 42669b7367 Merged Manage disable to disable command 2020-10-06 10:59:31 +03:00
Risto Lahtela 03bfe28762 unfinished work commit 2020-10-06 10:59:23 +03:00
Risto Lahtela 93dc1bbb9e
Added more context to errors (#1450)
* Improved Extension errors
* Removed scary reflective operation exception
* Additional context to SQL Exceptions
* Added error context to Listeners
* Added error context to most error logging places
* Ignore cyclomatic complexity of DBOpException

Adds context to almost all error logging situations, except those where it is unknown, or to commands that are being refactored on another branch.

Close #1245
2020-05-15 12:20:29 +03:00
Risto Lahtela e53b9f1602 Replace ErrorHandler usage with ErrorLogger
This was done to get deprecation to show up where context is not
given to the error logger.
2020-05-14 16:57:29 +03:00
Risto Lahtela 24af980d39 More cleanup on placeholder classes 2020-05-01 10:49:55 +03:00
Risto Lahtela 4371595ccf Removed static usage from placeholders
- Dagger used to reduce the amount of method parameters.

Affects:
- #1404
2020-05-01 10:49:55 +03:00
Creeperface01 0066813c28 Refactor placeholders and add support for nukkit PlaceholderAPI (#1404)
by Creeperface01
2020-05-01 10:49:54 +03:00
Risto Lahtela d6a7a43428 Made CPU, RAM and Disk gathering async
Affects issues:
- Fixed #1364
2020-04-12 14:26:30 +03:00
Risto Lahtela 081f378135 Refactored Address based rules to a class
Affects issues:
- Fixed #1380
2020-03-28 11:51:11 +02:00
Risto Lahtela b339800650 Removed JUnit 4 2020-03-14 12:40:23 +02:00
Rsl1122 9c74c40f72 Renamed some Service related classes 2020-03-14 12:35:06 +02:00
Rsl1122 f0c252fbde Added Nukkit PlayerDeathEvent listener
EntityDeathEvent is not called for player

Added listener for PlayerDeathEvent that performs the expected behavior

Affects issues:
- Fixed #1314
2020-02-07 10:25:53 +02:00
Rsl1122 ae9ce49c43 Nukkit register date now uses seconds
Affects issues:
- Fixed #1320
2020-02-07 10:20:04 +02:00
Rsl1122 5d457223f8 Prevented null playerUUID from executing code
Affects issues:
- Fixed #1307
2020-02-04 11:17:13 +02:00
Rsl1122 c87f981d6a Rewrote TPSCounter Task
This commit is a squash of 8 optimization commits to TPSCounter.

1. Extracted duplicate code in TPSCounters to ServerSensors.

- TPSCounter tasks now live inside common module
  - ServerTPSCounter and ProxyTPSCounter
- Gathering methods are implemented with ServerSensor interface:
  Player count, TPS, Entity count, Chunk count
- ServerProperties#getOnlinePlayers was replaced with ServerSensor
- Fixed sonar smells: "Hiding field" in TPSStoreTransaction & NavLink

2. Optimizations down to 0.15ms / run

- Optimized entity+chunk count (same for loop)
- Added warm-up for system resource methods
- Removed Stream API usages
- Removed List copy operation
- Entities & chunks only count once per minute
- CPU & RAM averages now produced with Average class
- Maximum player count per minute now produced with Maximum class

Affects issues:
- Fixed #1289
2020-01-17 21:11:05 +02:00
Rsl1122 8a059ced0b Added SystemUsage class
This class is collection of some methods in TPSCounter that
were refactored out of it.
2020-01-17 21:11:05 +02:00
Rsl1122 8dcfd3ad9a Fixed new sonar smells
- Reduced constructor parameters in Exporter
- Removed Throwable#printStackTrace calls
- Cleaned up SessionsMutator#toJSONMaps a little
- Replaced uses of getString/Number/ methods of PlanConfig with PlanConfig#get
2020-01-17 21:11:04 +02:00
Rsl1122 16a5b41db5 Implemented new GeoLite2 & IP2C geolocators
- GeoLite2 downloads the file using License key, only if EULA is accepted
- Fallback to IP2C if GeoLite2 is not available
- Remove GeoIP.dat after successfully downloading GeoLite2-Country.mmdb
- Added case where geolocation fails to enable and doesn't cause issues

- Adds Apache commons-compress to the dependencies because of a tar archive

Affects issues:
- Fixed #1273
2020-01-17 21:11:02 +02:00
Rsl1122 732c7858d0 Fixing Sonar smells:
- Removed unused code in Reflection
- Removed duplicated Strings in GMTimes
- Added private constructor to TimeZoneUtility
- Renamed local variable in RegisterDateMinimizationPatch
- Replaced Function<String, Boolean> with Predicate in ExtensionRegister
- Changed AFKListeners to use primitive boolean
- Changed Config#get(Setting<Boolean>) uses to isTrue and isFalse
- comment to NukkitListenerSystem
2019-12-17 10:41:50 +02:00
Rsl1122 a1168ba749 Fixed some gradle issues 2019-12-08 11:30:53 +02:00
Risto Lahtela 2877fdc5ca
Implemented Nukkit Support (#1244)
- Implemented APF for Nukkit
- Copied Bukkit implementation and modified it for Nukkit
- Fixed SQLite not being present on Nukkit by switching to H2 on boot

Affects issues:
- Close #1020
2019-12-08 10:26:24 +02:00