856 Commits

Author SHA1 Message Date
Greg Wilkins
18f7293efd 392237 Fixed 3.0 port of chat servlet 2012-10-25 12:27:30 +11:00
Simone Bordet
c21a17ea83 #392463 - Client SSL handshake may hang.
Now we check whether a fill() called from flush() has changed the SSLEngine state to NEED_WRAP,
and if so, we continue to wrap.
2012-10-19 17:53:54 +02:00
Greg Wilkins
2b13648b0e 392237 fixed many TODOs and many minor code cleanups 2012-10-19 16:17:30 +11:00
Greg Wilkins
f420f5016d 392237 Implemented HttpOutput.sendContent for large content 2012-10-19 10:16:30 +11:00
Greg Wilkins
b618ce59e3 392304 fixed intermittent client SSL failure. Correctly compact in flip2fill 2012-10-18 19:55:57 +11:00
Greg Wilkins
27e8efec94 jetty-9 optimised the selector change submission 2012-10-18 15:34:10 +11:00
Simone Bordet
444d5845ec jetty-9: improved logging. 2012-10-16 13:50:24 +02:00
Simone Bordet
84a1cff26e jetty-9: changed the way changes are run.
Before: changes were submitted, but if this happened in the selector thread, then they were executed immediately.
This lead to recursion: the run of a change submitted another change, which was run, which submitted a change, etc.
To avoid StackOverFlowException, a ForkInvoker was used, breaking the stack after 4 recursive calls.
The reason for this was to avoid to queue a change that could have been run in place, but costs probably it costs
more than what it saves.

Current: changes are now always queued. This avoids recursion and the need for a ForkInvoker, making the code simpler.
Instead of recursing we now iterate over the queue of changes.
2012-10-16 13:50:24 +02:00
Simone Bordet
39fb81c486 jetty-9: Fixed concurrent updates to volatile variable _interestOps.
Read interest and write interest can be setting concurrently, and they may cancel each other.
Replaced _interestOps with an AtomicInteger and checking whether the update succeeds,
otherwise it is reattempted.
2012-10-12 15:58:52 +02:00
Simone Bordet
e41ad27ca4 jetty-9: always clearing the buffer before returning it from acquire(). 2012-10-10 21:35:32 +02:00
Simone Bordet
7cad4ebe52 jetty-9: DecryptedEndPoint now delegates the set of the idle timeout to the underlying EndPoint.
DecryptedEndPoint does not perform any scheduling for idle timeouts, because those are done
by SelectChannelEndPoint that is the usual underlying EndPoint of DecryptedEndPoint.
In case of more nested EndPoint/Connection chains, EndPoints that delegate (such as
DecryptedEndPoint) should delegate the idle timeout to the underlying EndPoint.
2012-10-08 11:05:27 +02:00
Simone Bordet
2748a9381e jetty-9: Added support for connect timeout. 2012-10-08 11:05:26 +02:00
Greg Wilkins
f4d12412eb jetty-9 added FilterConnectionFactory and made SpdyServer use it 2012-10-08 15:22:49 +11:00
Greg Wilkins
c5d8fd748b jetty-9 added FilterConnection 2012-10-07 09:09:23 +11:00
Greg Wilkins
97d08c399a jetty-9 removed race with NPN replacing connection and extra wrap causing NPE in SSLEngineImpl 2012-10-02 15:00:31 -07:00
Greg Wilkins
6cc0734a1a jetty-9 miscillaneous optimizations: donot dispatch to HTTP and SPDY; improved executorCallback 2012-10-02 13:48:51 -07:00
Greg Wilkins
cb4e7982b1 jetty-9 SslConnection fill does not try to send close handshake 2012-09-24 13:10:18 +10:00
Simone Bordet
9e7fcf4fee jetty-9: Fixed SslBytesServerTest, and added factory methods to relevant classes. 2012-09-21 16:47:01 +02:00
Greg Wilkins
e04494da64 jetty-9 fixed test onOpen 2012-09-21 18:00:46 +10:00
Greg Wilkins
68ee346b8a jetty-9 combined the Container and AggregateLifeCycle into ContainerLifeCycle 2012-09-21 11:45:51 +10:00
Greg Wilkins
b9ceb8703d Merge branch 'jetty-9' into jetty-9-open-close 2012-09-21 08:36:22 +10:00
Joakim Erdfelt
857498b115 Upgrading to junit-dep-4.10.jar (banning junit.jar) 2012-09-20 11:52:59 -07:00
Simone Bordet
37a7e5977d Merged branch 'jetty-9' into jetty-9-open-close. 2012-09-20 18:46:16 +02:00
Simone Bordet
40382bad3a jetty-9 - Removed references to JUnit 3.x. 2012-09-20 18:23:02 +02:00
Greg Wilkins
0d2627b6e9 jetty-9 improved onOpen onclose handling 2012-09-20 11:05:20 +10:00
Simone Bordet
851de69d9d jetty-9 - Third take at open/close refactoring. 2012-09-19 18:04:15 +02:00
Simone Bordet
44b3bb067c jetty-9 - Second take at open/close refactoring. 2012-09-19 13:37:47 +02:00
Simone Bordet
f257f4b2bb jetty-9 - First take at open/close refactoring. 2012-09-19 13:37:47 +02:00
Simone Bordet
0915b2b0ab jetty-9 - Refactored code that was counting the number of reentrant invocations into a common utility class, ForkInvoker. 2012-09-17 14:39:13 +02:00
Simone Bordet
4ea5734ab1 jetty-9 - Avoiding StackOverflowErrors when processing changes. 2012-09-17 11:46:26 +02:00
Simone Bordet
4f1a2990de jetty-9 - Always making SslConnection dispatch completion callbacks to avoid StackOverflowErrors. 2012-09-17 11:46:26 +02:00
Greg Wilkins
129583679a jetty-9 javadoc improvements and renamed SelectChannelConnector to ServerConnector 2012-09-17 17:37:56 +10:00
Simone Bordet
4ffe66f899 jetty-9 - HTTP client: better cleanup at stop. 2012-09-14 23:30:21 +02:00
Simone Bordet
88cbfed7e0 jetty-9 - Made SelectorManager.connection[Opened|Closed]() concrete, since they are overridden only by SelectChannelConnector. 2012-09-14 23:30:21 +02:00
Simone Bordet
cf3f12297f jetty-9 - Cosmetics. 2012-09-14 23:30:21 +02:00
Simone Bordet
8c9f097666 jetty-9 - Throwing EofException when trying to flush after output shutdown.
When the output is shutdown, field _cannotAcceptMoreAppDataToFlush is set to true,
indicating that no more flush() calls are accepted.
However, a further call to flush() was reading _cannotAcceptMoreAppDataToFlush and
just returning false, leaving writes in pending state but without chance to be completed.
Now, if we detect _cannotAcceptMoreAppDataToFlush==true in flush(), we check
whether the output was shutdown; if it is the case, we throw an EofException to signal
to the application that it cannot write because the connection is already closed.
2012-09-14 15:20:10 +02:00
Simone Bordet
655a313fdf jetty-9 - Improved logging. 2012-09-14 15:09:22 +02:00
Greg Wilkins
22ba57b8d2 jetty-9 refactored onOpen and onClose 2012-09-14 17:38:47 +10:00
Simone Bordet
b264f20dc9 jetty-9 - Removed the write of an empty buffer from onOpen().
SslConnection should remain as passive as possible, with the next connection driving the activity.
If client connections need to drive the SSL handshake with an empty write, they should do it, and
not SslConnection.
2012-09-14 00:38:25 +02:00
Simone Bordet
24cbb6385b jetty-9 - Just returning in case we want to fail an already failed write flusher. 2012-09-14 00:38:25 +02:00
Joakim Erdfelt
12470a2715 Introduce SocketBased, and squelching logging on tests 2012-09-13 08:51:45 -07:00
Greg Wilkins
c709981aa5 jetty-9 finished refactor for oneconnector and configuration pluggability 2012-09-13 10:00:44 +10:00
Greg Wilkins
a41b6e32ac Merge branch 'jetty-9-configuration' into jetty-9
Conflicts:
	jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java
2012-09-13 08:22:06 +10:00
Greg Wilkins
b3e8f91026 jetty-9 flush returns boolean to say completely flushed or not 2012-09-13 08:11:05 +10:00
Greg Wilkins
79caf45604 Merge branch 'jetty-9' into jetty-9-configuration
Conflicts:
	jetty-io/src/main/java/org/eclipse/jetty/io/ssl/SslConnection.java
2012-09-12 23:11:12 +10:00
Greg Wilkins
427a01855c jetty-9 WriteFlusher handlers buffering endpoints 2012-09-12 23:06:19 +10:00
Joakim Erdfelt
550f0d28f6 attempting to address the SCEPSslTest.testWriteBlocked() failures 2012-09-10 15:15:31 -07:00
Greg Wilkins
26f5ffc459 jetty-9 improve SslConnection toString 2012-09-11 08:04:33 +10:00
Greg Wilkins
73ebe89019 jetty-9 refactored configuration 2012-09-10 20:26:14 +10:00
Greg Wilkins
a15d71932f jetty-9 protection from double onFillable calls 2012-09-09 08:31:31 +10:00