TheRealMoonman
I eat babies
- Sep 30, 2014
- 360
- 74
This is probably the first time I've asked for help, but because I have stuff irl to deal with, it kind of conflicts with projects and stuff i wanna do, I recently talked a bit of shit about golang, which is a language developed by google, and while looking more into it, its actually a pretty fucking awesome language. I just wanna know if anybody is interested in helping me with this current project, that I'm writing in go, my biggest problem is caching the data taken from the database, and caching it, I have looked into some of the binaries for golang, but I'm not a go developer, I've just been reading a few pdfs to understand the basics, and since I use python alot, its pretty easy.
The use of semi-colons is pretty must gone, functions are called without them e.g Initate(), and they have no circular dependencies which is a bit of a mind fuck for me.
But other than the code which is fairly good to use, the speed is almost akin to C++ which blows C#, Node.js and Java out of the water.. if you write the code good enough.
So if anybody knows basics of caching in golang or something helpful for it and you wanna make a unique emulator, hit me up, because its a learning experience for me, and I haven't made a development thread for it yet because I want to see it working in action, before i post anything about it.
bit of an example how you'd open a mysql connection in it.
The use of semi-colons is pretty must gone, functions are called without them e.g Initate(), and they have no circular dependencies which is a bit of a mind fuck for me.
But other than the code which is fairly good to use, the speed is almost akin to C++ which blows C#, Node.js and Java out of the water.. if you write the code good enough.
So if anybody knows basics of caching in golang or something helpful for it and you wanna make a unique emulator, hit me up, because its a learning experience for me, and I haven't made a development thread for it yet because I want to see it working in action, before i post anything about it.
bit of an example how you'd open a mysql connection in it.
Code:
func Connect() {
var err error
DB, err = gorm.Open("mysql", config.MYSQL_USER+":"+config.MYSQL_PASS+"@/"+config.MYSQL_DB+"?charset=utf8&parseTime=True&loc=Local")
if err != nil {
panic(err)
DB.Close()
}
fmt.Println(">Connection Succesful")
fmt.Println(">Test Query Starting")
TestQ()
}