Closed
Conversation
* Implement project metadata metrics * Implement metric metadata integration tests * Tweak methods so tests don't fail on Linux machines * Repair failing integration test * Implement proper exception handling for subprocesses * Format according to standard * Refactor function names and encryption logic * Remove unnecessary file * Add type hints to new functions
* Implement event data structure and relevant unit tests * Implement requested changes * Remove unused (useless) file * Remove unnecessary ABC class
* Implement tracker methods * Improve readability of Event's __repr__ method * Add method to convert Event to dictionary for JSON-compatibility
* Send Event metrics via Telemetry * Add unit tests for event telemetry * Simplify event telemetry unit tests * Clean up unit tests
* Add BuildRuntime Events * Remove unnecessary file * Prevent tracked Event 'spillage' from previous tests * Fix builder logic * Redefine BuildRuntime to focus on function runtimes * Remove unnecessary file (again)
* Add UsedFeature command and trackers * Remove LocalTest events Events regarding sam local will be implemented at a later time. * Prevent methods from failing if track_event fails * Reformat code to match current standard * Use correct string formatting * Use proper LOG message
* Add thread lock to EventTracker * Place lock in appropriate methods
* Add new attributes to Event datastructure * Fix non-JSON-serializable field in Event * Fix repr to ensure SQL casting will work * Add comment for timestamp method clarity
* Add framework for Event-sending method * Perform some general refactors and cleanup * Implement EventTracker Telemetry unit tests * Cleanup tests and unused imports * Update Metric name for consistency * Repair failing unit test * (Hopefully) repair broken integration test * *Actually* repair broken integration test I had the >= logic backwards lol * Fix integration test For sure this time * Really fix the integration test Windows development is not fun * Properly fix integration test * Reformat files * Implement requested changes * Add Lock logic to send_events method * Implement requested changes * Repair failing tests
* Upgrade encryption algorithm from SHA1 to SHA256 * Make return value of hash JSON-serializable
* Switch send_events to thread when at capacity * Repair failing unit test
Merge `develop` into `customer-journey`
* Add workflow_config events * Refactor workflow Events * Add tests for verifying workflow events * Remove redundant (UsedFeature, ESBuild) event * Repair failing unit test * Rename workflow event to prevent ambiguity
* Apply minor changes (some major) * Add session_id for multithreaded send_events * Adjust tests for new multithreading * Fix failing integration test * *Actually* fix failing integration test * Properly fix integration test * This time for sure * Really really repair that test * OK this one SHOULD work I swear * This time for sure * FIX INTEGRATION TEST * IT'S A LIST * Remove unused imports * Add debug log for EventTracker session ID * Place debug log in better position
Contributor
|
Superseded by #5208 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why is this change necessary?
This change decouples the logic of reading/writing TOML documents from the
SamConfigclass, allowing for the future implementation of additionalsamconfigfile types. It also allows the class to better follow the Single Responsibility Principle, as it handles the logic of storing and representing the config data, rather than also implementing the reading and writing.How does it address the issue?
The
SamConfighas been changed such thatdocumentis now no longer a TOML document, but a dictionary object, making it easier to interface with. In addition, two new classes, the abstractFileManagerand concrete childTomlFileManagerhave been created to handle the logic of reading and writing to TOML files.What side effects does this change have?
The
SamConfigclass now more accurately represents and encapsulates solely the configuration options, and any reading and writing to TOML files has now been generalized to a designatedFileManager, assigned based on the provided filename, and set to be TOML by default to ensure backwards compatibility.Mandatory Checklist
PRs will only be reviewed after checklist is complete
make prpassesmake update-reproducible-reqsif dependencies were changedBy submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.