Ruby China
  • 社区
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • 注册
  • 登录
bhuztez
@bhuztez
高级会员
第 1569 位会员 / 2012-03-24

40 篇帖子 / 2614 条回帖
105 关注者
0 正在关注
0 收藏
未设置 GitHub 信息。
  • 概况
  • 话题
  • 回帖
  • 收藏
  • 正在关注
  • 关注者
  • [北京] 星起招聘 Ruby 工程师 at 2018年03月06日

    求带

  • 前后端分裂 at 2018年01月07日

    这是大公司病,和前后端分离无关吧。小公司前后端再分离,刚开发的时候也许是多个人,只是改这么点东西,肯定是一个人随手就改了啊。

  • RubyConf China 2017 售票开始!(已更新日程安排) at 2017年08月01日

    我是说他要悲剧了

  • RubyConf China 2017 售票开始!(已更新日程安排) at 2017年08月01日

    这时间安排,Ruby 异步编程奥德赛 ...

  • RubyConf China 2017 讲师和主题介绍 at 2017年07月14日

    举个微小的例子

    -pattern(
       { integer,
         "[0-9]+",
         {erlang, binary_to_integer},
         {erlang, integer_to_binary}
       }).
    
    -dispatch({root, "posts/", {dispatch, post}}).
    -dispatch({post, "", {endpoint, index}}).
    -dispatch({post, "{id:integer}", {endpoint, post}}).
    
    test() ->
        [<<"/">>,<<"posts/">>] =
            url_reverse(index, #{}),
        [<<"/">>,<<"posts/">>,<<"10">>] =
            url_reverse(post, #{id => 10}),
        {index,#{},<<>>} =
            url_dispatch(<<"/posts/">>),
        {index,#{},<<"a">>} =
            url_dispatch(<<"/posts/?a">>),
        {post,#{id := 10},<<>>} =
            url_dispatch(<<"/posts/10">>),
        {post,#{id := 10},<<>>} =
            url_dispatch(<<"/posts/1%30">>),
        error =
            url_dispatch(<<"/posts/10/">>),
        ok.
    

    自动生成的函数大概长这样

    url_reverse(post, #{id := Vid}) ->
        [<<"/">>, <<"posts/">>,
         url:encode(erlang:integer_to_binary(Vid))];
    url_reverse(index, #{}) -> [<<"/">>, <<"posts/">>].
    
    url_dispatch(Bin) ->
        case url_dfa(Bin) of
          error -> error;
          {18, #{}, Rest} -> {index, #{}, Rest};
          {23, #{1 := T1, 2 := T2}, Rest} ->
              {post,
               #{id => erlang:binary_to_integer(url:decode(binary:part(Bin,T1,T2-T1)))},
               Rest}
        end.
    
  • RubyConf China 2017 售票开始!(已更新日程安排) at 2017年07月13日

    躺枪

  • RubyConf China 2017 讲师和主题介绍 at 2017年07月13日

    慢慢来吧。这个对轮子哥太不友好了。尽管我并不是针对他。轮子哥整天炫耀 C++,正则表达式,GUI 框架以及吃软饭。把轮子哥黑成不会 C++ 了,这事就已经吓的他连写好几篇谁都看不懂的,考不上三本系列了。这次把轮子哥黑成不会正则表达式,他又要有好久没心思玩了。下回要是再把他黑成不会 GUI 框架,他估计要自暴自弃了,整天只炫耀自己吃软饭了,这样不好。

  • 我觉的 Ruby China 对新手不太友好 at 2017年07月10日

    不是不太友好,是非常不友好,都动不动不让回复了

  • 如何一个人管理一堆服务器 at 2017年07月09日

    动态伸缩,直接用 ansible 管 CloudFormation 啊

  • Phoenix vs Rails: quick performance comparison 被最后的 ab 压测震惊了 at 2017年07月01日

    小破站才用 Erlang。小破站换 Erlang 是大势所趋。

    ActionCable 什么的,功能极其有限,难用的要死 ...

  • counter_cache + foreign_key + MySQL = DEADLOCK?? at 2017年07月01日

    你这 SQL 写的就是错的。你这么干,得先 SELECT FOR UPDATE,好不好

  • Phoenix vs Rails: quick performance comparison 被最后的 ab 压测震惊了 at 2017年07月01日

    跟 rails 比跑分,这是连脸都不要了 ...

    Erlang 跑分比较烂,估计要等明年 Erlang 21 出来才会改进。

  • Tracebin - 开源的 Ruby Application 性能监控应用 (APM) at 2017年06月28日

    集群维护成本比单机高太多了。这个 benchmark 选的不是很好。kdb+ 在 asof join 上能拉开其他数据库两到三个数量级。

  • Tracebin - 开源的 Ruby Application 性能监控应用 (APM) at 2017年06月28日

    你说的这些比 MapD kdb+ 这一梯队的慢大约一个数量级 ...

    http://tech.marksblogg.com/benchmarks.html

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月27日

    感觉不太好,现在看起来好像我就是来砸场的 ...

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月25日

    这个是很容易做的。问题在于并不能检查输出的 column 有没有被用到

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月16日

    要是比 ecto 好,你得换 Erlang !!!

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月16日

    只需要能支持 capture 的 DFA 就可以了。合并成一个 DFA 的好处在于编译期就能发现是不是有些 URL 会被多个 pattern 匹配。

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月16日

    ecto 功能弱爆了,用起来还这么麻烦

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    这么看来,可能是你不知道什么是 DFA。算了,不扯这个了。

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    差不多吧。全在编译期完成,100% 无运行期额外开销 ...

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    这个库的代码也好简单。DFA 到底在哪里?

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    吓尿。这么几行代码?也没看有调用什么库。

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    代码地址?

  • RubyConf China 2017 讲师和主题介绍 at 2017年06月15日

    目前还没弄完。还有一个月时间,我尽快吧。不过已经感觉有点不太好了。你可以去找 https://www.zhihu.com/people/fleurer/ 问问,昨天被他偷拍了。我感觉上面某个演讲的作者,可能要将他的框架称为量产炮灰型框架了 ...

  • [上海 张江] pwc (sdc) 招后端,前端,区块链应用开发。 at 2017年06月08日

    简历已发,求带

  • Tracebin - 开源的 Ruby Application 性能监控应用 (APM) at 2017年06月06日

    要啥后端。直接吐给 ELK 什么的就是了

  • [杭州][9.16 - 17] RubyConf China 2017 主题分享征集 (已更新主题) at 2017年06月05日

    我现在只保证在截止之前投稿

  • 申请删帖 at 2017年06月04日

    别吵了,反正过不了几个月你们都转 Erlang 了

  • [杭州][9.16 - 17] RubyConf China 2017 主题分享征集 (已更新主题) at 2017年06月02日

    放心,我会把你们全都转化成 Erlang 的

  • 1
  • 2
  • 3
  • …
  • 84
  • 85
  • 下一页
关于 / RubyConf / Ruby 镜像 / RubyGems 镜像 / 活跃会员 / 组织 / API / 贡献者
由众多爱好者共同维护的 Ruby 中文社区,本站使用 Homeland 构建,并采用 Docker 部署。
服务器由 赞助 CDN 由 赞助
iOS 客户端 / Android 客户端 简体中文 / English