@Override
  public ProtobufSystemInfo.Section toProtobuf() {
    ProtobufSystemInfo.Section.Builder protobuf = ProtobufSystemInfo.Section.newBuilder();
    protobuf.setName("ALMs");

    try (DbSession dbSession = dbClient.openSession(false)) {
      List<AlmSettingDto> almSettingDtos = dbClient.almSettingDao().selectAll(dbSession);

      for (AlmSettingDto almSettingDto : almSettingDtos) {
        setAttribute(protobuf, almSettingDto.getKey(), buildValue(almSettingDto));
      }
    }

    return protobuf.build();
  }
@Test
  public void null_url_are_ignored() {
    AlmSettingDto azure = db.almSettings().insertAzureAlmSetting(a -> a.setUrl(null));

    ProtobufSystemInfo.Section section = underTest.toProtobuf();

    assertThat(section.getAttributesList()).hasSize(1);
    assertThat(section.getAttributesList())
      .extracting(Attribute::getKey, Attribute::getStringValue)
      .containsExactlyInAnyOrder(
        tuple(azure.getKey(), String.format("Alm:%s", azure.getRawAlm())));
  }