-
Notifications
You must be signed in to change notification settings - Fork 143
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
Simplify environment variable object for more compact data representation; removes truncation indicator #1288
Conversation
…tion; removes truncation indicator (#9) Signed-off-by: Anthony Chan <antchan2@cisco.com>
Signed-off-by: Anthony Chan <antchan2@cisco.com>
c0eac64
to
3cf9d3d
Compare
I like it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Do we wanna remove the long_string object as well? We can add it down the road if needed. Or do folks see value in it? @mikeradka @zschmerber @davemcatcisco |
Hm, good point. I am sure there could be potential down the road for this object, but as of this PR this object would be unreferenced. I suppose since this is merged now, we could either do a subsequent PR to remove this object, or keep the unreferenced object. Maybe in the spirit of keeping the schema clean, we do a follow up PR to remove the |
long_string is still used for script content |
Ah, good eye. I think that answers that! |
@antchan2 Ah, good catch! Thanks. |
Yes, script content was the original reason for adding it, I think. |
Related Issue:
Fixes ocsf-schema#1272
Description of changes:
Simplify data representation for environment variables array by changing the type of
name
andvalue
fromlong_string
tostring
. This removes truncation indicators from those fields but this is a worthwhile trade-off to vastly simplify the general case since truncation is a rare occurrence.environment_variable
remains a separate class (i.e., not reuse theKey:Value
object) so it can be extended to more elegantly handle truncation, if there turns out to be a real need, in the future.