kite-sdk / kite

Kite SDK
http://kitesdk.org/docs/current/
Apache License 2.0
394 stars 263 forks source link

KITE-1081 FS writers to use the current view schema #421

Closed megnataraj closed 8 years ago

megnataraj commented 8 years ago

I am not sure if you got a chance to look into my latest commit addressing all your comments. After adding this new commit, build is failing for CDH5 alone and looking into the logs it doesn't seem those errors were introduced by this new commit, I could be wrong.

chris-hirstein commented 8 years ago

@rdblue Have you had a chance to review the update that @megnataraj provided?

rdblue commented 8 years ago

@megnataraj and @chris-hirstein, I've looked at the update and it looks mostly good. My comments on TestAvroWriter#newWriter still applies though. That writer should use the schema that was passed in.

chris-hirstein commented 8 years ago

@rdblue It looks like @megnataraj added an update, can you take another look? Thanks!

mkwhitacre commented 8 years ago

Re-kicked off Travis build b/c failures seemed unrelated to the PR.

+1 for this PR pending successful build for non-flaky reasons.

rdblue commented 8 years ago

I'm not sure that the tests are exercising the correct code path, so I'd appreciate it if you didn't merge this until I have time to take a closer look. Sorry to be a blocker here.

chris-hirstein commented 8 years ago

@rdblue Will you have time to review this change soon?

rdblue commented 8 years ago

@chris-hirstein, @megnataraj, thanks for the reminder. I've posted a comment about making sure the tests cover what we need to. I hope that is clear enough but if it isn't please ask questions about it and I'll make sure they get answered.

anandsagark commented 8 years ago

I've updated this pull request as per the changes suggested by @rdblue Please take a look and see if everything looks ok to merge, the failure in the integration checks is not related to this PR

rdblue commented 8 years ago

@anandsagark, I'll look today.

rbrush commented 8 years ago

+1 overall. I'm willing to merge unless there are objections from @rdblue or @mkwhitacre.

(I might quibble that the TestValue class could do with a more descriptive name, like "ValueWithoutOptionalField", but I don't think that's enough to block it.)

rdblue commented 8 years ago

I don't think that the new test actually tests what it should. It looks like the schemas for the two values are the same. I think the dataset should have a 2-field record and the code should write a 1-field record.

But, I've been holding this up for too long and I'm fairly confident that it works, so I'm not going to shoot it down. Thanks for being patient, everyone.

rbrush commented 8 years ago

@rdblue Ugh, you're right. Got my wires crossed on which schema the view pointed to.

@anandsagark, if I'm reading this right I think this just means making testReaderWriterCompatibleSchema use a dataset that uses the "testDescriptor" rather than the "valueDescriptor" so we write to a different schema than the writer has.

anandsagark commented 8 years ago

@rdblue @rbrush I've updated PR to use different schemas for read, write. Let me know if this is in tune with what you guys are looking for.

edit : updated PR again, dataset created with 2-field record and writer used 1-field record.

rdblue commented 8 years ago

+1

Test looks good to me. Thanks @anandsagark

rbrush commented 8 years ago

I kicked off the build again (looks like there was a spurious failure on the default profile). I'll merge pending a clean build on default and CDH5 (I know the CDH4 profile is failing for unrelated reasons.)

rbrush commented 8 years ago

The build is clean modulo the known CDH4 issue and we have +1's. Merging.

Thanks everyone!