HNHacker News
TopNewBestAskShowJobs

sunfmin

39 karma · joined June 23, 2011

submissionscomments
sunfmin··on Maud: A Rust macro for writing HTML
Similar thing in Go: https://github.com/theplant/htmlgo
sunfmin··on Show HN: A Full-Stack Web Framework for Go
People interested in this might also find my project interesting: https://docs.goplaid.dev, https://github.com/goplaid/
sunfmin··on I fell in love with low-JS
https://docs.goplaid.dev completely embrace low-JS in the Go world, you can write pretty complex UI interactions without write a single line of JavaScript, but only Go code.

It also integrate heavy duty UI component library like Vuetify, So you can use it easily in Go code.

It even go further to have presets that help you easily build Admin UI with much flexibility. https://docs.goplaid.dev/samples/presets-detail-page-cards/c...

sunfmin··on Go package: fanout – make writing parallel code even easier
Bookmarked and Stared!
sunfmin··on Go package: fanout – make writing parallel code even easier
Thanks, but there will be I/O waiting stuff right? For that whois command example, I find the CPU usage is zero if I am not running it parallel.
sunfmin··on Go package: fanout – make writing parallel code even easier
Yes, I often find myself lost in this trivial channels + goroutines + WaitGroup combination. For my self I'd prefer cast interface{}, :-)
sunfmin··on Go package: fanout – make writing parallel code even easier
I guess it is a parallel queue, It saves the trouble to worry about goroutines and channels and synchronizations, encapsulated the logic that talked in http://blog.golang.org/pipelines last part. To make use of that pattern easier.

I have quite a few use cases myself:

1. Say there is a article on the web, that contains dozens of images embed in the html. Which I want to crawl the article, and Also the images, and put the image into S3 for faster serve. I can use the fanout concurrency pattern to put upload all the images simultaneously to S3 to make it faster.

2. Say I have 20 mysql node sharded data, I want to fetch top 50 latest created data from all of them, and sort it to and show it to user after.

sunfmin··on Hood: A transactional, database-agnostic ORM for Go
I actually want to see this:

    hd.Where("name = ?", name).Where("category = ?", category)

So that you can do conditional where easily, for example:

    hd = hd.Where("name = ?", name)
    if category != "" {
        hd = hd.Where("category = ?", category)
    }
But It doesn't seem to support this?
sunfmin··on Basecamp Next
In early 2012, 37signals will introduce Basecamp Next , And you'll see why 2012 won't be like "2012"