Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate version information to device.runtimeVersions #141

Merged
merged 9 commits into from
Apr 25, 2019

Conversation

fractalwrench
Copy link
Contributor

Goal

We should collect the following information in the device.runtimeVersions section of the payload:

  • Java version
  • Java type (runtime environment)
  • Spring version
  • Spring Boot version

Changeset

  • Moved device.runtimeName to device.runtimeVersions.javaType
  • Moved device.runtimeVersion to device.runtimeVersions.javaVersion
  • Moved device.metaData.springVersion to device.runtimeVersions.springFramework
  • Moved device.metaData.springBootVersion to device.runtimeVersions.springBoot
  • Added package-visible BeforeSendSessions callback which is invoked immediately before session delivery and allows mutation of the payload
  • Added Spring/Spring Boot session callbacks that add runtime version info for sessions

Tests

Ran existing tests, and added new mazerunner scenarios to verify that version info is included in both errors/sessions for a plain, Spring, and Spring Boot app.

Cawllec
Cawllec previously approved these changes Apr 17, 2019
Copy link
Contributor

@Cawllec Cawllec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests LGTM

Copy link
Contributor

@bengourley bengourley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like the retrieveRuntimeVersionsMap method's functionality should be moved to the report class. That way it can have a name that is more indicative of what it's going to do.

There may be a good reason not to do this that I'm not aware of. If so I think the method could just do with a better name. It seems odd to have "map" in the name when that information is provided by the type system.

bugsnag/src/main/java/com/bugsnag/Diagnostics.java Outdated Show resolved Hide resolved
@fractalwrench fractalwrench dismissed Cawllec’s stale review April 24, 2019 10:37

Dismissing to avoid review confusion as per slack conversation

@fractalwrench fractalwrench merged commit d7ab7b7 into next Apr 25, 2019
@fractalwrench fractalwrench deleted the runtime-versions branch April 25, 2019 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants