--
You received this message because you are subscribed to the Google Groups "Gearman" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gearman+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gearman/158705044347.30162.5943445184644122393%40clint-ThinkPad-X1-Carbon-6th.
Greetings Gearman enthusiasts and users!
So, without furter ado, I give you: Rustygear, and Rustygeard
everything seems to function at the surface level.
To the other gearmand maintainers: How would you feel about deprecating
the C++ bits and focusing on this one? Could you make it work for your
org? What features would you need? I *really* don't want to work in
C/C++ anymore. :)
And I'd need SSL/TLS support to even consider switching. I can't seem to tell from the rustygeard source code if it currently supports that or not. It doesn't seem to based on my googling of Rust and SSL support, but maybe it's hidden in some Rust macro that I don't understand?
Hey,
From long term silence, comes an unwanted/uninvited opinion :)
> I hear you. Rust is not for everyone, the learning curve is a bit steep
> on the front end. One thing I like about it though, is that generally if
> the code compiles, it's got a really good shot of working right.
>
> It's not a short term suggestion btw. But one that I wonder about for
> the long term health of the project. I, for one, am kind of over C/C++
> now that I've bought in to Rust.
>
> > I would be unlikely to switch my organization from using gearmand mainly because gearmand works and fits our requirements fine as-is. I'd probably need a new feature or good reason to switch implementations, like vastly better performance under high loads or something like. And I'd need SSL/TLS support to even consider switching. I can't seem to tell from the rustygeard source code if it currently supports that or not. It doesn't seem to based on my googling of Rust and SSL support, but maybe it's hidden in some Rust macro that I don't understand?
> >
>
> Have not added TLS support yet no. I'd like to though. :)
>
> The main feature is maintainability. Once something *is* in Rust,
> refactors and expansions are extremely ergonomic, and generally
> performance regressions don't happen unless one really screws stuff up.
>
> In my limited scale tests though, rustygeard keeps up with gearmand just
> fine on one thread. I haven't had time to push it beyond that.
>
> > Generally, I would not be in favor of "deprecating" gearmand per se. Public popularity/usage will determine that on it's own. That said, a Rust implementation of Gearman is very cool (and impressively minimalistic in terms of lines of code). Gearman has a long history of being (re-)implemented in multiple languages, and Gearman has always been agnostic where it comes to the implementation language. It would certainly be appropriate to put it in a separate repo under github.com/gearman/, fwiw, if/when you didn't want to just keep it under your personal GitHub area, but I'm probably stating the obvious there.
> >
>
> Thanks! It's missing all of the background job durability, but really
> Rust is higher level than C, and Gearmand is kinda 90% C, 10% C++. If
> Gearmand had been fully converted to C++ I think you'd see less LOC as
> well.
This is a neat project (need to say this first!). I want to echo (echo?)
that the "rewrite in Rust" stuff is obnoxious on its own. I struggle a bit
with the language since most of what I do is data structures, which it
seems to do nothing but make difficult. If you can use a library and get
higher level than that it seems alright?
I have a point tho: it'd be nice if this came with an engineering goal.
Being in another language is maintenance; not a real goal to move the
project forward. Else your end goal is only to get back to where you are
now. That sucks.
If I dig my arms into history I'd welcome a chance to focus a
simplification of the daemon. The job durability stuff adds a lot to the
daemon itself with varied guarantees. I really liked the old Garivini
code; sits outside gearman, gets better with small protocol tweaks, etc.
Let the server be narrow and scalable, and let garivini persistence
daemons be written in any language that speaks gearman. It also scales
much better since you have a separation of duties between gearmand and the
persistence systems. You don't need 10 different rust clients for the
various persistence systems.
There isn't really much _to_ gearmand beyond the core protocol and a few
basic optimizations otherwise:
1) accept jobs from clients
2) wake up N workers, then All workers after a timeout (main
optimization!)
3) synchronous jobs
4) scheduled jobs
5) mild job priority system
That's it. Sprinkle TLS on top and you're done. If I wanted to innovate
I'd add batch ops to the protocol (which helps Garivini), unless I missed
that being added to the C daemon at some point :)
-Dormando
> Regarding data structures in rust.. I'm sorry that you've had frustration. If you wade back in, check out unsafe, which is specifically *for people like
> you*. The point of Rust is to default to safety so it feels like a high-level language 90% of the time, but to let you write small sections of code with
> your own algorithmic assurances and testing. Seriously. That said, without much state to manage, I don't think gearman needs any complex structures that
> aren't available in libraries already. It's mostly hashmaps and vecs. :-P
Given the abuse I've seen thrown at users of unsafe I think the rust
community can take some time to mature before I wade into it seriously. I
have a laundry list of complaints and too much work to do, but I don't
want that to take away from anyone who actually enjoys using it.
> If somebody has an engineering goal they should definitely work on it. What I see is that gearman languishes because nobody with an engineering problem to
> solve wants to work in hybrid C/C++. So, from an engineering perspective you are right: rustygear wants to match gearmand, not exceed it. But from a
> community standpoint, rustygear wants to open the door to folks using and contributing more. Also, rust does offer a better security story.
My communication skills are waning :) If I'm an outsider and see rustygear
and C gearmand in the gearman repo, I'd see a C daemon with a ton of
features (mostly various storage methods) and an MVP in rust. I doubt
anyone/many people would want to dive in as either a user or developer
with that much gap.
By clarifing that you have a goal of not including most of those C
features (and why) you go from a toy MVP to nearly complete.
> I have definitely thought about turning attention to building a built-in scale-out system like Garivini in Rust. But.. this is just a labor of love, and
> I'm wary of spending too much time chasing my own desires without any real world tether. :)
You don't have to do anything to support Garivini. You just have to
advertise it's a thing and that (when you're ready) you consider
rustygear feature complete; someone could go write the connector in Go or
C or Brainfuck or Rust or use the perl version. You're done already.
IIRC pledging to a storage scaleout model of Garivini only means some
small things for the main daemon:
1) the "status" command needs to be fast (or a fast command to list number
of jobs/bytes in each queue). It wasn't fast in one of the daemons and I
never fixed that.
2) Consider batch jobs, but that's purely an optimization.
3) You're done. You personally don't have to write any other code.
> 2) wake up N workers, then All workers after a timeout (main
> optimization!)
>
>
> OOPS! I forgot about this one. Thanks, I'll add it to rustygeard.
Ah cool heh. I can't fully remember anymore but there was an order to
which ones it woke up first (first to check in? last to check in?). This
confused some users since it wouldn't "distribute" load unless you
actually had load.
> This never worked in the C gearmand. The one reason I don't like it in the gearman daemon is that it represents state, just like background jobs. Much
> better handled by scaled out workers IMO.
No arguments here. Garivini-style can do that trivially.
> Really though, utlimately, it just feels that folks aren't seeing a need for a gearmand anymore. Folks use redis or rabbitmq or one of the cloud-provided
> things like SQS for job queueing.. and if you don't need the coalescing features of gearmand.. it doesn't offer you much over a much more mature and
> featureful thing like redis.
Yeah more or less. Sorry if I contributed to this by not putting any work
in :) I wish we blogged about gearman harder back in the day. I remember
Starling and Gearman existing at the same time (starling coming after),
and it was such a piece of trash in comparison. Queue software evolved
from starling (rescue/etc) and we did the world a disservice :(
I do say though that it's easy to kick off a queue in redis but it doesn't
have a concept of a distributed system at all. that's what gearman was
from the start and continues to provide. The internal job persistence
plugins took away from that and made it feel more pointless.
but.. yeah, most people just use whatever the cloud has now :/ oh well.
Thanks a ton for keeping things alive!
-Dormando
--
You received this message because you are subscribed to the Google Groups "Gearman" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gearman+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gearman/alpine.DEB.2.21.2005031144030.9649%40dskull.