It seems like both can be used to define functions that you can implement later, with different data types. AFAIK the major difference is that defmulti works on maps and defprotocol works on records.
What other differences there? What are the benefits of using one over the other?
Short version:
defmultiis much more flexible and general, whiledefprotocolperforms better.Slightly longer version:
defprotocolsupports dispatch on type, which is like polymorphism in most mainstream programming languages.defmultiis a more general mechanism where you can dispatch on other things than just a single type. This flexibility comes with a performance penalty.More on protocols
More on multimethods