Servers automatically renaming Plugin Database

  • I have been having trouble with some of the plugins on my server. I am not sure why but my server is proned to renaming the database for the ability to find them on a larger server I am sure but they all have pingperfect added to them. Most plugins dont seem to be bothered by it but others seem to not recognize the database. I was wondering if there is instructions to the server companies on this and if this would be something that the community has looked into as an issue?


    Even the main database for the game in the worlds directory has been named just Pingperfect.db. It obviously is working but wanted to head off larger issues as plugins become more common.

  • ehm noone can rename databases but the plugin itself, many plugin creators use the world name in the database's name to make the plugin usable on multiple worlds in SP


    The main db is named after the world and is inside the worlds folder that has always been the case.

  • ehm noone can rename databases but the plugin itself, many plugin creators use the world name in the database's name to make the plugin usable on multiple worlds in SP


    The main db is named after the world and is inside the worlds folder that has always been the case.

    No disrespect Minotorious, but this is a serious question I have to the developers who actually know the service they are proliferating to commercial servers and that it may have a problem. I am having issues with some plugins not seeing their own databases and I think a this could be a legitimate bug or reason for the plugins not seeing their own database. So if no-one but the plugin creator can rename the database and these commercial server services are automatically renaming then a solution needs to be found.


    Pingperfect renames every database in Rising World. You can rename it manually but it will repopulate it with a renamed database including the one in the world directory. If they do not want commercial services to do this or it causes some sort of issue with databases then a solution will have to be devised to either inform the commercial server services or inform the plugin operators to make a solution.


    I have attached two pdfs snapshots of the database. I tried renaming the databases and the server service automatically renames it or makes the new one that has pingperfect in the name. Probably so they can find all their files on a larger or not company owned third party server services. It works for the game but I suspect it may be a problem for plugin on multiple server services.


    I have made an inquirey to their service but they are like talking to a large company IT department that really does not understand how the game works. So I thought I would ask here.

  • In your screenshots I can see that the folder under the worlds directory is named Pingperfect, so I have one important question, what is the name of your world?


    Did you specify it in the server.properties file?



    Edit: I opened and decompiled the iConomy plugin and this is the line that specifies the plugin database: getSQLiteConnection(getPath() + "/database/" + getDescription("name") + "-" + this.world.getName() + ".db"); as you can clearly see it includes the world name. The world name is the name of the folder under the worlds directory so from my understanding your world is indeed named Pingperfect and the company is not altering anything on its own. To test this open the server.properties file and change the world name entry in it so that the server generates a new world with the other name, then check if the server provider will change that name (which I highly doubt they will). Make sure you backup your old world before doing any of this.

  • The server does not automatically rename any databases (neither the world name nor any plugin databases). Some hosters usually set a specific name for RW worlds (often including the name of the hoster), but there is nothing wrong with it. Only the "server_world_name" setting in the "server.properties" matters (if the server uses SQLite), but as long as it's equal to the world name, there is nothing to worry about (plugins access the world via abstract functions anyway, so the world name does not matter in this case). Usually hosters only set the world name once.


    However, when it comes to plugin databases, basically only the plugin creator is supposed to name/rename the database. The game/server does not touch these files. But since a database is just a file on the server, the administrator (i.e. the hoster) can of course also rename these files manually - but it's not recommended to do that, since most plugins probably won't recognize the database then. If your hoster is renaming any plugin files resulting in the plugin no longer recognizing the database anymore, I'd recommend to contact support of the hoster.


    Nevertheless, in this particular case it seems that everything works as intended, since the plugin creator included the world name for the database (as mentioned by @Minotorious).

  • No pingperfect automatically rename the databases. You can not rename it or when it runs the database gets renamed by the server. Pingperfect automatically puts ping perfect in every database file including plug ins. Some plugins don’t mind and some don’t seem to recognize it. I can show you more examples


    Everything is not working this example database is not working. So you are saying this is an issue on their side and not the plugin creator?

  • No pingperfect is not automatically renaming the databases, your world is called pingperfect, change the world name in the server.properties file and you will see the new databases will have the new name.


    What happened is that you didn't set the world name before starting the server so pingperfect automatically set it to "Pingperfect" else your server wouldn't have started.


    The plugins are not working not because their database is not recognised but because they probably have bugs in them. Try using my portals plugin and you will see that a database called Portals_pingperfect.db will be generated and it will be working perfectly.

  • I use it and yes your portals and it does work


    I did not name any database because they said not too in their setup. They set it up not me All I got was the address.


    So now it is the plug in problem


    I do have plug ins that have the same world name and no - name and they work ok. They have the pingperfect only name

  • I did not name any database because they said not too in their setup. They set it up not me All I got was the address.

    oh ok I see :/ That is weird for them not to allow you to customise it but idk their policies.

    So now it is the plug in problem


    I do have plug ins that have the same world name and no - name and they work ok. They have the pingperfect only name

    yes that is correct, if a plugin is not functioning properly it is not the game's, server's, or host company's fault, it is the plugin creator's fault 99% of the times.

  • I am sure they want it to work first time. They havea button I have to push when there is an update for Steam I have to push to log on because Steam pushes the update automatically to my computer unless I turn that off but it is sort of a pain if I do



    Anyway you help eliminate that theory. It must be the plugin that can’t see its own database for some reason and it is the plugin that is rewriting naming the databases

  • Anyway you help eliminate that theory. It must be the plugin that can’t see its own database for some reason and it is the plugin that is rewriting naming the databases

    yes it is the plugin but it is not really renaming the database, it is looking for a database named iconomy-WorldName.db if it doesn't find one named that it just creates a new one.


    So if you want the plugin to work you should not touch the plugin folder unless instructed to do so by the developer, or ofc in case there are settings you can specify for the plugin e.g. the amount of money new players get when they connect for the first time, or the colour of the plugin's text output.


    If the plugin doesn't work as provided by the developer then something is wrong with the plugin and the developer is the only one who can fix it.


    In extremely rare cases it can also be a bug in the API but then the plugin developer will have to let red51 know and fix it while letting you know you have to wait for a fix.

  • Ok well I was trying to trouble shoot the plugin that in an older version wrote to the database and stored player UIDs properly but would not transfer money. The new version wont even write to the database. It remains blank. I was hoping it would be as simple. I have fooled with edited plugin databases before and made them work, stop crashing my server or updated rights manually for a player. I did not understand the relationship between the database name and the world name which ends with this discussion.


    I am away from my computer that is set up for reviewing the java code so I could not see the routine calling you you displayed. However, in this case the server operators are given the actual code so it is reviewable and possible correctable. In most cases you dont get the code to review.


    Thanks for the incite and understanding.

  • I am away from my computer that is set up for reviewing the java code so I could not see the routine calling you you displayed. However, in this case the server operators are given the actual code so it is reviewable and possible correctable. In most cases you dont get the code to review.

    Most plugin creators don't provide source code by default, you can ask them for it but they are not obligated to share it with anyone. I have on multiple occasion provides snippets of my code to help others but I will only provide the full source of my plugins in case I intend to give up on updating them so that someone else may take over.

  • Funny I have a /TP routine that works at my home computer giving me a list of TP points I have created. When I come to my Lakehouse computer which is a little slower graphically my /TP List always gives me an error of no tp point by that name issues and I have to put the numbers in. Really weird these plugin issues.


    I have already voiced my thoughts on the frustration at the disparity in plugins and obstacles for running paid servers for the game. Glad there will be an official supported upgrade of the game pretty soon that will take everyone's attention for a awhile..

  • Unfortunately a few plugin creators have given up on their plugins and stable fully functioning new replacements for these plugins have not been created yet, some are on my to do list but it will take time for me to single handedly rewrite all these plugins :/

  • You can see what I did to rig the plugin to start working in the plugin thread. Basically the routine would not initiate or write to the new database. The old database was populated so I put that in and it started working. Still may be a writing to database issue for new entries as that is yet to be tested.


    If you go to my server as a first time and you have cash then it works. If you have been there before this will not be a test as you are probably in the old database.


    Thanks for the help.

  • ok sure will test it, I don't think i have even been on your server so I will join this evening (central europe time) and let you know :)

  • Code
    getSQLiteConnection(getPath() + "/database/" + getDescription("name") + "-" + this.world.getName() + ".db");


    I would write the path:

    Code
    getSQLiteConnection(this.getPath() + "\\database\\iconomy.db");


    The first one actually creates a path similar to (on Windows at least) C:\risingworld\path/database/description-name.db when executed on the JVM.


    I'm only surmising that this may be a cause. . .


    There really is no need for a unique database name for each server plugin it's complicating things for no reason.


    KISS mentality, Keep It Sweet (n) Simple.

  • nah doubt that is the cause, I use similar statements for the databases on all my plugins and have no problem no matter if they run on a windows or linux/unix server :/



    Java
    Database mainSQLite = getSQLiteConnection(getPath() + "/assets/" + getWorld().getName() + "_Portals.db");

Participate now!

Don’t have an account yet? Create a new account now and be part of our community!