Yammer 使用 Scala 的经验

发布于 2024-12-18 19:58:18 字数 529 浏览 2 评论 0原文

我在公司一直提倡使用Scala。我的一位同事今晚向我转发了此链接

http://blog.joda.org/2011/11/real-life-scala-feedback-from-yammer.html

我希望从 SO 社区得到一些关于此的建设性反馈。我不希望这变成一个火热的话题,但如果存在合理的担忧,我认为讨论可能的原因和最佳实践将是有益的,以避免其他人陷入此类陷阱。

我想说的是,我一直很喜欢 Scala,并且没有遇到任何提到的问题。我的应用程序也不是非常密集的哈希图,这似乎是他们相当多的问题的根源。

[编辑 - 显然我需要一个问题!]

问题是,您认为所描述的问题对于 Scala 来说是系统性的,还是对于他们的环境来说更为独特?如果它们是系统性的,是否有一些好的指导方针可供刚开始使用 Scala 的公司遵循,这样他们就不会在 2 年内重蹈覆辙?

I have been advocating using Scala at my company. One of my co-workers forwarded me this link tonight

http://blog.joda.org/2011/11/real-life-scala-feedback-from-yammer.html

I was hoping to get some constructive feedback from the SO community about this. I don't want this to turn into a flaming thread, but if there are legitimate concerns floating around out there I think it would be beneficial to discuss possible reasons and best practices that can avoid others falling into such traps.

I will say that I have been loving Scala and have not run into any of the problems that are mentioned. My application is also not very hashmap intensive, which appears to be where a fair number of their problems came from.

[Edit - apparently I need a question!]

The question is, do you think that the problems described are systemic to Scala, or more unique to their environment? If they are systemic, are there some good guidelines for a company that is just getting started with Scala to follow so that they don't end up in the same boat in 2 years?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

倒带 2024-12-25 19:58:18

问题描述

语言复杂性

系统性问题。 Scala 不太可能变得不那么复杂,这是否是一个问题取决于使用它的开发人员。对我来说,它足够复杂,足以让我保持兴趣和投入,而纯 Java 可能会让人感到无聊。我怀疑,如果 Scala 对于特定开发人员来说过于复杂,那么他们在 Java 方面也不太可能成为一流的开发人员。

社区

所以这个人说唯一的方法是使用双射映射
关于半代数,不管那是什么,另一个人说
使用一个没有文档并且直到最后才存在的库
周和他写的。第一个人和第二个人似乎很讨厌
彼此。 Scala 发送 HTTP 请求的方式是什么?
服务器?

这句话很有趣,但这显然是 Scala 的一个非系统性问题。他对最佳实践缺乏共识的主要抱怨与所有新兴语言相关。我认为 Java 开发人员在某种程度上被宠坏了——已经习惯了成为如此庞大社区的一部分,在这个社区中几乎所有事情都已经完成并且可能已经标准化。

构建工具链

另一个非系统性问题。

性能

这确实让我有点担心,我发现我很快就会感到沮丧,不得不发现以前未知的性能问题。我怀疑在未来的几年里,根据您如何使用该语言的某些方面,将会出现一些相当大的性能损失——因此人们必须谨慎行事,并对每个项目的性能要求进行自己的分析。

我在这里同意他的观点:

尽管我们正在放弃 Scala,但我仍然认为它是
我用过的最有趣、最创新、最令人兴奋的语言之一
用过...

最后,我会敦促人们带着某种程度的怀疑来阅读 Stephen Colebourne 的博客,因为相对于争论而言,他个人对 Scala 语言的蔑视似乎有点过大了。

Issues Described

Language Complexity

Systemic issue. Scala is unlikely to get less complex, whether or not that is a problem depends on the developers that are working with it. For me, it is complex enough to keep me interested and engaged, whereas pure Java can be mind-numbingly boring. My suspicion is that if Scala is way too complex for a particular developer, it is unlikely they're going to be top-notch dev when it comes to Java as well.

Community

So this one guy says the only way to do this is with a bijective map
on a semi-algebra, whatever the hell that is, and this other guy says
to use a library which doesn't have docs and didn't exist until last
week and that he wrote. The first guy and the second guy seem to hate
each other. What's the Scala way of sending an HTTP request to a
server?

That quote is pretty funny, but this is obviously a non-systemic issue with Scala. His main complaint about a lack of consensus regarding best-practices is relevant to all up-and-coming languages. I think Java developers have been spoiled in a way -- having gotten used to being part of such an enormous community where pretty much everything has been done before and possibly already standardized.

Build Toolchain

Another non-systemic issue.

Performance

This one does worry me a little bit and I can see getting frustrated very fast having to uncover previously unknown performance gotchas. I suspect for years to come there will be some pretty big performance penalties depending on how you use certain aspects of the language -- so people will have to exercise caution and make their own analysis regarding each project's performance requirements.

I concur with his sentiments here:

Despite the fact that we're moving away from Scala, I still think it's
one of the most interesting, innovative, and exciting languages I've
used...

And finally I would urge people to read Stephen Colebourne's blog with some degree of skepticism, because his personal disdain for the Scala language seems a bit oversize relative to the arguments.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文