[MISC] CraftProxy 0.2.0 - Reduce bandwidth use by caching chunk data [1.6]

Discussion in 'Archived: Plugin Releases' started by Raphfrk, May 1, 2011.

  1. Offline

    Raphfrk

    CraftProxy - Reduce bandwidth use by caching chunk data
    Version: 0.2.0

    Description

    This plugin and local client allows chunk data to be cached locally by players. This reduces the bandwidth required for hosting the server. It also helps users who are on slower connections.

    I am not sure what the status of this system is. It doesn't count as a plugin, since it has 2 parts.

    Even when running the plugin, players who don't use the client proxy can still connect. However, they will use the full bandwidth.

    The system can reduce bandwidth by 70-90% (after the 2nd login).

    Setup

    Server

    Add the plugin file to the plugins folder

    Client

    Start minecraft client and login
    Double click on the client jar file
    Enter login details
    Enter the server location/port in the GUI
    Press start on the GUI
    Connect to localhost on the minecraft client

    Stable Builds

    None yet

    Dev Builds

    Warning: These may not be stable

    Client
    Plugin

    Had it get the compress/decompression gain backwards.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
    Jushy, Martin1704, Nathan C and 24 others like this.
  2. Offline

    Raphfrk

    Your players should still connect to localhost with their minecraft client.

    On the GUI,
    Remote Server
    Name: <your server ip or hostname>
    Port: 1440

    Local Server (leave as default)
    Name: localhost
    Port: 25565

    - press start

    Open minecraft and connect to localhost. This will connect them to the GUI. The GUI will connect to the plugin and then plugin will connect to your server.
     
  3. Offline

    den

    I'm getting this error when logging in. Using the 1.6 protocol version of the plugin on craftbukkit 815.

    http://pastebin.com/3XZqTSD5

    It says [CraftProxyLite] Protocol Stream Closed in the client.
     
  4. Offline

    Raphfrk

    What settings have you set in proxylite.txt?
     
  5. Offline

    den

    Completely default.

    Show Spoiler
    clientversion=
    bridge_connection=false
    reconnectfile=
    monitor=
    seed=
    cache_limit=
    default_server=25565
    quiet=false
    debug=false
    listen_hostname_port=20000
    password=
    auth_off=true
    log=
    banned=
    info=false
    dimension=
    staticlocalhost=false
    log_time_off=true
    disable_flood=false
     
  6. Offline

    sfxworks

    I LOVE IT!
    http://sfxworksmc.blogspot.com/2011/05/download-this-to-reduce-all-lag.html

    For my wireless users, localhost:1440 does not work. I think its because localhost for wifi is targeting the wireless router and not the actual router. How do I fix this for them?

    fixed. I need to be able to change localhost to the users Default Gateway. (Which is an ip address)

    Could you make it so that I can edit localhost under LocalServer?

    Another thing, to find the default gateway

    Command prompt and type in ipconfig.

    Last thing

    Use http://ci.bukkit.org/job/dev-CraftBukkit/816/ :p

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

    Simanova

    issue with cp98 and cb817 and mc 1.6.6:


    client is diconnecting while crafting maps (paper+compass)
    error: protocol stream closed
    after relogging, the world stops loading ( only 1 chunk will be loaded )


    > clearing client cache wont work
    > restarting server wont work
    > after destroying the map by lava, everything is working again

    So the error might be: The protocol cant handle map items or a related function
     
  8. Offline

    Tealk

    i have a problem
    i have set up
    Code:
    clientversion=
    bridge_connection=false
    reconnectfile=reconnec.txt
    monitor=-1
    seed=
    cache_limit=3072
    default_server=78.47.47.179:25566
    quiet=false
    debug=false
    listen_hostname_port=20000
    password=
    auth_off=false
    log=
    banned=
    info=false
    dimension=
    staticlocalhost=false
    log_time_off=true
    disable_flood=false
    but if i connect with proxy i become the message "Failed to verify username!"
     
  9. Offline

    ssechaud

    Using CB b817, mc server 1.6.6 and craftproxy v96 I am getting bad packet dc's.

    9:44:00] 2.96.199.102/24487 (ssechaud): Client requested caching mode
    com.raphfrk.protocol.Packet@10eb27d Unknown packet Id e9
    com.raphfrk.protocol.Packet@10eb27d Unknown packet Id e9
    [19:44:01] 2.96.199.102/24487 (ssechaud): com.raphfrk.protocol.Packet@10eb27d Unable to read packet
    [19:44:01] 2.96.199.102/24487 (ssechaud): Packets: [31, 33, 33, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 23, 0, 0, 0]
    Exception in thread "CompressionThread" java.util.concurrent.RejectedExecutionException
    at java.util.concurrent.ThreadPoolExecutor$AbortPolicy.rejectedExecution(ThreadPoolExecutor.java:1956)
    at java.util.concurrent.ThreadPoolExecutor.reject(ThreadPoolExecutor.java:816)
    at java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:1337)
    at java.util.concurrent.AbstractExecutorService.submit(AbstractExecutorService.java:120)
    at com.raphfrk.compression.Compressor.compress(Compressor.java:177)
    at com.raphfrk.craftproxyliter.CompressionManager$CompressionThread.run(CompressionManager.java:74)
     
  10. Offline

    Chojin

    And also when using map item there are so strange things I cannot describe them, it also crashes the client.
     
  11. Offline

    Raphfrk

    Set auth_off to true.

    You should either have the proxy OR the server handle authentication.

    @ssechaud
    @Simanova

    I updated the proxy again. It should now handle the map packet correctly.

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

    Simanova

    V98? ... ah i see 99^^
     
  13. Offline

    Raphfrk

    Yeah, just uploaded.
     
  14. Offline

    Simanova

    Its working fine .. just testet .. thank you!
     
  15. Offline

    sfxworks

    Raphrfk, you need to make it so we can edit localhost under localserver. People on a wireless network can't use this.

    Hey man. Craftproxy allows people who have banned ip addresses to connect. Please fix this?

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

    Tealk

    its possible to set the proxy a ip
    because i have on the same server 2 servers with same port and different ip's

    //Edit
    and what mean the config var
    buffer_latency=0
     
  17. Offline

    Raphfrk

    Wireless doesn't allow map localhost to the current machine?

    It doesn't do much anymore. The proxy can be set to combine lots of info into a single internet packet. This sets the maximum time it will wait until it sends what it has.

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

    Tealk

    ty
    and whats with my problem with the ips
     
  19. Offline

    Raphfrk

    I can look into it. At the moment, it just binds to the default port.
     
  20. Offline

    Tealk

    thanks
     
  21. Offline

    spunkiie

    How do I enable whitelist ? There's nothing about it in my proxylite.txt

    Here's my 99 auto generated config:

    clientversion=
    bridge_connection=false
    reconnectfile=
    monitor=
    seed=
    cache_limit=
    default_server=25565
    quiet=false
    debug=false
    listen_hostname_port=20000
    password=
    auth_off=true
    log=
    banned=
    info=false
    dimension=
    staticlocalhost=false
    log_time_off=true
    disable_flood=false
     
  22. Offline

    sfxworks

    localhost for wireless has a different IP than the actual default gateway. All of my wireless users can't connect when they follow the directions.

    For instance, when you type in http://locahost while connected to a wireless router, it will have trouble accessing the router's home page for configuration. However, if you type in your routers ip (the default gateway) then it will work. You can find the default gateway by typing in "ipconfig" in command prompt. I don't know if java can automap the users network and reach out to get the user's IP address, but if localhost under LocalNetwork could be edited I could have this fixed in no time. If java can't map it, I would suggest having a downloadable file with the jar and a batch file. The batch file would run the command and write it to a text file. Then your program could read that txt file, replace localhost with the IP address of the Default Gateway, and it would all work.
     
  23. Offline

    Tealk

    2011-06-01 19:46:57 [INFO] 79.200.124.44/50911 (Relde): Attempting to connect to: 78.47.47.180:25566
    2011-06-01 19:46:57 [INFO] 79.200.124.44/50911 (Relde): Connection successful
    2011-06-01 19:46:57 [INFO] 79.200.124.44/50911 (Relde): Connecting using proxy to server connection format
    2011-06-01 19:46:59 [INFO] Relde [/78.47.47.180:33542] logged in with entity id 58280 at (-142.5, 64.69999998807907, 145.5)
    2011-06-01 19:46:59 [INFO] 79.200.124.44/50911 (Relde): Server login successful
    2011-06-01 19:46:59 [INFO] 79.200.124.44/50911 (Relde): Client requested caching mode
    2011-06-01 19:46:59 [WARNING] Failed to handle packet: java.lang.NullPointerException
    java.lang.NullPointerException
    at net.minecraft.server.Entity.f(Entity.java:1094)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:232)
    at net.minecraft.server.Packet10Flying.a(SourceFile:126)
    at net.minecraft.server.NetworkManager.b(NetworkManager.java:217)
    at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:75)
    at net.minecraft.server.NetworkListenThread.a(SourceFile:105)
    at net.minecraft.server.MinecraftServer.h(MinecraftServer.java:401)
    at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:311)
    at net.minecraft.server.ThreadServerApplication.run(SourceFile:422)
    2011-06-01 19:46:59 [INFO] 79.200.124.44/50911 (Relde): Kicked with: Internal server error
    2011-06-01 19:46:59 [INFO] 79.200.124.44/50911 (Relde): Redirect detected: null
    2011-06-01 19:46:59 [INFO] 79.200.124.44/50911 (Relde): EOF reached
    2011-06-01 19:47:00 [INFO] 79.200.124.44/50911 (Relde): Timeout
    2011-06-01 19:47:00 [INFO] 79.200.124.44/50911 (Relde): Closed connection to server
    2011-06-01 19:47:00 [INFO] 79.200.124.44/50911 (Relde): Closed connection to client
     
  24. Offline

    Kimundi

    Hm, could you maybe explain a bit more where the problem lies, or what you are trying to do? What has localhost aka 127.0.0.1 to do with the gateway? Or do you want to run the proxy on a different computer than the clients that connect to it? Of course http://localhost doesnt reach the router, it loops back to the own pc...
     
  25. Offline

    sfxworks

    I knew this.....I just derpd when I should of herpd....
    So I completely got this entire thing wrong then...

    In any case, for some reason, users that are on a wireless network cannot connect using this program. They follow the directions exactly as everyone else and they cannot connect. Why is this?
     
  26. Offline

    Kimundi

    That's a good question...
    To begin with, there is no difference between a wireless network and any other connection that would cause that behavior, and as long as they can connect without the proxy it should work...

    Maybe you could change the ports so that all traffic goes through the proxy, then there would be no difference in the network path, but the way you describe it it seems to be more a issue with the operating system or network setup of the clients and not the proxy itself.

    If you run the proxy on the command line you can specify a address to bind to, I just testet it:
    Both binding to my private ip and 127.0.0.1 works, As does connectiong from the same machine or another to it.
     
  27. Offline

    Tealk

    hi its possible to set up a variable who the player become a message at join that the server use the proxy plugin?
     
  28. Offline

    Raphfrk

    Presumably, you mean a message for players who connect with a normal client?
     
  29. Offline

    Tealk

    yes
     
  30. Offline

    sfxworks

    HOW DO I BAN AN IP? ITS NOT WORKING when i have this addon installed
     
  31. Offline

    Raphfrk

    The internal IP ban system won't work since all players are connecting from the same IP (i.e. the proxy).
     

Share This Page