entity-manager unexpected handling of template parameters

Patrick Venture venture at google.com
Sat Aug 10 02:53:11 AEST 2019


Given the following:

busctl introspect --no-pager xyz.openbmc_project.FruDevice
/xyz/openbmc_project/FruDevice/Altie
NAME                                TYPE      SIGNATURE RESULT/VALUE
            FLAGS
org.freedesktop.DBus.Introspectable interface -         -
            -
.Introspect                         method    -         s
            -
org.freedesktop.DBus.Peer           interface -         -
            -
.GetMachineId                       method    -         s
            -
.Ping                               method    -         -
            -
org.freedesktop.DBus.Properties     interface -         -
            -
.Get                                method    ss        v
            -
.GetAll                             method    s         a{sv}
            -
.Set                                method    ssv       -
            -
.PropertiesChanged                  signal    sa{sv}as  -
            -
xyz.openbmc_project.FruDevice       interface -         -
            -
.ADDRESS                            property  u         82
            emits-change
.BOARD_LANGUAGE_CODE                property  s         "25"
            emits-change
.BOARD_MANUFACTURER                 property  s         "Inventec"
            emits-change
.BOARD_MANUFACTURE_DATE             property  s         "Thu Jul 11
17:09:00 2019" emits-change
.BOARD_PART_NUMBER                  property  s         "1051867-01"
            emits-change
.BOARD_PRODUCT_NAME                 property  s         "Altie"
            emits-change
.BOARD_SERIAL_NUMBER                property  s
"ALTIVT192700026"          emits-change
.BUS                                property  u         1
            emits-change
.Common_Format_Version              property  s         "1"
            emits-change

I expected entity-manager with this profile to populate dbus properly:
configurations/altie.json
{
    "Name" : "Altie",
    "Probe" : "xyz.openbmc_project.FruDevice({'BOARD_PRODUCT_NAME': 'Altie'})",
    "Type": "Board",
    "xyz.openbmc_project.Inventory.Decorator.Asset": {
        "Manufacturer": "$BOARD_MANUFACTURER",
        "Model": "$BOARD_PRODUCT_NAME",
        "PartNumber": "$BOARD_PART_NUMBER",
        "SerialNumber": "$BOARD_SERIAL_NUMBER"
    }
}

Instead:
root at semitruck:~# busctl introspect --no-pager
xyz.openbmc_project.EntityManager
/xyz/openbmc_project/inventory/system/board/Altie
NAME                                          TYPE      SIGNATURE
RESULT/VALUE                             FLAGS
org.freedesktop.DBus.Introspectable           interface -         -
                                    -
.Introspect                                   method    -         s
                                    -
org.freedesktop.DBus.Peer                     interface -         -
                                    -
.GetMachineId                                 method    -         s
                                    -
.Ping                                         method    -         -
                                    -
org.freedesktop.DBus.Properties               interface -         -
                                    -
.Get                                          method    ss        v
                                    -
.GetAll                                       method    s
a{sv}                                    -
.Set                                          method    ssv       -
                                    -
.PropertiesChanged                            signal    sa{sv}as  -
                                    -
xyz.openbmc_project.AddObject                 interface -         -
                                    -
.AddObject                                    method    a{sv}     -
                                    -
xyz.openbmc_project.Inventory.Decorator.Asset interface -         -
                                    -
.Manufacturer                                 property  s
"$BOARD_MANUFACTURER"                    emits-change
.Model                                        property  s
"$BOARD_PRODUCT_NAME"                    emits-change
.PartNumber                                   property  s
"$BOARD_PART_NUMBER"                     emits-change
.SerialNumber                                 property  s
"$BOARD_SERIAL_NUMBER"                   emits-change
xyz.openbmc_project.Inventory.Item.Board      interface -         -
                                    -
.Name                                         property  s
"Altie"                                  emits-change
.Probe                                        property  s
"xyz.openbmc_project.FruDevice({\'BOA... emits-change
.Type                                         property  s
"Board"                                  emits-change

I must be doing something obvious and silly.  Please advise.

Thanks,
Patrick


More information about the openbmc mailing list