Supporting tight coupling in a componentized framework #323
tclune
started this conversation in
Ideas / Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In the early days of ESMF development, the GMAO pressured the ESMF core team to introduce a callback mechanism that enables flexibility and tight coupling between components. I think it is fair to say that the core team provided this feature rather reluctantly, and I suspect that only GMAO/GEOS are still using it today.
For those that are unfamiliar, the callback mechanism in ESMF allows you to associate a procedure with an ESMF state. That procedure can then be called through ESMF with the state becoming the primary argument to the procedure. Generally, the provider constructs a state, attaches the procedure, and then passes the state as an item in its export state. The consumer expects such a state in its import state and has some idea of which subitems are to be filled in prior to the call. The consumer makes the call and then extracts the output subitems.
As an example, GEOS uses this to allow radiation to calculate optical properties of aerosols. The radiation gridcomp does not know which aerosol gridcomp is being used (and GEOS has several). Most ESMs do not have such fine-grained gridded components, so this approach might be doubly unfamiliar.
An interesting discussion is whether or not such use of callbacks is a violation of the spirit of componentization. I think that it is fair to say that that it is properly encapsulated.
I raise the issue, because we (GMAO) are contemplating an even heavier use of callbacks to support tight coupling between turbulence and surface components (land, seaicethermo, etc.) I am not an Earth scientist myself, and am left wondering how other models deal with turbulence in this context. It seems to me they either (1) do not have tight coupling or (2) achieve coupling through other means.
I'm hoping for a new idea, as I'm not happy with any of the design options I'm currently facing.
Beta Was this translation helpful? Give feedback.
All reactions