<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BMC/OpenBmc/bmcweb.git/redfish-core/include/utils/eventlog_utils.hpp, branch master</title>
<subtitle>A do everything Redfish, KVM, GUI, and DBus webserver for OpenBMC (mirror)</subtitle>
<id>https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/atom?h=master</id>
<link rel='self' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/'/>
<updated>2026-09-19T14:51:47+00:00</updated>
<entry>
<title>Refactor eventlog_utils respHandler lambdas</title>
<updated>2026-09-19T14:51:47+00:00</updated>
<author>
<name>Yuvakumar Selvamani</name>
<email>yuvakumars@ami.com</email>
</author>
<published>2026-08-17T12:01:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=384a6b3e04d20f615cbc33260b4fb572f8749818'/>
<id>urn:sha1:384a6b3e04d20f615cbc33260b4fb572f8749818</id>
<content type='text'>
The dBusEventLogEntryDelete and dBusLogServiceActionsClear functions
each contained an inline respHandler lambda that triggered the
long-lambda ast-grep rule, requiring an inline suppression
(// ast-grep-ignore: long-lambda).

This commit extracts each lambda into a separate named function,
afterDBusEventLogEntryDelete and afterDBusLogServiceActionsClear
respectively, and uses std::bind_front to handle the asynchronous
callback. This aligns the code with the preferred bmcweb pattern for
D-Bus callbacks, improves readability, and allows the removal of the
static analysis suppressions.

Tested on AST2600 SoC (with PACKAGECONFIG `redfish-dbus-log` enabled;
disabled by default).
- `DELETE .../EventLog/Entries/1` (real entry)
  Expected: HTTP 200 Base.1.19.Success, entry removed
  Actual:   HTTP 200 Base.1.19.Success, entry removed
- `DELETE .../EventLog/Entries/999` (nonexistent)
  Expected: HTTP 404 Base.1.19.ResourceNotFound
  Actual:   HTTP 404 Base.1.19.ResourceNotFound
- `POST .../EventLog/Actions/LogService.ClearLog`
  Expected: HTTP 200 Base.1.19.Success, all entries cleared
  Actual:   HTTP 200 Base.1.19.Success, all entries cleared
- RSV: 5845 Pass / 353 Warn / 0 Fail

Change-Id: I323a0813fef4f04622a71f27258fe9b1930ec6cd
Signed-off-by: Yuvakumar Selvamani &lt;yuvakumars@ami.com&gt;
</content>
</entry>
<entry>
<title>clang-tidy fixes for log services header</title>
<updated>2026-08-26T10:22:49+00:00</updated>
<author>
<name>Oliver Brewka</name>
<email>oliver.brewka@9elements.com</email>
</author>
<published>2026-08-18T09:36:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=bc230aed77bb20fc7a2e6fe7f9d79e01c5fa6ee0'/>
<id>urn:sha1:bc230aed77bb20fc7a2e6fe7f9d79e01c5fa6ee0</id>
<content type='text'>
Silent clang-tidy warnings:

- remove unused header includes
- switch &lt;systemd/sd_bus.h&gt; to &lt;systemd/sd-bus-protocol&gt; for
  sd_bus_error usage
- change str.find usage to str.contains

Tested: Code compiles.

Change-Id: I814239d47e1586ebc28bccc00c08e41f711b9beb
Signed-off-by: Oliver Brewka &lt;oliver.brewka@9elements.com&gt;
</content>
</entry>
<entry>
<title>redfish: Return empty DBus EventLog collection</title>
<updated>2026-07-10T21:04:42+00:00</updated>
<author>
<name>Joel Pullokaran Jesin</name>
<email>joelpj@ami.com</email>
</author>
<published>2026-07-09T13:26:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=0868ab5aa1b32e6922bb7fdc987e247af6e991eb'/>
<id>urn:sha1:0868ab5aa1b32e6922bb7fdc987e247af6e991eb</id>
<content type='text'>
When the DBus-backed EventLog entry collection is unavailable, return
an empty Redfish collection instead of an internal error for expected
absence cases.

Treat EBADR and host_unreachable from GetManagedObjects as optional
backend unavailability. In those cases, populate Members with an
empty array and set Members@odata.count to 0, while continuing to
surface unexpected DBus errors as internal errors.

Tested:
- ninja -C build bmcweb

Change-Id: Iffff05231927f8d2239b25bbbb98960d7b5d71e0
Signed-off-by: Joel Pullokaran Jesin &lt;joelpj@ami.com&gt;
</content>
</entry>
<entry>
<title>Flag long lambdas</title>
<updated>2026-07-01T17:10:08+00:00</updated>
<author>
<name>Ed Tanous</name>
<email>etanous@nvidia.com</email>
</author>
<published>2026-06-22T16:53:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=8176ae6778015743b77e8744c046bc50edf13cc4'/>
<id>urn:sha1:8176ae6778015743b77e8744c046bc50edf13cc4</id>
<content type='text'>
Long lambdas have been documented as an anti-pattern for some time.[1]
Despite this being generally understood, bmcweb has a long ways to go
cleaning these up, and routinely code is submitted in violation of this
anti-pattern.

Invent an ast-grep rule that can identify when new examples of this
anti-pattern are added, and ignore the existing 200+ examples that are
in the codebase already using ast-grep ignore.  These flags will give us
something to search for as we clean this up, and will help to prevent
new instances from being added unintentionally.

[1] https://github.com/openbmc/docs/blob/master/anti-patterns.md#very-long-lambda-callbacks

Tested: Comment only change.  ast-grep passes.  Manually removing an
ast-grep ignore flag shows as a failure in ast-grep scan

Change-Id: I77d634a393884969f184d2c39c02cc08288d5a29
Signed-off-by: Ed Tanous &lt;etanous@nvidia.com&gt;
</content>
</entry>
<entry>
<title>Remove static variables</title>
<updated>2026-04-20T22:36:58+00:00</updated>
<author>
<name>Ed Tanous</name>
<email>etanous@nvidia.com</email>
</author>
<published>2026-04-13T18:53:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=aa2dfd26a514e063d2b62ec32f562cbcd43a21b4'/>
<id>urn:sha1:aa2dfd26a514e063d2b62ec32f562cbcd43a21b4</id>
<content type='text'>
These static variables have the potential to cause reentrancy issues.
In practice, the conditions to cause issues would require someone to
basically write incorrect code, but it makes sense to wrap this into a
state tracker anyway to clean up the code.  While we're here, convert to
using std::chrono.

Note, this changes the behavior such that the values produced are now no
longer dependent on timezone.  Functionally, Redfish only recently got
the ability to set a timezone, so this is not expected to have any user
facing impact, even though the unit tests need to change.

Tested: RSV Passes

Change-Id: Icb7cff1d289ae23790a5fb1db6604abd73dd68fd
Signed-off-by: Ed Tanous &lt;etanous@nvidia.com&gt;
</content>
</entry>
<entry>
<title>Deduplicate function</title>
<updated>2026-04-20T22:36:58+00:00</updated>
<author>
<name>Ed Tanous</name>
<email>etanous@nvidia.com</email>
</author>
<published>2026-04-13T18:52:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=5803072626187a2cc14bd93962a3899ce1fb4695'/>
<id>urn:sha1:5803072626187a2cc14bd93962a3899ce1fb4695</id>
<content type='text'>
These two functions differ in only one minor thing, how the first entry
is handled.  event_log::getUniqueEntryID is better unit tested, so move
to it for all uses.  Next commit will move the static variables out so
the behavior of these two methods is identical.

Tested: in next commit

Change-Id: I7a27d3506a6fec1f62fe8f584dbceb0ac34893ac
Signed-off-by: Ed Tanous &lt;etanous@nvidia.com&gt;
</content>
</entry>
<entry>
<title>sdbusplus: use shorter type aliases</title>
<updated>2026-04-15T01:50:54+00:00</updated>
<author>
<name>Patrick Williams</name>
<email>patrick@stwcx.xyz</email>
</author>
<published>2026-04-14T11:26:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=36498b406abb3be754e84072d50f16d9dcbbfa8f'/>
<id>urn:sha1:36498b406abb3be754e84072d50f16d9dcbbfa8f</id>
<content type='text'>
The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines.  Possible replacements are for:
  * bus_t
  * exception_t
  * manager_t
  * match_t
  * message_t
  * object_t
  * slot_t
  * object_path

Change-Id: Iace20f9ad26e8d9dc234979e7a4087d599da2641
Signed-off-by: Patrick Williams &lt;patrick@stwcx.xyz&gt;
</content>
</entry>
<entry>
<title>Expose date/time in local timezone</title>
<updated>2026-04-10T22:21:27+00:00</updated>
<author>
<name>Igor Kanyuka</name>
<email>ifelmail@gmail.com</email>
</author>
<published>2026-03-24T12:00:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=33d7d41c71bb9a22725d77d97e41114c50b502c0'/>
<id>urn:sha1:33d7d41c71bb9a22725d77d97e41114c50b502c0</id>
<content type='text'>
BMC now exposes DateTime property under the Manager/&lt;ID&gt; in timezone
configured on the BMC (local TZ) and not in UTC, but the other date
time properties are still in UTC.
Convert date time fields to local timezone.

Tested:
1. Redfish service validator
2. Built Facebook's Catalina image with this change, ran in QEMU and
   checked manually varioius endpoints.
3. Ran automated tests [1] from openbmc-test-automation repo.
4. Unit tests

[1] https://gerrit.openbmc.org/c/openbmc/openbmc-test-automation/+/88659

Change-Id: I8e587c7a1030deff8e6a550651c5e62719fe5299
Signed-off-by: Igor Kanyuka &lt;ifelmail@gmail.com&gt;
Signed-off-by: Ed Tanous &lt;ed@tanous.net&gt;
</content>
</entry>
<entry>
<title>Allow to set Manager TZ and show its time in local</title>
<updated>2026-03-20T20:04:48+00:00</updated>
<author>
<name>Igor Kanyuka</name>
<email>ifelmail@gmail.com</email>
</author>
<published>2026-02-23T18:27:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=22c8e70d0c41e06d15b5533f121ae704fbe8a0fb'/>
<id>urn:sha1:22c8e70d0c41e06d15b5533f121ae704fbe8a0fb</id>
<content type='text'>
Current code always return Date time in UTC, despite local timezone may
differ. This change allows to set manager timezone via redfish and show
manager's TZ and offset in manager's local timezone. When the DateTime
is being patched, the provided date time gets converted from the
provided TZ to the local timezone, but configured TZ does not get
changed. A user must explicitly patch TimeZoneName to change Manager's
TZ.

Tested:
1. Built an image, ran in QEMU, changed TZ to PST8PDT (negative offset),
UTC (0 offset), and Tokyo (positive offset). Made sure the patch works
and all the touched fields have correct values. See [1].

2. Unit tests
3. Redfish validator

[1]
```
$ curl -s -k -H 'Content-type: application/json' -u root:0penBmc https://localhost:8443/redfish/v1/Managers/bmc | jq '.DateTime, .DateTimeLocalOffset, .TimeZoneName'
"2026-03-19T11:03:16-07:00"
"-07:00"
"PST8PDT"

$ curl -i -k -H 'Content-type: application/json' -u root:0penBmc -d '{"TimeZoneName": "UTC"}' -X PATCH https://localhost:8443/redfish/v1/Managers/bmc
HTTP/1.1 204 No Content
Allow: GET, PATCH
OData-Version: 4.0
Strict-Transport-Security: max-age=31536000; includeSubdomains
Pragma: no-cache
Cache-Control: no-store, max-age=0
X-Content-Type-Options: nosniff
Date: Thu, 19 Mar 2026 18:03:28 GMT
Content-Length: 0

$ curl -s -k -H 'Content-type: application/json' -u root:0penBmc https://localhost:8443/redfish/v1/Managers/bmc | jq '.DateTime, .DateTimeLocalOffset, .TimeZoneName'
"2026-03-19T18:03:53+00:00"
"+00:00"
"UTC"

$ curl -i -k -H 'Content-type: application/json' -u root:0penBmc -d '{"TimeZoneName": "Asia/Tokyo"}' -X PATCH https://localhost:8443/redfish/v1/Managers/bmc
HTTP/1.1 204 No Content
Allow: GET, PATCH
OData-Version: 4.0
Strict-Transport-Security: max-age=31536000; includeSubdomains
Pragma: no-cache
Cache-Control: no-store, max-age=0
X-Content-Type-Options: nosniff
Date: Thu, 19 Mar 2026 18:04:20 GMT
Content-Length: 0

$ curl -s -k -H 'Content-type: application/json' -u root:0penBmc https://localhost:8443/redfish/v1/Managers/bmc | jq '.DateTime, .DateTimeLocalOffset, .TimeZoneName'
"2026-03-20T03:04:32+09:00"
"+09:00"
"Asia/Tokyo"

$ curl -i -k -H 'Content-type: application/json' -u root:0penBmc -d '{"DateTime": "2026-01-02T11:03:16-07:00"}' -X PATCH https://localhost:8443/redfish/v1/Managers/bmc
HTTP/1.1 204 No Content
Allow: GET, PATCH
OData-Version: 4.0
Strict-Transport-Security: max-age=31536000; includeSubdomains
Pragma: no-cache
Cache-Control: no-store, max-age=0
X-Content-Type-Options: nosniff
Date: Fri, 02 Jan 2026 18:03:16 GMT
Content-Length: 0

$ curl -s -k -H 'Content-type: application/json' -u root:0penBmc https://localhost:8443/redfish/v1/Managers/bmc | jq '.DateTime, .DateTimeLocalOffset, .TimeZoneName'
"2026-01-03T03:03:21+09:00"
"+09:00"
"Asia/Tokyo"

$ curl -s -k -H 'Content-type: application/json' -u root:0penBmc https://localhost:8443/redfish/v1/Managers/bmc/LogServices/Journal/Entries | jq '.Members[0]'
{
  "@odata.id": "/redfish/v1/Managers/bmc/LogServices/Journal/Entries/cz0zNTMzMTVkMTBjYWQ0ZTg5ODJiYjliZGVmOTc2NDE2MDtpPTE7Yj00YzU5NzY1NzQ0M2M0N2IzOWZjYTZiNzU1ZWVlY2NjOTttPTFlZjc1Yzg7dD02MzY0OGQxOTFhZTE0O3g9ZDU5MjYwNzJkZTgzMWYzYw==",
  "@odata.type": "#LogEntry.v1_9_0.LogEntry",
  "Created": "2025-05-29T16:30:41.794580+00:00",
  "EntryType": "Oem",
  "Id": "cz0zNTMzMTVkMTBjYWQ0ZTg5ODJiYjliZGVmOTc2NDE2MDtpPTE7Yj00YzU5NzY1NzQ0M2M0N2IzOWZjYTZiNzU1ZWVlY2NjOTttPTFlZjc1Yzg7dD02MzY0OGQxOTFhZTE0O3g9ZDU5MjYwNzJkZTgzMWYzYw==",
  "Message": "kernel: Booting Linux on physical CPU 0xf00",
  "Name": "BMC Journal Entry",
  "OemRecordFormat": "BMC Journal Entry",
  "Severity": "OK"
}
```

Change-Id: I5a4567b9ca6a0f56dd9d1b971d418a19bf625a10
Signed-off-by: Igor Kanyuka &lt;ifelmail@gmail.com&gt;
</content>
</entry>
<entry>
<title>Use boost::urls::format</title>
<updated>2026-01-20T22:11:48+00:00</updated>
<author>
<name>Brad Bishop</name>
<email>bradbish@qti.qualcomm.com</email>
</author>
<published>2025-09-04T02:04:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/OpenBmc/bmcweb.git/commit/?id=5c170f784baedc3eec4a39a25bd1dc0114254275'/>
<id>urn:sha1:5c170f784baedc3eec4a39a25bd1dc0114254275</id>
<content type='text'>
boost::urls::format is specifically meant for URL construction. It
handles encoding like percentage encoding which std::format does not.

Change-Id: Ief7d574d1652096c2701979a9f8fe9897957f492
Signed-off-by: Brad Bishop &lt;bradbish@qti.qualcomm.com&gt;
</content>
</entry>
</feed>
