Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Added update-datapack in-game command. Running will trigger a script to run on host and restart builders server. #19

Merged
merged 6 commits into from
Feb 1, 2024

Conversation

xane256
Copy link
Contributor

@xane256 xane256 commented Jan 31, 2024

No description provided.

xane256 and others added 5 commits January 27, 2024 20:59
- added shadowJar artifact which bundles jedis library
- shadowJar is 96mb compared to base mod 1.5mb
- still has kotlin language adapter error despite AgroNet.kt L51 bundling entire thing
- ./gradlew runServer WORKS but copying jar to server and running there DOES NOT WORK - this required shadow jar to fix because Jedis library was not included in compiled jar.
Copy link
Member

@4Ply 4Ply left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor improvement suggested, but happy to merge as is for now if you want to do those in a follow-up PR

response = "Failed to send message"
}
logger.info("[AGRONET]: [update-datapack]: $response")
// context.source.player?.sendMessage(response, Formatting.GRAY)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The source should get the response information as well, otherwise we have to check server logs to debug

You should be able to just send that directly to the source, regardless of whether or not it's a player with context.source.sendMessage(...)

logger.info("Successfully established a socket connection to Redis.")
} catch (e: Exception) {
logger.error("Failed to establish a socket connection to Redis: ${e.message}")
e.printStackTrace()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should throw this error here or just return, so that we don't try the next block of code if this connection fails

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll put in an error message and return early

@xane256 xane256 merged commit fcf6ed5 into main Feb 1, 2024
4 checks passed
@4Ply 4Ply deleted the feat/update-datapack branch June 9, 2024 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants