The minOccurs and maxOccurs attributes should appear on the elements, rather than the containers.
for a thrift struct, we produce:
<sequence>
<element name="some_element"> <!-- max is implicitly 1 -->
<element name="some_optional_element" minOccurs="0"> <!-- max is
implicitly 1 -->
...
for a thrift list, we produce
<sequence>
<element name="the_list_element" minOccurs="0" maxOccurs="unbounded">
</sequence>
for a thrift struct tagged with xsd_all, we produce
<all>
<element name="some_element" minOccurs="0"/> <!-- max is implicitly 1
-->
</all>
Reviewed By: mcslee
Test Plan: sandbox
Revert Plan: revertible
Notes:
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664962 13f79535-47bb-0310-9956-ffa450edef68
Summary: libthriftnb is the one that requires libevent. It was really annoying that you always had to put -levent in your link step to build thrift programs when youa re not using any of the c++ nonblocking stuff. This way, if you're using nonblocking you can do that, but the normal case is easier to link.
Reviewed By: makefile
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664951 13f79535-47bb-0310-9956-ffa450edef68
Summary:
- perform some basic corruption checks:
1) Event larger than chunk
2) Event larger than specified max
3) Event crossing chunk boundary etc.
- If error encountered, then try to perform some recovery
Reviewed By: Slee
Test Plan: Going to test now...need to check in because of compile issues
Notes:
- These checks take care of the case when there is a dirty read from the filesystem (which
we have encountered with the netapps). The recovery involves trying to perform the read
again from ths FS and if that fails skipping the chunk altogether.
Keep in mind that this might only be useful for idempotent systems (e.g. search redolog).
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664943 13f79535-47bb-0310-9956-ffa450edef68
Summary:
- Transport factories now wrap around one transport
- Protocol factories now wrap around one transport (as opposed to a pair of input/output
transports)
- TServer now takes input/output transport and protocol factories
The motivation for this change is that you could concievably want to use a different protocol or
transport for input and output. An example is that incoming data is encoded using binary protocol
but outgoing data is encrypted XML (with encryption being done on the transport level).
This change should be mostly backwards compatible because the TServer classes have constructors
that take a transport factory and use that for both the input and transport factories. The only
change might be for anyone who is using the C++ client code directly i.e. instantiating
TBinaryProtocol() directly because the constructor now only accepts one transport.
Reviewed By: Slee
Test Plan: Everything compiles (for both thrift and search).
Notes:
I am going to make the same changes in all the supported languages after this...
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664940 13f79535-47bb-0310-9956-ffa450edef68
Summary:
-- the constructor needs to accept a transport factory
-- TConnection close() needs to close factor generated transports
Reviewed By: Mark Slee
Test Plan: Tested with search redologger
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664930 13f79535-47bb-0310-9956-ffa450edef68
Summary: This keeps confusing people when they try to do make and make install, we always have it around in the svn repo, so we can take it out of current trunk.
Reviewed By: martin
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664926 13f79535-47bb-0310-9956-ffa450edef68
Trac Bug: #
Reviewed By:
Test Plan:
The correct error message appears when a PHP Thrift client can't
connect to a server. Set that up, and try and get the error message:
[Wed Jan 17 10:41:41 2007] [error] TSocketPool: retryInterval (60) has
passed for host dev007:8188
...then you're good. If you get something about a undefined property,
then this fix didn't work.
Revert Plan: Revertible
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664920 13f79535-47bb-0310-9956-ffa450edef68