[INACTIVE][ADMN] PetitionPlugin v1.34 - Help ticket system [600-818]

Discussion in 'Inactive/Unsupported Plugins' started by FloydATC, Jan 20, 2011.

  1. Offline

    FloydATC

    This plugin is used for players to log problems, requests and complaints. This plugin relies on Permissions.jar for access control. This will ofcourse be changed once permissions are properly implemented in Bukkit.

    The source code is included in the .jar file, feel free to do whatever you want with it. If you use it to save the universe, credits would be nice.

    Features:
    • Players may open one or more petitions and get assigned a unique ticket # for each. This number can be used to track the petition until it has been closed.
    • Each petition may be assigned to a specific op/admin or left as unassigned
    • Players as well as ops/admins may add comments to an open petition
    • Ops/admins (and currently players) may warp to the location where the petition was opened
    • Ops/admins (and currently players) may review the history of each open petition
    • Closed petitions are archived and can be reviewed or reopened by moderators
    • Use the command "/petition" or the shorthand command "/pe". These can be reconfigured if you want. Option to change these was removed in v1.20, sorry.
    • All commands are case-insensitive
    • New and updated petitions are announced to everyone with 'petition.moderate' permission
    • Want to call them something else than petitions? This can be configured.
    • Supports multiple worlds
    • Offline players receive notifications on petition updates when logging in
    • Server admins can handle petitions on the server console
    • Players and moderators are reminded of their open petitions at configurable intervals
    Command syntax
    Code:
    /pe open|create|new <Message>
    /pe comment|log <#> <Message>
    /pe close <#> [<Message>]
    /pe list [<count>]
    /pe view <#>
    /pe assign <#> [<Operator>]
    /pe unassign <#>
    /pe warp|goto <#>
    
    Note that the command/alias "/pe" can no longer be changed by the server administrator.

    How to install
    1. Download http://minecraft.atc.no/plugins/PetitionPlugin.jar
    2. Copy it to your "plugins" directory
    3. Optionally create a new directory called "plugins/PetitionPlugin"
    4. Optionally create a new directory called "plugins/PetitionPlugin/archive"
    5. Optionally create a new file "plugins/PetitionPlugin/settings.txt"
    6. Load the plugin (Restart the server, or use any plugin you have for this purpose)
    Settings
    The configuration file is optional, the following settings are available:
    Code:
    single=Petition
    plural=Petitions
    notify-all-on-close=false
    notify-owner-on-assign=true
    notify-owner-on-unassign=true
    notify-interval-seconds=300
    warp-requires-permission=false
    Command examples
    A player in distress:
    Code:
    /pe open Someone has burned down my home!
    # the player receives a ticket number, say 45 for this example
    /pe comment 45 And killed my chicken!
    
    The brave (but slightly insensitive) administrator arrives:
    Code:
    /pe list
    # the plugin shows me a list of currently open petitions
    /pe assign 45 FloydATC
    # the petition status is changed to show that I am now handling this incident
    /pe warp 45
    # I am teleported to the scene
    /pe comment 45 Nice crater
    /pe close 45 Feather refunded, have a nice day
    # +1 served
    
    Again, note that the command/alias "/pe" can be changed by the server administrator.

    Changelog:
    v1.00 - Original release
    v1.01 - Rebuild (fixed onPlayerCommand issue)
    v1.02 - Implemented locking and permissions
    v1.03 - Added notifications and colors, and fixed a stupid permission bug
    v1.04 - Fixed a few problems with notifications, added more colors.
    v1.05 - Command/alias can now be configured. More colors.
    v1.06 - Fixed crash bug when closing without a comment. Added optional notifications on assign/unassign.
    v1.07 - Improved error-checking. Players may now list/close/comment/view/warp to their own petitions.
    v1.08 - Automatically create necessary directories and files if they don't exist
    v1.10 - A few cosmetic fixes + petition length in header
    v1.11 - Added experimental support for multiple worlds
    v1.12 - Changed to use world name instead of ID
    v1.20 - Rewrote to use onCommand(), fixed /pe warp security issue + much more.
    v1.21 - Removed the "stupidly long constructor" as per Bukkit team recommendation
    v1.22 - Implemented a notification system for offline players, admins and operators
    v1.23 - Fixed duplicate messages. Commands now work from the server console.
    v1.24 - Added optional setting to limit use of warp. Petitions are now almost listed in correct order.
    v1.25 - Fixed null pointer error on player join.
    v1.26 - Petitions are now listed in correct order. Finally.
    v1.27 - Optional online/offline filter to /pe list implemented.
    v1.28 - Non-moderators could assign/unassign their petitions. Fixed.
    v1.30 - Closed petitions may be viewed and reopened. Added list filters "closed", "unassigned", "newest" plus Regular Expression matching.
    v1.31 - The list would always get reversed. Fixed.
    v1.32 - Notification thread implemented, remind users and mods at regular intervals.
    v1.33 - Changed onPlayerJoin() as required by build #600. Fixed deprecated call to void teleportTo().
    v1.34 - Added option to notify all players when a petition is closed, not just the moderators.

    Dependencies:
    • Requires the Permissions plugin (2.6 or equivalent required) Use other versions or compatible plugins at own risk.
    Permissions
    • 'petition' required to open, comment and view a petition
    • 'petition.warp-to-own' required IF 'warp-requires-permission' is enabled
    • 'petition.warp-to-own-if-assigned' required IF 'warp-requires-permission' is enabled
    • 'petition.moderate' required for everything else
    Known problems
    Certain situations can lead to double notifications, such as an operator commenting on his own petition. Colorization is work-in-progress.

    I'm a Java newbie, please be gentle.
    Thank you :)
     
    DJdur, Phaedrus, kahlilnc and 3 others like this.
  2. Offline

    MJRamon

    @FloydATC
    What about MySQL support? It would be much better to use (web interface for admins)
     
  3. Offline

    Xemnas33

    As said before :)

     
  4. Offline

    MJRamon

    Oh, shame on me. Have to be more attentive.
     
  5. Offline

    pyros

    Hmm seems petition output an error earlier that crashed my server (or is a result of an unreported error), hard for me to tell
    I presume nonactive petitions arent loaded? I imagine if they were, the 500-odd on my server could cause some kind of ourofmemory bug, but I have no experience in coding plugins or java so it is not for me to know
    Code:
    15:07:47 [INFO] Connection reset
    15:07:54 [INFO] Connection reset
    15:08:00 [INFO] Read timed out
    15:08:30 [INFO] Connection reset
    15:09:34 [INFO] Connection reset
    15:11:34 [SEVERE] Exception in thread "Thread-6925"
    15:11:51 [SEVERE] java.lang.OutOfMemoryError: Java heap space
    15:14:39 [SEVERE]       at java.io.BufferedReader.<init>(BufferedReader.java:97)
    15:15:06 [SEVERE]       at java.io.BufferedReader.<init>(BufferedReader.java:108)
    15:15:41 [SEVERE]       at com.floyd.bukkit.petition.PetitionObject.<init>(PetitionObject.java:69)
    15:15:50 [SEVERE]       at com.floyd.bukkit.petition.NotifierThread.run(NotifierThread.java:49)
    15:16:21 [SEVERE] Exception in thread "Listen thread"
    15:16:52 [SEVERE] java.lang.OutOfMemoryError: Java heap space
    15:17:19 [SEVERE]       at java.io.BufferedOutputStream.<init>(BufferedOutputStream.java:76)
    15:17:25 [SEVERE]       at net.minecraft.server.NetworkManager.<init>(NetworkManager.java:52)
    15:17:42 [SEVERE]       at net.minecraft.server.NetLoginHandler.<init>(NetLoginHandler.java:21)
    15:18:19 [SEVERE]       at net.minecraft.server.NetworkAcceptThread.run(SourceFile:53)
    15:18:30 [SEVERE] java.lang.OutOfMemoryError: Java heap space
    15:19:10 [SEVERE]       at net.minecraft.server.AxisAlignedBB.a(SourceFile:11)
    15:19:10 [SEVERE]       at net.minecraft.server.AxisAlignedBB.b(SourceFile:25)
    
    Xemnas33 said:
    There is development going on, we're just at a slow pace at the moment due to real life matters. If you want to make any pull requests there is a github.

    I believe our main aim for the next release is to add mysql support.​

    Is there a link to the github?

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

    Xemnas33

    https://github.com/FloydATC/Bukkit-PetitionPlugin

    How much ram is the server running with?
     
  7. Offline

    pyros

    2GB

    Also, is it possible to get the petition thread number when writing a script in commandhelper?
    I was thinking of making an addon script for tags on petitions (Id look into it for java but have no experience in coding it)
     
  8. Offline

    FloydATC

    The plugin does not keep any information about petitions in memory. I am not aware of any memory leaks in the plugin itself. There is no free() call in Java so the most common way to leak memory is to create a circular pointer reference, i.e. two or more objects that refer to eachother. PetitionPlugin has no complex data structures under the hood so this should be irrelevant.

    What I do know is that Java has a problem with garbage collection in general. When the system is under heavy load, the garbage collector thread isn't always able to keep up and so the memory manager runs out of heap space even though there are lots of objects no longer in use. The solution is to add more RAM and more CPU, or give garbage collection threads higher priority at the expense of user threads.
     
  9. Offline

    gamer1129

    Hey Floyd. I love your plugin, very useful for a ton of things and now i don't have to call up by friends to ask what they were talking about, I just go to the petition. Epic plugin. But, whenever my friends try to go to another persons petition, it wont work.... I have tried every configuration, I have given them all the permissions listed, I am still the only one who can go to every petition. How is this so? Is there a mystery permission node you didn't include or something? Is there currently a way for me to allow them to go to any petition?
     
  10. Offline

    xZise

    Is it possible to add a vote system for each petition? Especially the public petitions would be nice, if the users could vote for this. I'm working on a voting plugin at the moment, maybe I could add an API, so you could call the plugin to manage the vote.

    Fabian
     
  11. Offline

    FloydATC

    Hmm these should do the trick, as listed in the OP:

    Permissions

    • 'petition' required to open, comment and view a petition
    • 'petition.warp-to-own' required IF 'warp-requires-permission' is enabled
    • 'petition.warp-to-own-if-assigned' required IF 'warp-requires-permission' is enabled
    • 'petition.moderate' required for everything else
    To clarify, moderators should be able to view and warp to any petition. There is no special permission just for warping to any petition.
     
  12. Offline

    gamer1129

    No matter what I do, give them the mod permission, adjust the settings, take the petition.warp-to-own or whatever nothing I do will allow anyone below my rank to goto anything else than their own, is there something I am doing wrong?
     
  13. Offline

    ANTlabs

    I love this plugin, but the download link is broken!
     
  14. Offline

    dak393

    Yes, please update :) love the plugin
     
  15. Offline

    Xemnas33

    I think the server must be dead or something... i'll try uploading the jar if not I will provide a dropbox link.

    This plugin ISN'T dead :)

    Link here: PetitionPlugin v1.34
     
  16. Offline

    dak393

    awesome thanks for the link :D
     
  17. Offline

    Kainzo

  18. Offline

    Xemnas33

    He's busy with real life unfortunatley. He left me a pm asking to keep things going while he sorts everything out. He should be back soon :)

    Are you having any problems?
     
  19. Offline

    dak393

    awesome thanks for the update :)
     
  20. Offline

    Kainzo

    We were looking for some web integration / source, nothing too important.
     
  21. Offline

    Xemnas33

    Alright, I think that could be sorted when Floyd returns.
     
  22. Offline

    WhosDaMan

    Is this compatible with 935?
     
  23. Offline

    Xemnas33

    Yes. Title will not be changed for a bit.
     
  24. Offline

    kahlilnc

    Come back!!!
     
  25. Offline

    Xemnas33

    Still here :3

    Floyd is in Denmark, what's up?
     
  26. Offline

    kahlilnc

    OH just wanted the thread to say it is working with 953 and its kinda a bump. :D
     
  27. Offline

    LiamFrazer

    Just implementing it into my server, it's very useful plugin that provides the player or user with a lot more support then just a /help system. Thanks for the development and I haven't noticed any issues with 953 yet.
     
  28. Offline

    dak393

    Are you using this version? ^^^
    Edit: O wait looks like the original d/l link is working I think both versions are the same -.-;
     
  29. Offline

    Xemnas33

    Yeah main dl link is working again now :) Floyd sorted that before going to Denmark.
     
  30. Offline

    Juze

    #818 inactive.

    If anyone feels like still updating this plugin, please create a new thread until OP comes back.
     
  31. Offline

    dak393

    @FloydATC I know this is working and that its updated past #818 :) Thread update please.
     

Share This Page