Reading and observing some of the startups and well-known services, almost every time I found that people there are using cross-technology system in their architecture. For example like Twitter, used ruby on rails on their front-end parts, and scala for their more of back-end parts. Or the other stories like how some startup use java and golang or java and erlang for their stack.
Well I'm curious about how is the common practice to implement such cross-technology integration? For Twitter case, do they build the Scala back-end and then wire up some web service technology to create api endpoints for the rails part to consume? Or there's some API for the cross functionality between scala and ruby? Or is there some more common practice to do such thing?
As a rookie, I hope to get some perspective on this subject.