Skip to content

logs: Support all flags for builds and deployments - #5396

Merged
openshift-bot merged 2 commits into
openshift:masterfrom
0xmichalis:bundle-podlogoptions
Oct 30, 2015
Merged

openshift-bot merged 2 commits into
openshift:masterfrom
0xmichalis:bundle-podlogoptions

Conversation

@0xmichalis

Copy link
Copy Markdown
Contributor

@deads2k podLogOptions doesn't deserialize correctly in the server and I am not sure what else am I missing...

I had to update v1beta3 conversions manually (both in Origin and Kube) and updating swagger doesn't work too.

Fixes #5070, https://bugzilla.redhat.com/show_bug.cgi?id=1273948, and https://bugzilla.redhat.com/show_bug.cgi?id=1273817.

@deads2k

deads2k commented Oct 26, 2015

Copy link
Copy Markdown
Contributor

@deads2k podLogOptions doesn't deserialize correctly in the server and I am not sure what else am I missing...

@smarterclayton I remember you said the query parameter deserialization had limitations. Are anonymous structs one of those limitations?

@smarterclayton

Copy link
Copy Markdown
Contributor

Anonymous inline structs. PodLogOptions has worked for a while (unless
you're embedding it).

On Mon, Oct 26, 2015 at 10:00 AM, David Eads [email protected]
wrote:

@deads2k https://github.com/deads2k podLogOptions doesn't deserialize
correctly in the server and I am not sure what else am I missing...

@smarterclayton https://github.com/smarterclayton I remember you said
the query parameter deserialization had limitations. Are anonymous structs
one of those limitations?

—
Reply to this email directly or view it on GitHub
#5396 (comment).

@0xmichalis

Copy link
Copy Markdown
Contributor Author

that's a pity

@0xmichalis

Copy link
Copy Markdown
Contributor Author

Is it possible to inline named structs?

@deads2k

deads2k commented Oct 27, 2015

Copy link
Copy Markdown
Contributor

Is it possible to inline named structs?

No. Looks like it might be into the deserialization code for you :)

@smarterclayton

Copy link
Copy Markdown
Contributor

There's no way conversion changes will go into 3.1, so if you need it this
is going to get deferred.

On Tue, Oct 27, 2015 at 7:50 AM, David Eads [email protected]
wrote:

Is it possible to inline named structs?

No. Looks like it might be into the deserialization code for you :)

—
Reply to this email directly or view it on GitHub
#5396 (comment).

@0xmichalis

Copy link
Copy Markdown
Contributor Author

@deads2k I prefer we defer adding PodLogOptions to our logOptions objects until the converion gets fixed. In the meantime, we can add all the PodLogOptions fields manually if we really want full logs support for builds/deployments. WDYT?

@deads2k

deads2k commented Oct 27, 2015

Copy link
Copy Markdown
Contributor

@deads2k I prefer we defer adding PodLogOptions to our logOptions objects until the converion gets fixed. In the meantime, we can add all the PodLogOptions fields manually if we really want full logs support for builds/deployments. WDYT?

I'm ok with deferring, I don't want to ship APIs we don't like.

@0xmichalis

Copy link
Copy Markdown
Contributor Author

+1

On Tue, Oct 27, 2015 at 6:40 PM, David Eads [email protected]
wrote:

@deads2k https://github.com/deads2k I prefer we defer adding
PodLogOptions to our logOptions objects until the converion gets fixed. In
the meantime, we can add all the PodLogOptions fields manually if we really
want full logs support for builds/deployments. WDYT?

I'm ok with deferring, I don't want to ship APIs we don't like.

—
Reply to this email directly or view it on GitHub
#5396 (comment).

@deads2k

deads2k commented Oct 27, 2015

Copy link
Copy Markdown
Contributor

@Kargakis based on IRC, @smarterclayton wants the functionality. That means manually including the values, writing reflective tests to ensure we don't drift, and being chased by un-deserializeable spiders.

@0xmichalis

Copy link
Copy Markdown
Contributor Author

@deads2k added the fields manually and wrote reflective tests. PTAL

Comment thread pkg/build/api/validation/validation.go Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

build the PodLogOptions and call teh correct validate method.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

build the PodLogOptions and call teh correct validate method.

The logic to build it should probably be the api/helpers.go since somewhere else will need to do it too

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

ok

@deads2k

deads2k commented Oct 29, 2015

Copy link
Copy Markdown
Contributor

@smarterclayton API changes. The query parameter serialization has forced ugliness.

@smarterclayton

Copy link
Copy Markdown
Contributor

API approved

@deads2k

deads2k commented Oct 29, 2015

Copy link
Copy Markdown
Contributor

@Kargakis descriptions and then lgtm.

@deads2k

deads2k commented Oct 29, 2015

Copy link
Copy Markdown
Contributor

added descriptions. are these supposed to be picked up by swagger? because I can't see any diff when trying to update the spec

Yes the descriptions should be included in the swagger. Try make clean build and generate them again?

@0xmichalis

Copy link
Copy Markdown
Contributor Author

[test]

@0xmichalis

Copy link
Copy Markdown
Contributor Author

Yes the descriptions should be included in the swagger. Try make clean build and generate them again?

Fields like Follow and NoWait already had description fields but I don't see them in the spec. That's why I cannot get any diff from the rest.

@0xmichalis

Copy link
Copy Markdown
Contributor Author

Please hold off merging this until #5393 gets in.

@deads2k

deads2k commented Oct 29, 2015

Copy link
Copy Markdown
Contributor

@0xmichalis

Copy link
Copy Markdown
Contributor Author

I think it's pretty straightforward, will add and test it tomorrow.

On Thu, Oct 29, 2015 at 7:05 PM, David Eads [email protected]
wrote:

@deads2k https://github.com/deads2k
https://github.com/kubernetes/kubernetes/blob/848fed8f4b811d7343d2b012708820817826837e/pkg/client/unversioned/request.go#L410

How easy or hard is that to make use of here?

—
Reply to this email directly or view it on GitHub
#5396 (comment).

@0xmichalis

Copy link
Copy Markdown
Contributor Author

Works fine. PTAL in client/buildlogs.go and client/deplyomentlogs.go

@openshift-bot

Copy link
Copy Markdown
Contributor

Evaluated for origin test up to 298c6b4

@openshift-bot

Copy link
Copy Markdown
Contributor

@deads2k

deads2k commented Oct 30, 2015

Copy link
Copy Markdown
Contributor

Works fine. PTAL in client/buildlogs.go and client/deplyomentlogs.go

Much nicer.

lgtm, merge in the order you like, but #5393 is cursed.

@0xmichalis

Copy link
Copy Markdown
Contributor Author

Ok, let's [merge] this for a change.

@openshift-bot

Copy link
Copy Markdown
Contributor

continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin/6429/) (Image: devenv-rhel7_2606)

@openshift-bot

Copy link
Copy Markdown
Contributor

Evaluated for origin merge up to 298c6b4

openshift-bot pushed a commit that referenced this pull request Oct 30, 2015
@openshift-bot
openshift-bot merged commit c0d32ee into openshift:master Oct 30, 2015
@0xmichalis
0xmichalis deleted the bundle-podlogoptions branch October 30, 2015 16:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants