Skip to content

EclWriter: forward dynamically created well connections to EclipseIO - #7328

Merged
bska merged 2 commits into
OPM:masterfrom
hnil:pr/eclwriter-dynamic-conns
Aug 28, 2026
Merged

EclWriter: forward dynamically created well connections to EclipseIO#7328
bska merged 2 commits into
OPM:masterfrom
hnil:pr/eclwriter-dynamic-conns

Conversation

@hnil

@hnil hnil commented Aug 17, 2026

Copy link
Copy Markdown
Member

recordNewDynamicWellConns() hands well name plus zero-based Cartesian cell ids for dynamically created connections to the output layer on the I/O rank, so the summary engine can instantiate connection-level vectors for them.

The receiving side already exists in opm-common (Summary::recordNewDynamicWellConns); this is only the simulator-side forwarding. Nothing upstream calls it yet — it is needed by a fracture model that creates connections during the run, which lives out of tree.

12 lines, inert without such a caller.

@hnil hnil added the manual:enhancement This is an enhancement/improvent that needs to be documented in the manual label Aug 17, 2026
@hnil
hnil marked this pull request as ready for review August 19, 2026 08:23
@hnil
hnil force-pushed the pr/eclwriter-dynamic-conns branch from 33919b6 to 86f2158 Compare August 19, 2026 08:23
@hnil
hnil requested review from svenn-t and totto82 August 20, 2026 09:51

@svenn-t svenn-t left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have any knowledge about dynamic well connections, so I only have some minor comments.

Comment thread opm/simulators/flow/EclWriter.hpp
Comment thread opm/simulators/flow/EclWriter.hpp Outdated

void recordNewDynamicWellConns(const DynamicConns& newConns)
{
if ((this->rank_ == 0) && (this->eclIO_ != nullptr)) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for consistency, use isIORank() instead of this->rank_ == 0


public:

using DynamicConns =

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use out::Summary::DynamicConns instead?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use out::Summary::DynamicConns instead?

Maybe. That would require including opm-common's Summary.hpp header here.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I don't know if that has larger implications, so I'll leave it to you. Just noted the duplication.

@svenn-t

svenn-t commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

jenkins build this please

recordNewDynamicWellConns() passes fracture-created connections (well name
+ zero-based Cartesian cell ids) to the output layer on the I/O rank, so
the summary engine can instantiate connection-level vectors for them
(opm-common already provides the receiving API).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@hnil
hnil force-pushed the pr/eclwriter-dynamic-conns branch from 86f2158 to 3612d06 Compare August 28, 2026 11:57
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@bska

bska commented Aug 28, 2026

Copy link
Copy Markdown
Member

jenkins build this please

@hnil

hnil commented Aug 28, 2026

Copy link
Copy Markdown
Member Author

@svenn-t both taken:

  • isIORank() instead of comparing the rank directly — done.
  • out::Summary::DynamicConns: kept the local alias, for bska's reason. Using opm-common's type means pulling Summary.hpp into EclWriter.hpp, a heavy header for a two-line alias that everything including the writer would then carry. The duplication is real; this looked like the cheaper of the two. Happy to switch if you would rather have the single definition.

@bska bska left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for the updates. I think this looks good now. Unless someone really objects, I think this should go into the master branch.

@svenn-t svenn-t left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

@bska

bska commented Aug 28, 2026

Copy link
Copy Markdown
Member

Looks good to me!

Cool, thanks! In that case I'll merge this into the master branch.

@bska
bska merged commit 5e1a132 into OPM:master Aug 28, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

manual:enhancement This is an enhancement/improvent that needs to be documented in the manual

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants