Skip to content

Navigation Menu

Sign in
Sign up

feat: state the device's own address in origin.ip - #60

Merged
DavidCozens merged 1 commit into
main from
stage-12-origin-ip
Aug 16, 2026
Merged

feat: state the device's own address in origin.ip #60
DavidCozens merged 1 commit into
main from
stage-12-origin-ip

Conversation

@DavidCozens

@DavidCozens DavidCozens commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

Add the ip PARAM to the origin element, sourced from the same interface address the HOSTNAME field
reports.

struct SolidSyslogOriginSdConfig originConfig = {
 /* ... as the previous stage ... */
 .GetIpCount = SyslogOriginIpCount,
 .GetIpAt = SyslogOriginIpAt,
};
... [origin software="solid-syslog-example" swVersion="0.1.0" enterpriseId="32473" ip="10.0.2.15"] device started

A relay or NAT between the device and the collector rewrites the address the collector observes. ip
is what the device says about itself, and that survives the hop.

The PARAM is repeatable, so the library asks for a count and then one value per index rather than
taking a single string. This device has one address and returns one, and returns none before the
interface has an address — a count of zero omits the PARAM rather than emitting an empty one.

SyslogFields_IpAddress becomes the single place that reads the address, and HOSTNAME formats the
same string through it. Two fields that must agree now cannot disagree.

Four elements put the record at 260 octets.

coderabbitai Bot commented Aug 16, 2026
edited
Loading

Copy link
Copy Markdown

Note

Reviews paused

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

coderabbitai Bot commented Aug 16, 2026
edited
Loading

Copy link
Copy Markdown
⚠️ Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
Copy Markdown
Contributor Author

Base automatically changed from stage-11-origin to main August 16, 2026 17:57
The ip PARAM, sourced from the same interface address HOSTNAME reports. A relay
or NAT between device and collector rewrites what the collector observes; ip is
what the device says about itself, which survives the hop.
 Flash +12,380 B (+392 on the previous stage)
 RAM +9,172 B (unchanged)
 Log stack +680 B (+8)
 Service +960 B (unchanged)
ip is repeatable, so the library asks for a count and then one value per index
rather than taking a string. This device has one address and returns one, and
none before the interface has an address — a count of zero omits the PARAM rather
than emitting an empty one.
SyslogFields_IpAddress is now the single place that reads the address, and
HOSTNAME formats the same string through it, so two fields that must agree cannot
disagree.
Four elements put the record at 260 octets.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
DavidCozens merged commit ec68eb2 into main Aug 16, 2026
1 check passed

coderabbitai Bot commented Aug 16, 2026

Copy link
Copy Markdown
✅ Action performed

Reviews paused.

DavidCozens deleted the stage-12-origin-ip branch August 16, 2026 17:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /