# Understanding data movement with Distributed.jl

**URL:** <https://discourse.julialang.org/t/understanding-data-movement-with-distributed-jl/100680>\
**Category:** General Usage\
**Tags:** distributed\
**Created:** [June 22, 2023, 12:55am UTC](https://discourse.julialang.org/t/understanding-data-movement-with-distributed-jl/100680 "2023-06-22T00:55:22Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![lmtzx9h4qqnt](https://avatars.discourse-cdn.com/v4/letter/l/74df32/32.png) [@lmtzx9h4qqnt](https://discourse.julialang.org/u/lmtzx9h4qqnt)\
**Post date:** [September 2, 2024, 11:00pm UTC](https://discourse.julialang.org/t/understanding-data-movement-with-distributed-jl/100680/2 "2024-09-02T23:00:02Z")

</div>

Regarding the question of why “named” functions behave differently from anonymous functions for serialization, I just came across this post in a different thread:

> [@\`foo = () -\> 3\` vs. \`foo() = 3\`](https://discourse.julialang.org/t/foo-3-vs-foo-3/59710/8):
>
> Just for completeness, another small difference is how they’re serialized. For the anonymous version, the function definition is actually serialized, where as the non-anonymous one just the name is serialized. The niche place where this might come up is when using Distributed’s auto-global shipping, so e.g. this works, foo = () -\> 3 @fetch foo() # foo definition shipped to worker, run there, answer returned whereas the non-anonymous version you need to have foo actually defined on all workers …

---

_[View the full topic](https://discourse.julialang.org/t/understanding-data-movement-with-distributed-jl/100680)._
