[SEC/MECH/FUN] PreciousStones - Block Area Proteciton System [BukkitDev]

Discussion in 'Archived: Plugin Releases' started by phaed, Jan 18, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    phaed

  2. Offline

    Kaosvf

    Hi,
    I have a suggestion, why don't you add the flag that a block can't be placed more than one in X minutes? (With the bypass permission for the admins).
    Kaos
     
  3. Offline

    staniboy

    hm size problem is gone but now my protection field makes me jump....canon effect
    edit: nevermind....for some reason i got canon: true in config....never used it...

    /ps visualize and the tool group(to see if land is protected) seems to be not working with just preciousstones.benefit.* however works fine for admin group...(node "*")

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 6, 2016
  4. Offline

    thefoxygranpa

    http://pastebin.com/M0qk0887

    Check that out....all the good stuff is at the bottom. That's where all the server was doing was sending queries, over and over and over, nothing else. Read time out for all my users.

    At the top of the log you'll see the server was running okay for a little bit, then started to slow down and then eventually just keep saying;

    2011-07-12 13:35:20 [INFO] [Queue] processing 1 queries...
    2011-07-12 13:35:20 [INFO] [Queue] done.


    Edit: My saving part of the config;
    Code:
    saving:
        frequency-minutes: 120
        saving-frequency-minutes: 120
        database-update-seconds: 15
     
  5. Offline

    phaed

    Ok. re-download 5.1.1. Now its batching before sending, this is the only thing the saving part of your config should have:
    Code:
    saving:
        batch-size: 35
    
    This is how many queries it sends to the database at one time, try different ranges to see if that helps. Try something really large, so it wont save for a while, to see if its the saving that's causing this or something else.

    Use /ps debug to check out your output.
     
  6. Offline

    thefoxygranpa

    I threw it in for a bit.....server got hung up after a certain amount of time, i used the default 35 batch size. Unforunately I got to run out so I'll be back later to test it out some more.

    Oh and got a severe error form PS on the newest version "511b" :p

    Code:
    2011-07-12 14:26:28 [SEVERE] Could not pass event PLAYER_INTERACT to PreciousStones
    
    java.lang.NullPointerException
    
            at net.sacredlabyrinth.Phaed.PreciousStones.managers.ForceFieldManager.isAllowed(ForceFieldManager.java:665)
    
            at net.sacredlabyrinth.Phaed.PreciousStones.managers.ForceFieldManager.isAllowed(ForceFieldManager.java:677)
    
            at net.sacredlabyrinth.Phaed.PreciousStones.listeners.PSPlayerListener.onPlayerInteract(PSPlayerListener.java:197)
    
            at org.bukkit.plugin.java.JavaPluginLoader$10.execute(JavaPluginLoader.java:307)
    
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
    
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:321)
    
            at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:168)
    
            at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:210)
    
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:552)
    
            at net.minecraft.server.Packet15Place.a(SourceFile:57)
    
            at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
    
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:84)
    
            at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
    
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
    
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
    
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    
    2011-07-12 14:26:28 [INFO] [ChestShop] jesterdom bought 64 REDSTONE for 18.0 from NapaseT
    
    2011-07-12 14:26:28 [INFO] [g] <VIP:BlackKnights>Stuu: 1 minute
    
    2011-07-12 14:26:31 [SEVERE] Could not pass event PLAYER_INTERACT to PreciousStones
    
    java.lang.NullPointerException
    
            at net.sacredlabyrinth.Phaed.PreciousStones.managers.ForceFieldManager.isAllowed(ForceFieldManager.java:665)
    
            at net.sacredlabyrinth.Phaed.PreciousStones.managers.ForceFieldManager.isAllowed(ForceFieldManager.java:677)
    
            at net.sacredlabyrinth.Phaed.PreciousStones.listeners.PSPlayerListener.onPlayerInteract(PSPlayerListener.java:197)
    
            at org.bukkit.plugin.java.JavaPluginLoader$10.execute(JavaPluginLoader.java:307)
    
            at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:58)
    
            at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:321)
    
            at org.bukkit.craftbukkit.event.CraftEventFactory.callPlayerInteractEvent(CraftEventFactory.java:168)
    
            at net.minecraft.server.ItemInWorldManager.interact(ItemInWorldManager.java:210)
    
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:552)
    
            at net.minecraft.server.Packet15Place.a(SourceFile:57)
    
            at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
    
            at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:84)
    
            at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
    
            at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:451)
    
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:361)
    
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    
    
     
  7. Offline

    Kaosvf

  8. Offline

    jonDatz

  9. Offline

    phaed

    Oh, that's a way old version that didn't support SQLite.
     
  10. Offline

    staniboy

    This is happening to me when i trying to get protection status of block with predefined tools....
     
  11. Offline

    jonDatz

    Gah, overlooked version number, must've uploaded old jar. my apologies. Thanks for the help
     
  12. Offline

    lycano

    Cool SQLite support! I really did need this. And welcome back ^^
     
  13. Offline

    Leon Philips

    Is there an command to Activate a block when pointing at it [After placing it as last block]
    becouse on my server we use some of those blocks as decoration and it would be a shame
    if we couldnd use that block anymore... and does it support multiworld?? (i coulnd find this sorry if I ask thing's twice)

    Thanks, :p
     
  14. Offline

    staniboy

    There is a command that turns PS off "/ps off" so u can place just a regular stones and "/ps on" to get ability to place field blocks.... also in config file there is an option for ps to be on or off on log in
     
  15. Offline

    thefoxygranpa

    You can use /ps off. This will set it so any blocks you place that are also PStones won't be made pstones. When you're ready to place pstones again type /ps on and you're set :)
     
  16. Offline

    phaed

    Yes, its already been fixed, will be out on next version. Its harmless tho, so you can safely ignore it for now.
     
  17. Offline

    Leon Philips

    okay great thx :)
     
  18. Offline

    thefoxygranpa

    Hey,

    Check this pastebin out, [ It's lengthy :\ ]

    http://pastebin.com/5jN3BrrP

    This is with batch size set to 100. It was working okay for a little bit, then started to get a little jittery, then slowly came to a stop and RTO'd my users. Anything else I should try out?
     
  19. Offline

    staniboy

    Is this a common problem for everyone or certain big servers only?
     
  20. Offline

    thefoxygranpa

    It seems to be isolated for servers with a large amount of pstones *i think* . We're pushing 100,000 fields, with users constantly deleting and placing them.
     
  21. Offline

    phaed

    Up to now, you are the only server who has had this problem that I have heard of. With the massive amounts of pstones you have you are now encountering bottlenecks other servers don't have to deal with and which I haven't needed to address til now. I am working on a much optimized db saving setup, with partial saves, and grouping redundant saves. For example if the save frequency is 5 minutes, and someone triggered 200 snitch alerts on one field in that time frame, instead of making 200 db calls, it would just make 1 with all the changes included. Also instead of saving the whole field with all the columns (name, radius, allowed players, etc), it would just update that one packed_snitchlist column. Will release most likely tonight.
     
  22. Offline

    Bronski

    With these batches, can I assume that if you do save-all or stop in the console that any pending ones are pushed out?

    Also, I was running the bad version for at least a full day. Is there anything I need to check regarding existing stones and/or the database tables? I don't know what the 'bad' thing was but I have to ask now in case I need to start dipping into backups. Thanks.
     
  23. Offline

    phaed

    Yes of course, on plugin unload all pending queries get processed.

    No new version puts everything back to normal. With 5.0.6 you may have gotten reports of ppls fields being larger than they actually were. /ps info also showed fields of the general area not just the ones that you were standing on, and launchers/cannons/give-air stopped working. Nothing had actually changed, just the reporting of it had. All due to a function being used that was checking fields in the area rather than fields in the area that were affecting a certain spot.
     
  24. Offline

    Latros

    Keep workin' away at it Phaed, I anxiously await your update so we can test it.
     
    thefoxygranpa and staniboy like this.
  25. Offline

    Leon Philips

    I dont know how github works in commenting ect...
    but i found an bug -> PSlapis doesnt work that well when you walk slow
    you can just walk trough is there an way to TP you when inside the range?
     
  26. Offline

    Kaosvf

    Do you suggest to change them?
     
  27. Offline

    phaed

    Change log
    Version 5.2
    • Partial saves, no more sending the entire field up to save with the snitch list and allowed players and everything else when only the height has changed.
    • No more redundant db updates, a snitch recorded 200 blocks breaking and 15 people entering in between the save-frequency period, it wont send 215 queries to the db, it will send one with the final version.
    • Added: Allows you to set the maximum amount of records a snitch can hold, to prevent enormously huge abandoned snitches which take forever to send up to the db. oldest record is removed when a new one does not fit.
    • New save settings:
      saving:​
      frequency-seconds: 300​
      batch-size: 100​
      max-records-per-snitch: 50​
    • Added: /ps debug to dump event timing info to the console
    • Added: /ps debugdb to dump a summary of the batch sending of queries to console
    • Added: /ps debugsql to dump the actual sql queries themselves to console (very verbose)
    • Fixed: entry-alert was alerting the entry of any player, now only alerts when those who are not allowed enter
    • Fixed: preciousstones.admin.visualize players now no longer see partitions in between overlapped fields
    • Fixed: /ps setowner giving syntax error bug
     
  28. Offline

    staniboy

    hm...so /ps visualize not included in benefit node anymore? mine is red in the list when i /ps
     
  29. Offline

    phaed

    Ah, let me fix. Copy/paste mistake.

    Edit: Re-download 5.2
     
  30. Offline

    thefoxygranpa

    Phaed! Need assistance, I dropped the packed_snitch_lists table and need to recreate it, otherwise I get massive errors on start.

    Have you a query I could use :( ?
     
  31. Offline

    Bronski

    Following along with you again hehe.

    Oh, I see this in the log at startup:

    Severe errors are severe? I'm using GroupManager with the fakey bridge thing.
     
Thread Status:
Not open for further replies.

Share This Page