Skip to content

aya-log v0.2.0

Compare
Choose a tag to compare
@dave-tucker dave-tucker released this 28 Feb 12:39
· 266 commits to main since this release

Chore

  • Don't use path deps in workspace
    This moves the path dependencies back into the per-crate Cargo.toml.
    It is required such that the release tooling can correctly calculate
    which version constraints require changing when we perform a release.

  • Use the cargo workspace package table
    This allows for inheritance of common fields from the workspace root.
    The following fields have been made common:

    • authors
    • license
    • repository
    • homepage
    • edition

Documentation

  • Add CHANGELOG

New Features

  • check format and value type in proc macro

Bug Fixes

  • remove some useless code

Other

  • group_imports = "StdExternalCrate"
    High time we stop debating this; let the robots do the work.

  • s/Result<usize, ()>/Option/
    Option<NonZeroUsize> is guaranteed to have the same size as usize,
    which is not guarnateed for Result. This is a minor optimization, but
    also results in simpler code.

  • Define dependencies on the workspace level
    This way we will avoid version mismatches and make differences in
    features across our crates clearer.

  • add formatter and check in CI

  • Unify IP format hints into one, repsesent it by :i token
    Having separate format hints and tokens per IP address family is
    unnecessary, since they are represented by different types and we handle
    format hints for each type separately. So we can just have one format
    hint.

    Also, we should be consistent with the format strings grammar in
    Rust[0]. The type token, which is mapped to formatting traits, usually
    consists of one letter[1] (and optional ? for Debug trait, but that
    doesn't matter for us). It shouldn't consist of multiple letters. Our
    :ipv4 and :ipv6 tokens were clearly breaking that convention, so we
    should rather switch to something with one letter - hence :i.

    [0] https://doc.rust-lang.org/std/fmt/#syntax
    [1] https://doc.rust-lang.org/std/fmt/#formatting-traits

  • support logging byte slices
    These only support LowerHex and UpperHex hints for now.

  • check errors in tests

  • Move the Pod implementations from aya-log-common to aya-log
    Keeping the Pod implementations and optional dependency on aya in
    aya-log-common breaks the clippy checks (which are made on the entire
    workspace).

    The reason is that when different crates inside the workspace have the
    same dependency with different features, that dependency is built only
    once with the sum of features needed by all crates. It's not being
    built separately with different feature sets.

    That's why, before this change, aya-log-common was built once for the
    entire workspace with userspace feature enabled. That made importing
    aya-log-ebpf inside integration-ebpf impossible. The aya-log-common
    build, with userspace feature enabled, was pulling std as a
    dependency. Therefore, importing aya-log-ebpf inside integration-ebpf
    resulted in including std and errors like:

    error[E0152]: found duplicate lang item `panic_impl`
      --> test/integration-ebpf/src/log.rs:23:1
       |
    23 | fn panic(_info: &core::panic::PanicInfo) -> ! {
       | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
       |
       = note: the lang item is first defined in crate `std` (which `aya` depends on)
    

    This change fixes the problem by removing the userspace feature from
    aya-log-common and moving the Pod implementations to aya-log.

  • update env_logger requirement from 0.9 to 0.10
    Updates the requirements on env_logger to permit the latest version.


    updated-dependencies:

    • dependency-name: env_logger
      dependency-type: direct:production
      ...

Commit Statistics

  • 37 commits contributed to the release over the course of 469 calendar days.
  • 469 days passed between releases.
  • 14 commits were understood as conventional.
  • 0 issues like '(#ID)' were seen in commit messages

Commit Details

view details
  • Uncategorized
    • Add CHANGELOG (9abb716)
    • Release aya-log-common v0.1.14, aya-log v0.2.0 (c22a696)
    • Release aya-obj v0.1.0, aya v0.12.0, safety bump aya-log v0.2.0 (0e99fa0)
    • Don't use path deps in workspace (13b1fc6)
    • Merge pull request #882 from dave-tucker/metadata (0fadd69)
    • Use the cargo workspace package table (b3e7ef7)
    • Appease rustc dead_code lint (963dd13)
    • Merge pull request #797 from aya-rs/rustfmt-group-imports (373fb7b)
    • Group_imports = "StdExternalCrate" (d16e607)
    • Merge pull request #736 from aya-rs/logging-better (45df251)
    • Merge pull request #735 from aya-rs/log-option-not-result (ecf0dd9)
    • S/Result<usize, ()>/Option/ (ca3f70b)
    • Remove pointless DefaultLogger (00d265c)
    • Merge pull request #667 from vadorovsky/workspace-dependencies (f554d42)
    • Define dependencies on the workspace level (96fa08b)
    • Merge pull request #666 from aya-rs/toml-fmt (dc3b0b8)
    • Add formatter and check in CI (c8bf646)
    • Merge pull request #650 from aya-rs/test-cleanup (61608e6)
    • Remove "async" feature (fa91fb4)
    • Unify IP format hints into one, repsesent it by :i token (84e5e28)
    • Remove some useless code (d999a95)
    • Check format and value type in proc macro (0970300)
    • Merge pull request #585 from probulate/tag-len-value (5165bf2)
    • Support logging byte slices (d9f966e)
    • Aya-log, aya-log-common: economize bytes (a4a69a6)
    • Check errors in tests (e4537e3)
    • Aya-log, aya-log-common: Remove duplicate struct (490d7d5)
    • Merge pull request #591 from vadorovsky/aya-log-impl-pod (3d3ce8b)
    • Move the Pod implementations from aya-log-common to aya-log (5603d72)
    • Merge pull request #484 from vadorovsky/update-tokio (bea0e83)
    • Update Tokio and inventory (dad75f4)
    • Don't panic in init when bpf programs don't log (12927cf)
    • Merge pull request #456 from dmitris/uninlined_format_args (16b029e)
    • Fix uninlined_format_args clippy issues (055d94f)
    • Merge pull request #449 from aya-rs/dependabot/cargo/env_logger-0.10 (f9bef9f)
    • Update env_logger requirement from 0.9 to 0.10 (1c8088b)
    • Revert "aya-log, aya-log-common: temporarily revert to old map API so we can release" (0b41018)