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

data logging #20

Merged
merged 4 commits into from
Oct 2, 2018
Merged

data logging #20

merged 4 commits into from
Oct 2, 2018

Conversation

pq
Copy link
Owner

@pq pq commented Oct 1, 2018

Follow-up from #19.

I opted to add data to the log call but we could add a logData call instead. I don't have a strong preference...

(Aside: It'll be interesting to see how much of a drag all of these closures are in practice.)

/cc @devoncarew

Copy link
Contributor

@devoncarew devoncarew left a comment

Choose a reason for hiding this comment

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

Hey - not a lot of opinions here, but:

  • a dedicated logData call could be useful, esp. to indicate that we have a prescriptive way to write the data
  • if we're very proscriptive of what kind of data we can log (Map<String, Object>?), I wonder if we need both LogDataCallback data and ToJsonEncodable toJsonEncodablecallbacks? The LogDataCallback could just return a Map, and we'd document that all the objects in it needed to be jsonable (or, string, maps, lists, and ints)?

@pq
Copy link
Owner Author

pq commented Oct 2, 2018

Thanks for the feedback!

I'll land this for now but add notes to #19 to capture your ideas. I'll take another pass after we've talked through some of the ideas from my conversation w/ the apptree folks.

@pq pq merged commit ad7254c into master Oct 2, 2018
@pq pq mentioned this pull request Oct 2, 2018
@devoncarew
Copy link
Contributor

Hey - I used this API to pass structured data back from my sample app, and to log http headers back for network traffic. 👍 it worked great

@pq
Copy link
Owner Author

pq commented Oct 3, 2018

Great to hear!

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.

2 participants