Sponge's Way Of Logging

Now, Im a bit fussy when it comes to logging.
I guess its based on Forges’s way of logging which is just stupid.
What is the point of this?

[12:33:37] [Server thread/INFO] [net.minecraft.server.dedicated.DedicatedServer] : Loading properties

Surely the Sponge Team could condense it to:

[12:33:37] [Server thread/INFO] [Sponge] : Loading properties

Although, I have the feeling that its something to-do with class names, and if it is, Bukkit didn’t have all that [net.minecraft.server.dedicated.DedicatedServer] stuff.

It just makes the log ugly and hard to read on smaller screens.


Anyone Agree?

2 Likes

@Niall7459 you forget that sponge is a forge mod and no server distribution. Ofc sponge could change this using asm, but I see no reason why it would do that. Meaby forge will change it to:

[12:33:37] [Server thread/INFO] [Minecraft] : Loading properties
2 Likes

Oh, so its based on Forge Server and sponge is just a mod

Yep :smile:!
I understand that this will be very confusing for craftbukkit people. But I am sure when sponge released some good tuto’s will come up.

No, you do not want to get rid of that. That is the actual class name doing the logging which is important for debugging. By just replacing it with “[Sponge]” you have no idea where that log originated and what it actually means. e,g, DedicatedServer’s “loading properties” means something completely different than MyMod’s “loading properties”. By removing the class name you lose all context.

Also, the logging is using log4j2, so you can configure the logging output a lot. For an example see http://www.minecraftforum.net/forums/minecraft-discussion/recent-updates-and-snapshots/382008-log4j-2-server-logging-help

What About Giving It A Nickname, Is That Possible?

[net.minecraft.dedicated.DedicatedServer] =

[Forge]

Even if they could change it the above one would still be more useful, because it tells you the exact class where the entry came from, which is really useful for debugging (for the developer at least).

iirc one of the function of the logging configuration can cause

net.minecraft.dedicated.DedicatedServer

to become

n.m.d.DedicatedServer

I think it should be the class name only, without the package.

[12:33:37] [Server thread/INFO] [DedicatedServer] : Loading properties

But you may have classes with the same name in different packages. It is something that someone would obviously try to avoid, but sometimes it still happens. Then you wouldn’t know which class a problem might be in.

Yes it makes it easier, and if developers wanted to see the full class name, then they should add an option.

Once Sponge gets a config.yml or whatever, people can just enable an option to have full-class-debug.

One could passably add another logging level called condensed, just for console output, not for log files.

edit: I got ninjad

Phew, Im Really Confused, So Sponge Isn’t a minecraft_server.jar, it is a plugin, right?

so you would drag sponge.jar into Forge/Plugins or Forge/Mods

Im Confused :confused:

You would put it into the mods folder, since it’ll be a Forge coremod. The plugins folder will then contain the Sponge-plugins.

Sorry if this is getting a little off-topic, but on that note, will this require all clients to be forge enabled as well or will Forge eventually allow non forge clients to connect? I’m not personally a fan of adding Forge mods to my servers since I used Spigot prior. Although, if it’s a forced thing to use Sponge, I may consider some forge mods to compliment the server.

Clients can be running the vanilla jar.

Right now Forge requires the client to be Forge as well, but htey said they’re gonna change that for 1.8.

3 Likes

I think it should be formatted like one of these…

[12:33:37] [INFO] Something printed to the server.

or

12:33:37 [INFO] Something printed to the server.

It just makes everything cleaner and more human friendly, especially if you want to read through the logs to see how things are going.

PS: Sorry for replying to a 14 day old post…

2 Likes

It should probably be optional. Without the class name on the line, people trying to debug may have issues. So it wouldn’t be wise to remove it entirely, but rather just clean it up if configured to.