Re: Redirect to buffer strategy may not work properly on Tomcat 7.0.29

2012-07-27 Thread Martin Grigorov
Hi Pedro,

I've CC-ed Tomcat's team, so they can explain better what Tomcat does.

On Fri, Jul 27, 2012 at 3:24 AM, Pedro Henrique Oliveira dos Santos
 wrote:
> Hi Martin,
>
> I don't see how to wrap the request or the response can be useful here. Even 
> if we decorate the container request to return its URI based on the page 
> being rendered address it will not be enough because Servlet API does not 
> allow us to change the composition of a response. i.e. we are not able to set 
> on which request URI the encode method of the response will work on (Tomcat 
> API allows such thing but I'd rather not use to it).

I don't quite understand what you mean with the above.
As far as I understood Mark he suggests to use
HttpServletRequestWrapper which should return the proper base url when
asked (#getRequestURI, #getPath, etc.)

Thinking more about it now I don't see how this will help actually
because this wrapper will be reachable only by Wicket code. To encode
an URL Wicket calls HttpServletResponse#encodeURL(), note this is the
*response*, and it has no reference from the response to the wrapped
request, so Tomcat will be able to find and use only the original
request.
Wrapping the response and link it to it the wrapped request wont help
because Tomcat wont be able to cast to our custom wrappers.

>
> I simply don't get why Tomcat added such validation in the encode method. To 
> redirect the request to a buffered response is a very common strategy that 
> has being saving tons of applications from double form submissions for 
> instance rather than a weird web framework implementation like I read in the 
> ticket.

Do you know of another bigger web framework that uses this approach ?
If you know please mention it in the ticket. This will be a stronger
argument for Tomcat to not ignore this solution.

It all started with a ticket by me in Tomcat's Bugzilla to normalize
the absolute urls which are send in "Location" response header. This
is the redirect url. Before the ticket Tomcat was sending urls like
'http://www.example.com/a/b/../c/d.html' and '..' in this url caused
some problems in some cases, e.g. JMeter complained about it, and
Chris Colman reported an issue with IE when using Tomcat virtual
hosts.
So now Tomcat normalizes the url to
'http://www.example.com/a/c/d.html' before sending it to the client.
All good so far.

The new problem is that Tomcat uses the normalization even in
#encodeURL(), this method just encodes jsessionid if needed, even for
relative urls. To decide whether the relative url is part of the
current application Tomcat makes the url absolute and normalizes it.
When Wicket starts rendering the rendering for PageB (from my first
mail) it produces relative urls to PageB, but later Tomcat normalizes
them against PageA and url like
'http://www.example.com/a/b/../../../../c/d.html' fails because there
are too many '..'s.

I hope the problem is more clear now.

>
> It looks like the response will not encode the session id to links and 
> callbacks in the buffered pages in a deeper path from Tomcat 7.0.29 on. I'm 
> OK with the way the Tomcat team worked around this issue. Who knows if they 
> aren't only doing some good by preventing some session fixation attacks.

They didn't workaround it yet. For now we discuss possible solutions
for the next version.

>
> Pedro Santos
>
> Em 25/07/2012, às 16:42, Martin Grigorov escreveu:
>
>> Hi,
>>
>> Please take a look at 
>> https://issues.apache.org/bugzilla/show_bug.cgi?id=53469.
>> This issue describes a problem which prevents Wicket's default
>> RenderStrategy - REDIRECT_TO_BUFFER.
>>
>> Basically the problem is:
>> - PageA mounted at /mount/pageA is requested
>> - the code uses setResponsePage(PageB.class) which is mounted at
>> /deeper/mount/path/pageB
>> - Wicket starts to render PageB (in the same request cycle) and for
>> each url in the page it asks the web container to encode it
>> (HttpServletResponse#encodeURL())
>> - here Tomcat 7.0.29+ tries to find whether the url to encode is part
>> of the web app. To do this it makes the relative url passed by Wicket
>> to absolute by using the HttpServletRequest's requestURI (i.e.
>> /mount/pageA). This may get wrong because Wicket actually generates
>> the urls against /deeper/mount/path/pageB
>>
>> Mark Thomas (Tomcat dev) suggests that Wicket could use
>> HttpServletRequestWrapper which should return the correct requestURI
>> depending on the current request cycle baseUrl.
>>
>> Any ideas and comments are welcome!
>>
>> --
>> Martin Grigorov
>> jWeekend
>> Training, Consulting, Development
>> http://jWeekend.com
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



Re: Moderators wanted

2015-10-15 Thread Martin Grigorov
Hi Mark,

On Thu, Oct 15, 2015 at 12:24 PM, Mark Thomas  wrote:

> On 01/12/2014 16:24, Martin Grigorov wrote:
> > Hi,
> >
> > On Mon, Dec 1, 2014 at 4:56 PM, Mark Thomas  wrote:
> >
> >> Hi,
> >>
> >> I've been reviewing the moderators for our various lists and if I ignore
> >> the no longer active ones we are below the 3 moderators the ASF likes to
> >> have on a number of lists.
> >>
> >> Therefore, can I have some volunteers for the following lists:
> >>
> >> users@tomcat.a.o- Need two moderators
> >> dev@tomct.a.o   - Need one moderator
> >> announce@tomcat.a.o - Need one moderator
> >> private@tomcat.a.o  - Need one moderator
> >> security@tomcat.a.o - Need one moderator
> >>
> >> You can volunteer for more than one :)
> >>
> >> There is typically less than one message a week that requires moderator
> >> input (security@ is a little higher) which is usually explaining to
> >> folks how to unsubscribe themselves or doing it for them if they are
> >> unable to.
> >>
> >> Note all of our public lists automatically reject mails from
> >> unsubscribed users so there is no moderator traffic from that source.
> >>
> >>
> >
> >> Generally, you need to be a committer to moderate a list.
> >> To moderate the private and security list you need to be a PMC member.
> >>
> >
> > As an ASF Member I already have access to those lists. I'd volunteer for
> > private@ and security@ if this is OK with you.
>
> Martin,
>
> Sorry I dropped the ball on this. Is this still something you are
> willing to take on?
>

Sure!


>
> Mark
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 7.0.65

2015-10-15 Thread Martin Grigorov
[ X ] Stable - go ahead and release as 7.0.65 Stable

Tested our main application. No issues found!

On Fri, Oct 9, 2015 at 1:04 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.65 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.65/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1053/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_65/
>
> The proposed 7.0.65 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 7.0.65 Stable
>
> Regards,
> Violeta
>


Re: svn commit: r1708968 - in /tomcat/site/trunk: docs/migration-9.html docs/migration.html xdocs/migration-9.xml xdocs/migration.xml

2015-10-18 Thread Martin Grigorov
Hi,

On Fri, Oct 16, 2015 at 2:03 PM,  wrote:

> In JSP pages that use wildcard import syntax the new classes added in
> +Servlet API may conflict with ones in web applications.
> +For example, if package "a" contains class
> +PushBuilder, the following JSP page will cease to
> compile in
> +Tomcat 8:
>

I think this should say "Tomcat 9".


> +
> +
>



Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: svn commit: r1708968 - in /tomcat/site/trunk: docs/migration-9.html docs/migration.html xdocs/migration-9.xml xdocs/migration.xml

2015-10-18 Thread Martin Grigorov
On Fri, Oct 16, 2015 at 2:03 PM,  wrote:

> 


s/virtua/virtuaL/

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: [ANN] New committer: Ognjen Blagojevic

2015-10-25 Thread Martin Grigorov
Congratulations, Ognjen!


Re: svn commit: r1710734 - in /tomcat/site/trunk: docs/whoweare.html xdocs/whoweare.xml

2015-10-27 Thread Martin Grigorov
On Tue, Oct 27, 2015 at 2:59 PM, Konstantin Kolinko 
wrote:

> This page is sorted by family name. So I expect yours to be between
> Gomez and  Hanik.
>

Fixed!
Thanks!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: [ANN] New committer: Martin Grigorov

2015-10-27 Thread Martin Grigorov
On Tue, Oct 27, 2015 at 3:00 PM, Konstantin Kolinko 
wrote:

> 2015-10-26 17:35 GMT+03:00 Mark Thomas :
> > On behalf of the Tomcat committers I am pleased to announce that
> > Martin Grigorov (mgrigorov) has been voted in as a new Tomcat committer.
> >
>
> Welcome!
>
>
> Best regards,
> Konstantin Kolinko
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>
Thank you everyone for the warm welcome!


Re: [VOTE] Switch 6.0.x from RTC to CTR

2015-10-28 Thread Martin Grigorov
On Thu, Oct 29, 2015 at 12:42 AM, Mark Thomas  wrote:

> [ ] Continue to use RTC for 6.0.x
> [ X ] Switch 6.0.x to CTR
>


Re: svn commit: r1713158 - /tomcat/tc6.0.x/trunk/test/org/apache/catalina/tribes/group/TestGroupChannelSenderConnections.java

2015-11-07 Thread Martin Grigorov
On Sat, Nov 7, 2015 at 7:35 PM, Rémy Maucherat  wrote:

> 2015-11-07 18:17 GMT+01:00 :
>
> > Author: kkolinko
> > Date: Sat Nov  7 17:17:55 2015
> > New Revision: 1713158
> >
> > URL: http://svn.apache.org/viewvc?rev=1713158&view=rev
> > Log:
> > Copy test implementation from Tomcat 7.
> > This a) uses logging instead of System.out,
> > b) validates result of the test and fail()s, instead of just printing a
> > message onto System.out
> >
> > When I voted for CTR on 6, it was agreed upon that only critical fixes
> would go in 6. Obviously, there's no regression risk with the testsuite,
> but what is the rationale with such an upgrade ?
>

I've also asked the same myself.
My answer is: to be better prepared for the eventual fixes later :-)


>
> Rémy
>


Re: svn commit: r1713285 - in /tomcat/trunk: java/org/apache/catalina/ java/org/apache/catalina/session/ java/org/apache/catalina/util/ test/org/apache/catalina/util/

2015-11-08 Thread Martin Grigorov
On Sun, Nov 8, 2015 at 9:05 PM,  wrote:

> public void testValidateWithJvmRouteWithPerid() {
>

I'd fix it myself with my new superpowers but I'm not sure whether there is
a typo in Period above or it is just my non-native English.


Re: Time for 9.0.0.RC1

2015-11-12 Thread Martin Grigorov
Hi,

On Thu, Nov 12, 2015 at 11:22 AM, Rémy Maucherat  wrote:

> 2015-11-12 9:26 GMT+01:00 Mark Thomas :
>
> > The announcements, download page, which version etc. will all make it
> > clear that this a work in progress.
> >
> > To make it clearer, I'll label the version M1 (milestone 1) rather than
> > RC1.
> >
> > This naming is new in Tomcat. It could be just M, with 9.0.0.M, then
> 9.0.1.M, etc. Or 9.0.0.Alpha. Or 9.0.0.M1 as you said, then 9.0.0.M2 until
> it gets to 9.0.0.Alpha/Beta/etc once the relevant specifications are out.
> Either way, it's 1+ years of alphas ahead.
>

I think the best for Tomcat would be: M1, M2, ..., 9.0.0, 9.0.1, ...
No need of alpha/beta/rc.
The current approach with releasing X.0.0 as non-stable works quite well!
More people start to test/use it earlier and report problems.


>
> Rémy
>


Issues when building Tomcat 9 + tcnative

2015-11-15 Thread Martin Grigorov
Hi devs,

I'm trying to build 9.0.0.M1 from sources to test the HTTP2 functionalities.
I haven't built Tomcat + tcnative before so I may be doing something
wrong...

I run Ubuntu 15.10 here.

Running just 'ant' downloads tomcat-native.tar.gz (1.2.2) to base.path.
But this file is just copied in ./output/build/bin/, it is not untar-ed.

So I've checked in build.xml and saw that at line 1927 it copies the .dll
files, as part of "dist-static" target. Executing "ant dist-target" leads
to:

1) trydownload:
  [get] Getting:
http://www.apache.org/dist/tomcat/tomcat-connectors/native/1.2.2/binaries/tomcat-native-1.2.2-win32-bin.zip

and

testexist:
 [echo] Testing  for /tmp/tc9/commons-daemon-1.0.15/windows/prunmgr.exe

and

trydownload:
  [get] Getting:
http://www.apache.org/dist/commons/daemon/binaries/windows/commons-daemon-1.0.15-bin-windows-signed.zip
  [get] To: /tmp/tc9/download-530232362.zip

and the same for makensis.exe

Why win32 ?!
Later I see the Unix versions being downloaded too, so maybe it just
download everything and then decides which ones to actually use. Not a big
issue.


2) at step "extras-commons-logging" it fails with:

extras-commons-logging:
   [gunzip] Expanding
/tmp/tc9/commons-logging-1.1.3/commons-logging-1.1.3-src.tar.gz to
/tmp/tc9/apache-tomcat-9.0.0.M1-src/output/extras/logging/commons-logging-src.tar
[untar] Expanding:
/tmp/tc9/apache-tomcat-9.0.0.M1-src/output/extras/logging/commons-logging-src.tar
into /tmp/tc9/apache-tomcat-9.0.0.M1-src/output/extras/logging

BUILD FAILED
/tmp/tc9/apache-tomcat-9.0.0.M1-src/build.xml:1651: Error while expanding
/tmp/tc9/apache-tomcat-9.0.0.M1-src/output/extras/logging/commons-logging-src.tar
java.io.IOException: Error detected parsing the header
at org.apache.tools.tar.TarInputStream.getNextEntry(TarInputStream.java:292)
at org.apache.tools.ant.taskdefs.Untar.expandStream(Untar.java:165)
at org.apache.tools.ant.taskdefs.Untar.expandFile(Untar.java:114)
at org.apache.tools.ant.taskdefs.Expand.execute(Expand.java:132)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:435)
at org.apache.tools.ant.Target.performTasks(Target.java:456)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
at
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
at org.apache.tools.ant.Main.runBuild(Main.java:851)
at org.apache.tools.ant.Main.startAnt(Main.java:235)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
Caused by: java.lang.IllegalArgumentException: Invalid byte 32 at offset 7
in '   {NUL}' len=8
at org.apache.tools.tar.TarUtils.parseOctal(TarUtils.java:134)
at org.apache.tools.tar.TarUtils.parseOctalOrBinary(TarUtils.java:172)
at org.apache.tools.tar.TarEntry.parseTarHeader(TarEntry.java:912)
at org.apache.tools.tar.TarEntry.parseTarHeader(TarEntry.java:899)
at org.apache.tools.tar.TarEntry.(TarEntry.java:323)
at org.apache.tools.tar.TarInputStream.getNextEntry(TarInputStream.java:290)
... 19 more


$ tar xvf commons-logging-src.tar
works just fine, but it seems the Java library used for untar-ing doesn't
like the content

I'll try with apache-tomcat-9.0.0.M1.tar.gz  +
http://tomcat.apache.org/native-doc/ (configure+make)


Cheers
Martin


Re: Issues when building Tomcat 9 + tcnative

2015-11-15 Thread Martin Grigorov
On Sun, Nov 15, 2015 at 12:54 PM, Martin Grigorov 
wrote:

>
> So I've checked in build.xml and saw that at line 1927 it copies the .dll
> files, as part of "dist-static" target. Executing "ant dist-target" leads
> to:
>

Uh. Of course ".dll" means that it will deal with Windows stuff...


I have the natives properly set up! Now I'll test the HTTP2 connector.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: Issues when building Tomcat 9 + tcnative

2015-11-15 Thread Martin Grigorov
On Sun, Nov 15, 2015 at 1:35 PM, Mark Thomas  wrote:

> On 15/11/2015 11:54, Martin Grigorov wrote:
>
> 
>
> > Running just 'ant' downloads tomcat-native.tar.gz (1.2.2) to base.path.
> > But this file is just copied in ./output/build/bin/, it is not untar-ed.
>
> Correct. The source ships in that directory for the Tomcat .tar.gz
> distro. Users of that distro are expected to build tc-native themselves.
>
> > So I've checked in build.xml and saw that at line 1927 it copies the .dll
> > files, as part of "dist-static" target. Executing "ant dist-target" leads
> > to:
> 
> > Why win32 ?!
> > Later I see the Unix versions being downloaded too, so maybe it just
> > download everything and then decides which ones to actually use. Not a
> big
> > issue.
>
> Because the Tomcat binary distros for Windows ship with the pre-built
> tc-native binaries.
>
> > 2) at step "extras-commons-logging" it fails with:
>
> Looks like you are using a version of Ant with known issues.
>
> Mark
>

I was using Ant 1.9.4. Upgraded it to 1.9.6 and the problem is gone!

Thanks!


>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Issues when building Tomcat 9 + tcnative

2015-11-15 Thread Martin Grigorov
On Sun, Nov 15, 2015 at 1:35 PM, Martin Grigorov 
wrote:

>
> On Sun, Nov 15, 2015 at 12:54 PM, Martin Grigorov 
> wrote:
>
>>
>> So I've checked in build.xml and saw that at line 1927 it copies the .dll
>> files, as part of "dist-static" target. Executing "ant dist-target" leads
>> to:
>>
>
> Uh. Of course ".dll" means that it will deal with Windows stuff...
>
>
> I have the natives properly set up! Now I'll test the HTTP2 connector.
>
>
To setup HTTP2 I follow the steps done by Konstantin Kolinko at
https://bz.apache.org/bugzilla/show_bug.cgi?id=58605
But here it fails with:

15-Nov-2015 13:40:37.505 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR
based Apache Tomcat Native library 1.2.2 using APR version 1.5.2.
15-Nov-2015 13:40:37.506 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR
capabilities: IPv6 [true], sendfile [true], accept filters [false], random
[true].
15-Nov-2015 13:40:37.508 INFO [main]
org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL
successfully initialized (OpenSSL 1.0.2d 9 Jul 2015)
15-Nov-2015 13:40:37.612 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["http-apr-8080"]
15-Nov-2015 13:40:37.619 INFO [main]
org.apache.coyote.http11.AbstractHttp11Protocol.configureUpgradeProtocol
The ["https-apr-8443"] connector has been configured to support negotiation
to [h2] via ALPN
15-Nov-2015 13:40:37.620 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["https-apr-8443"]
15-Nov-2015 13:40:37.622 SEVERE [main]
org.apache.coyote.AbstractProtocol.init Failed to initialize end point
associated with ProtocolHandler ["https-apr-8443"]
 java.lang.Exception: Unable to load certificate key
/tmp/tc9/apache-tomcat-9.0.0.M1/conf/localhost-key.pem (error:0906D06C:PEM
routines:PEM_read_bio:no start line)
at org.apache.tomcat.jni.SSLContext.setCertificate(Native Method)
at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:487)
at
org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:790)
at
org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:544)
at
org.apache.coyote.http11.AbstractHttp11Protocol.init(AbstractHttp11Protocol.java:67)
at
org.apache.catalina.connector.Connector.initInternal(Connector.java:978)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at
org.apache.catalina.core.StandardService.initInternal(StandardService.java:569)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at
org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:851)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at org.apache.catalina.startup.Catalina.load(Catalina.java:600)
at org.apache.catalina.startup.Catalina.load(Catalina.java:623)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:310)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:484)

The connector config is:







Ideas what could be wrong ?

Martin


Re: Issues when building Tomcat 9 + tcnative

2015-11-15 Thread Martin Grigorov
On Sun, Nov 15, 2015 at 3:10 PM, Rainer Jung 
wrote:

> Am 15.11.2015 um 13:59 schrieb Martin Grigorov:
>
>> On Sun, Nov 15, 2015 at 1:35 PM, Martin Grigorov 
>> wrote:
>>
>
> To setup HTTP2 I follow the steps done by Konstantin Kolinko at
>> https://bz.apache.org/bugzilla/show_bug.cgi?id=58605
>> But here it fails with:
>>
>> 15-Nov-2015 13:40:37.505 INFO [main]
>> org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR
>> based Apache Tomcat Native library 1.2.2 using APR version 1.5.2.
>> 15-Nov-2015 13:40:37.506 INFO [main]
>> org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR
>> capabilities: IPv6 [true], sendfile [true], accept filters [false], random
>> [true].
>> 15-Nov-2015 13:40:37.508 INFO [main]
>> org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL
>> successfully initialized (OpenSSL 1.0.2d 9 Jul 2015)
>> 15-Nov-2015 13:40:37.612 INFO [main]
>> org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
>> ["http-apr-8080"]
>> 15-Nov-2015 13:40:37.619 INFO [main]
>> org.apache.coyote.http11.AbstractHttp11Protocol.configureUpgradeProtocol
>> The ["https-apr-8443"] connector has been configured to support
>> negotiation
>> to [h2] via ALPN
>> 15-Nov-2015 13:40:37.620 INFO [main]
>> org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
>> ["https-apr-8443"]
>> 15-Nov-2015 13:40:37.622 SEVERE [main]
>> org.apache.coyote.AbstractProtocol.init Failed to initialize end point
>> associated with ProtocolHandler ["https-apr-8443"]
>>   java.lang.Exception: Unable to load certificate key
>> /tmp/tc9/apache-tomcat-9.0.0.M1/conf/localhost-key.pem (error:0906D06C:PEM
>> routines:PEM_read_bio:no start line)
>>  at org.apache.tomcat.jni.SSLContext.setCertificate(Native Method)
>>
> ...
>
> The connector config is:
>> > protocol="org.apache.coyote.http11.Http11AprProtocol" maxThreads="150"
>> SSLEnabled="true" >
>>  > className="org.apache.coyote.http2.Http2Protocol"
>> />
>>  
>>  >   certificateFile="conf/localhost-cert.pem"
>>   type="RSA" />
>>  
>>  
>>
>> Ideas what could be wrong ?
>>
>
> Shooting from the hip:
>
> /tmp/tc9/apache-tomcat-9.0.0.M1/conf/localhost-key.pem (error:0906D06C:PEM
> routines:PEM_read_bio:no start line)
>
> sounds like the key file is not in valid PEM format, ie. it doesn't start
> with a
>
> -BEGIN RSA PRIVATE KEY-
>

Thanks, Rainer!
Somehow I messed up my Tomcat SVN working dir here and both
localhost-cert.pem and localhost-key.pem had the same content!
svn revert + copy again the -key.pem file to conf/ fixed the issue!


> line. Could you check, what the format of that file is?
>
> You can also use the openssl command from the same openssl installation
> that was used to build your tcnative and read the key file contents using
> it:
>
> /path/to/openssl rsa -inform pem -in
> /tmp/tc9/apache-tomcat-9.0.0.M1/conf/localhost-key.pem -text
>
> Finally, could it be, that your Tomcat runtime user can not read the file?
>
> Regards,
>
> Rainer



Overall everything looks good now!
Tomcat default apps run OK. Both Firefox and Google Chrome report H2.

It is just my own application that doesn't work in HTTP2 mode.
http://localhost:8080/wicket-websocket/ works fine
But https://localhost:8443/wicket-websocket/ redirects immediately with 302
to http://localhost/wicket-websocket/ (and Tomcat is not responsible for
port 80 here)
I've changed the name of the app (i.e. the .war) but it behaves the same
way. I'll try to debug it.



>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M1

2015-11-15 Thread Martin Grigorov
On Fri, Nov 13, 2015 at 1:12 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M1 release is now available for voting.
>
> This is the first milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 8.0.x branch are:
> - Requires Java 8
> - BIO, Comet and Windows Itanium support have been removed
> - Support for TLS virtual hosting, ALPN, HTTP/2 and OpenSSL with
>   NIO/NIO2 has been added
> - Lots of internal refactoring to support the above changes
>
> For full details, see the changelog:
> http://svn.us.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M1/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1054/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcattags/TOMCAT_9_0_0_M1/
>
> The proposed 9.0.0.M1 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M1
>

Environment: Ubuntu 15.10, Firefox 42.0, Google Chrome 46

Tested:
- Apache Wicket WebSocket demo application (uses JSR 356 web sockets) with
HTTP2.
- Apache Wicket examples application

The only problem I faced was with Wicket-Atmosphere integration (Atmosphere
ver. 2.2.8):

1)
ERROR - AtmosphereFramework- AtmosphereFramework exception
java.lang.IllegalStateException: A filter or servlet of the current chain
does not support asynchronous operations.
at org.apache.catalina.connector.Request.startAsync(Request.java:1571)
at
org.apache.catalina.connector.RequestFacade.startAsync(RequestFacade.java:1037)
at
org.atmosphere.cpr.AtmosphereRequest.startAsync(AtmosphereRequest.java:723)
at
org.atmosphere.container.Servlet30CometSupport.suspend(Servlet30CometSupport.java:93)
at
org.atmosphere.container.Servlet30CometSupport.service(Servlet30CometSupport.java:68)
at
org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework.java:2078)
at org.atmosphere.cpr.AtmosphereServlet.doPost(AtmosphereServlet.java:198)

Is it a good idea (and possible) to print which filter or servlet is not
properly configured? For better debug info.

2)
java.lang.NullPointerException
at
org.apache.catalina.connector.Request.getServletContext(Request.java:1559)
at org.apache.catalina.connector.Request.getContextPath(Request.java:1894)
at
org.apache.catalina.connector.RequestFacade.getContextPath(RequestFacade.java:783)
at
org.atmosphere.cpr.AtmosphereRequest.getContextPath(AtmosphereRequest.java:359)
at
javax.servlet.http.HttpServletRequestWrapper.getContextPath(HttpServletRequestWrapper.java:150)
at org.apache.wicket.atmosphere.EventBus$2.getContextPath(EventBus.java:473)
at
org.apache.wicket.protocol.http.servlet.ServletWebRequest.getContextRelativeUrl(ServletWebRequest.java:184)
at
org.apache.wicket.protocol.http.servlet.ServletWebRequest.(ServletWebRequest.java:112)
at
org.apache.wicket.protocol.http.servlet.ServletWebRequest.(ServletWebRequest.java:82)

I believe this issue has been discussed before. Either here or in
Atmosphere forums.


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Apache Tomcat YouTube channel

2015-11-19 Thread Martin Grigorov
Hi Mark,

Please add me.

Martin

On Thu, Nov 19, 2015 at 2:44 PM, Mark Thomas  wrote:

> Hi,
>
> In readiness for the Webinar recordings, I have created the Apache
> Tomcat YouTube channel.
>
> If any committer wants to help manage that channel, just let me know and
> I'll add you (via you asf e-mail so this needs to be linked to your
> Google account).
>
> Mark
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.29

2015-11-23 Thread Martin Grigorov
On Fri, Nov 20, 2015 at 11:00 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.0.29 release is now available for voting.
>
> The main changes since 8.0.28 are:
>
> - Add an option to control (per context) quoting of EL expressions in
>   JSP attributes
>
> - Correct a regression in the fix for 56777 that added support for
>   URIs in config file locations
>
> - Add a new RestCsrfPreventionFilter that provides basic CSRF
>   protection for REST APIs
>
> -  Use instance manager for WebSocket server endpoint instances
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.29/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1055/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_29/
>
> The proposed 8.0.29 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.29
>

Tested our main application and Apache Wicket's examples app


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.30

2015-12-03 Thread Martin Grigorov
On Wed, Dec 2, 2015 at 1:02 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.0.30 release is now available for voting.
>
> The main changes since 8.0.29 are:
>
> - Location headers for redirects now use relative URIs. This can
>   be controlled by Context with the useRelativeRedirects attribute.
>
> - Correct a regression in 8.0.29 that broke redirects for context
>   roots.
>
> - Restore the default setting of quoteAttributeEL in Jasper to true
>   to align with 8.0.26/7.0.64 and earlier as well as other JSP
>   implementations.
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.30/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1057/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_30/
>
> The proposed 8.0.30 release is:
> [ ] Broken - do not release
>


> [ X ] Stable - go ahead and release as 8.0.30
>



>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Message files encoding

2018-08-01 Thread Martin Grigorov
Hi,

On Wed, Aug 1, 2018 at 2:08 PM Mark Thomas  wrote:

> On 01/08/18 12:03, Emmanuel Bourg wrote:
> > Hi all,
> >
> > The LocalString*.properties files are ASCII encoded which renders the
> > modification of the non-english messages rather inconvenient.
> > Contributors either need a specialized resource editor or go through a
> > native2ascii roundtrip.
> >
> > How do feel about converting the message files to UTF-8 to facilitate
> > the modifications and transform them with native2ascii at build time?
>
> I like the idea but that will make building with later versions of Java
> problematic - or at least more complex - since native2ascii has been
> removed in Java 9 onwards.
>

What about using the XML version of Java Properties ?
https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html#loadFromXML(java.io.InputStream)
This way the encoding could be specified in the XML file itself and there
is no need to use native2ascii at all.

Martin


>
> Mark
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Message files encoding

2018-08-01 Thread Martin Grigorov
On Wed, Aug 1, 2018 at 2:56 PM Emmanuel Bourg  wrote:

> Le 01/08/2018 à 13:16, Martin Grigorov a écrit :
>
> > What about using the XML version of Java Properties ?
> >
> https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html#loadFromXML(java.io.InputStream)
> > This way the encoding could be specified in the XML file itself and there
> > is no need to use native2ascii at all.
>
> I'm not really fond of XML properties files, the plain text format is
> more compact and easier to browse in my opinion. XML files are
> interesting when structured with different levels, but properties files
> even in XML format have a flat layout.
>

I hope the following changes your mind:

1) Bulgarian translations in XML format:
https://github.com/apache/wicket/blob/master/wicket-core/src/main/java/org/apache/wicket/Application_bg.properties.xml
2) Czech translation in ascii format:
https://github.com/apache/wicket/blob/master/wicket-core/src/main/java/org/apache/wicket/Application_cs.properties

I can easily read 1) (bulgarian, is my native lang).
I know some Czech but the \u0xyz makes it really hard / imposible to read
it as is.


>
> Emmanuel Bourg
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.5.0

2016-03-19 Thread Martin Grigorov
On Thu, Mar 17, 2016 at 9:00 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.0 release is now available for voting.
>
> This is the first release of the 8.5.x branch. The release is, in essence:
> - Based on a copy of the 9.0.0.M4 tag
> - All 9.0.x changes to the specification APIs have been reverted. The
>   specification APIs should match 8.0.x exactly
> - Java 8 specific code has been re-written for Java 7
> - Tomcat and specification versions have been set
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.0/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1066/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_0/
>
> The proposed 8.5.0 release is:
> [ ] Broken - do not release
> [ ] Alpha  - go ahead and release as 8.5.0
> [ ] Beta   - go ahead and release as 8.5.0
> [ ] Stable - go ahead and release as 8.5.0
>
>
[ X ] Beta   - go ahead and release as 8.5.0


> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.33

2016-03-23 Thread Martin Grigorov
On Fri, Mar 18, 2016 at 9:55 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.0.33 release is now available for voting.
>
> The main changes since 8.0.32 are:
>
> - Correct a false positive warning for ThreadLocal related memory
>   leaks when the key class but not the value class has been loaded
>   by the web application class loader.
>
> - Improve the performance of
>   javax.servlet.jsp.el.ScopedAttributeELResolver when resolving
>   attributes that do not exist.
>
> - Update the packaged version of the Tomcat Native Library to 1.2.5
>   to pick up the Windows binaries that are based on OpenSSL 1.0.2g
>   and APR 1.5.1.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.33/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1067/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_33/
>
> The proposed 8.0.33 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 8.0.33
>

[ X ] Stable - go ahead and release as 8.0.33


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Maven snapshot builds

2016-04-01 Thread Martin Grigorov
Hi,

Does anyone know what is the reason for the missing -SNAPSHOT builds at
https://repository.apache.org/content/repositories/snapshots/org/apache/tomcat/tomcat-catalina/
(RAO) ?

https://tomcat.apache.org/tomcat-8.5-doc/maven-jars.html says that the
snapshots should be at
http://people.apache.org/repo/m2-snapshot-repository/org/apache/tomcat/ but
this gives 404.

The last 8.0-SNAPSHOT at RAO is from Feb 23th.
I actually need 8.5-SNAPSHOT with the fix for ClassCastException when
trying to get the ApplicationPushBuilder.

Another option for me is to build and install the Maven jars locally. Any
hints for the Ant commands to do this ?

Thank you!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: Maven snapshot builds

2016-04-01 Thread Martin Grigorov
On Fri, Apr 1, 2016 at 10:07 PM, Martin Grigorov 
wrote:

> Hi,
>
> Does anyone know what is the reason for the missing -SNAPSHOT builds at
> https://repository.apache.org/content/repositories/snapshots/org/apache/tomcat/tomcat-catalina/
> (RAO) ?
>
> https://tomcat.apache.org/tomcat-8.5-doc/maven-jars.html says that the
> snapshots should be at
> http://people.apache.org/repo/m2-snapshot-repository/org/apache/tomcat/
> but this gives 404.
>
> The last 8.0-SNAPSHOT at RAO is from Feb 23th.
> I actually need 8.5-SNAPSHOT with the fix for ClassCastException when
> trying to get the ApplicationPushBuilder.
>
> Another option for me is to build and install the Maven jars locally. Any
> hints for the Ant commands to do this ?
>

I didn't find a way to install them just locally so I've uploaded
8.5-SNAPSHOT at
https://repository.apache.org/content/repositories/snapshots/org/apache/tomcat/tomcat-catalina/8.5-SNAPSHOT/
by following the steps at res/maven/README.txt.


>
> Thank you!
>
> Martin Grigorov
> Wicket Training and Consulting
> https://twitter.com/mtgrigorov
>


Re: [VOTE] Release Apache Tomcat 7.0.69

2016-04-12 Thread Martin Grigorov
On Mon, Apr 11, 2016 at 12:55 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.69 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.69/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1074/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_69/
>
> The proposed 7.0.69 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 7.0.69 Stable
>

[X] Stable - go ahead and release as 7.0.69 Stable

Tested Apache Wicket native web socket examples.


> Regards,
> Violeta
>


Re: Looking for mentor

2016-04-16 Thread Martin Grigorov
Hi,

On Sat, Apr 16, 2016 at 9:34 PM, Abdessamed MANSOURI 
wrote:

> Thank you for your response and your time, i checkouted svn trunk and built
> Tomcat successfully, its works fine, i also run ant test, for unit testing,
> but it ended with some errors (i've used IBM J9), now i completed this
> step, what do you suggests me to do now?? :)
>

Out of curiosity: Why do you use J9 ?
I guess your first task could be to make all Tomcat tests running on J9 ;-)


>
> I can't find Tomcat on Jira, why?? :)
>

Tomcat is using Bugzilla.
Check http://tomcat.apache.org/bugreport.html


>
> Thank you for your time again.
>
> 2016-04-16 16:25 GMT+01:00 Mark Thomas :
>
> > On 15/04/2016 17:59, Abdessamed MANSOURI wrote:
> > > Hello all,
> > >
> > > I'm newcomer and i want to contribute to Tomcat developement, i have
> some
> > > free time (alots of time), so i want to be useful in this world better
> > than
> > > sleeping all the day, so i'm looking for applying Apache mentoring
> > program,
> > > i'm not guru in Java but not totaly a newbie, so i want to try all my
> > best
> > > to help you guys, who want to be my mentor??
> >
> > Welcome to the Tomcat development community. Feel free to ask any
> > questions you have on this list.
> >
> > > Note : i still student, but i'm not looking to do Tomcat as my final
> > > project (i already have a final project), i wan't to help you (as much
> > as i
> > > can).
> > >
> > > Thank you all for your time.
> >
> > The first step is to make sure you can build Tomcat locally. Follow the
> > instructions in [1] to checkout the latest Tomcat source and and build
> it.
> >
> > Note that the URL you'll need to checkout Tomcat trunk is:
> > https://svn.apache.org/viewvc/tomcat/trunk
> >
> > If you have any questions, just ask.
> >
> > Mark
> >
> >
> > [1] https://svn.apache.org/viewvc/tomcat/trunk/BUILDING.txt?view=markup
> >
> >
> > -
> > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: dev-h...@tomcat.apache.org
> >
> >
>


Re: [VOTE] Release Apache Tomcat 8.5.2

2016-05-13 Thread Martin Grigorov
On Thu, May 12, 2016 at 12:22 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.2 release is now available for voting.
>
> 8.5.2 corrects a regression found in 8.5.1.
>
> The major changes compared to the 8.5.0 release are:
> - Add the org.apache.catalina.servlet4preview package that can be
>   used to gain early access to Servlet 4.0 features. Note that this
>   package will not be present in Tomcat 9.
> - Make default TLS configuration more secure
> - Add direct HTTP/2 connection support
> - Update the packaged version of the Tomcat Native Library to 1.2.7 to
>   pick up the Windows binaries that are based on OpenSSL 1.0.2h and
>   APR 1.5.2.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.2/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1081/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_2/
>
> The proposed 8.5.2 release is:
> [ ] Broken - do not release
> [ ] Alpha  - go ahead and release as 8.5.2
> [X] Beta   - go ahead and release as 8.5.2
> [ ] Stable - go ahead and release as 8.5.2
>

Tested Apache Wicket WebSocket


>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M6

2016-05-13 Thread Martin Grigorov
On Thu, May 12, 2016 at 12:06 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M6 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> 9.0.0.M6 corrects a regression found in 9.0.0.M5
>
> The major changes compared to the 9.0.0.M4 release are:
> - Add direct HTTP/2 connection support
> - Update the implementation of the the proposed Servlet 4.0 API to
>   provide mapping type information for the current request to reflect
>   discussions within the EG.
> - Update the packaged version of the Tomcat Native Library to 1.2.7 to
>   pick up the Windows binaries that are based on OpenSSL 1.0.2h and
>   APR 1.5.2.
>
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M6/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1079/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M6/
>
> The proposed 9.0.0.M6 release is:
> [ ] Broken - do not release
> [X] Alpha - go ahead and release as 9.0.0.M6
>

Tested Apache Wicket WebSocket


>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Regarding files generated by "JJTree"

2016-05-20 Thread Martin Grigorov
Hello Sangeeta,

Yes, those files are auto-generated by a tool: https://javacc.java.net/.


On Fri, May 20, 2016 at 11:41 AM, sangeeta lal 
wrote:

> Dear Dev Team,
>
> Can anyone please give me little information about these files?
>
> Thank You
>
> On Thu, May 19, 2016 at 8:22 PM, sangeeta lal 
> wrote:
>
> >
> > Dear Dev Team,
> >
> >
> > I am Sangeeta. I am a PhD Scholar in the area of automated software
> > engineering. I am currently studying source code of Apache Tomcat
> project.
> > While studying the source code. I noticed a folder in Apache Tomcat
> project
> > consisting of 58 files having following line written in them:
> >
> >
> > "/* *Generated By:JJTree: Do not edit this line. AstLambdaExpression.java
> > Version 4.3 */"*
> >
> >
> > Can anyone please explain me little about the meaning of this line? Are
> > all such files  generated by this tool have no contribution from the
> human
> > developers?
> >
> > I highly appreciate your help!
> >
> > Thanks You
> > Sangeeta
> >
> > --
> > Regards...
> > Sangeeta
> > Assistant Professor
> > CSE Department @JIIT Noida
> >
> >
>
>
> --
> Regards...
> Sangeeta
> Assistant Professor
> CSE Department @JIIT Noida
>


Re: Regarding files generated by "JJTree"

2016-05-20 Thread Martin Grigorov
Hi,

I guess your question is related to
http://markmail.org/message/kw4erakv272hsy3o where someone else already
told you about JavaCC.
AFAIK JavaCC is the only tool used by Tomcat that generates classes.
The number of classes depends on the parser rules so it could be N today
and M tomorrow.
Just grep the sources for this header and use the returned number.


On Fri, May 20, 2016 at 12:01 PM, sangeeta lal 
wrote:

> Dear Sir,
>
> *Thanks for your reply!*
>
> Could you please tell me,  if there is any listing about all the  auto-
> generated files. I have manually identified 59 files in the folder "
> *tomcat\java\org\apache\el\parser*" which are auto generated.
>
> I have following two questions:
>
> 1. Can tomcat project have auto-generated files in some other folder also?
> 2. Is the "JavaCC" only tool which is used to auto-generate the files ? or
> there are some other tools as well?
>
>
> I highly *appreciate your help* and time!
>
> Thank You
> Sangeeta
>
> On Fri, May 20, 2016 at 3:14 PM, Martin Grigorov 
> wrote:
>
> > Hello Sangeeta,
> >
> > Yes, those files are auto-generated by a tool: https://javacc.java.net/.
> >
> >
> > On Fri, May 20, 2016 at 11:41 AM, sangeeta lal 
> > wrote:
> >
> > > Dear Dev Team,
> > >
> > > Can anyone please give me little information about these files?
> > >
> > > Thank You
> > >
> > > On Thu, May 19, 2016 at 8:22 PM, sangeeta lal  >
> > > wrote:
> > >
> > > >
> > > > Dear Dev Team,
> > > >
> > > >
> > > > I am Sangeeta. I am a PhD Scholar in the area of automated software
> > > > engineering. I am currently studying source code of Apache Tomcat
> > > project.
> > > > While studying the source code. I noticed a folder in Apache Tomcat
> > > project
> > > > consisting of 58 files having following line written in them:
> > > >
> > > >
> > > > "/* *Generated By:JJTree: Do not edit this line.
> > AstLambdaExpression.java
> > > > Version 4.3 */"*
> > > >
> > > >
> > > > Can anyone please explain me little about the meaning of this line?
> Are
> > > > all such files  generated by this tool have no contribution from the
> > > human
> > > > developers?
> > > >
> > > > I highly appreciate your help!
> > > >
> > > > Thanks You
> > > > Sangeeta
> > > >
> > > > --
> > > > Regards...
> > > > Sangeeta
> > > > Assistant Professor
> > > > CSE Department @JIIT Noida
> > > >
> > > >
> > >
> > >
> > > --
> > > Regards...
> > > Sangeeta
> > > Assistant Professor
> > > CSE Department @JIIT Noida
> > >
> >
>
>
>
> --
> Regards...
> Sangeeta
> Assistant Professor
> CSE Department @JIIT Noida
>


Re: memory leak in Tomcat 8.0.9

2016-05-20 Thread Martin Grigorov
Hi,


On Fri, May 20, 2016 at 2:55 PM, Sanka, Ambica  wrote:

> Support Team,
>
> We have been using Tomcat 8.0.9 for our applications. We noticed below
> memo= ry leak error and out tomcat could not stopped. We had to kill the
> process = manually. I was reading articles in the internet and this got
> address after=  tomcat 6. But we found error in higher versions. We are not
> sure where to = fix this? Below is the error we are getting
>
> 2016-05-19 14:03:31,161 [localhost-startStop-2] WARN
> org.apache.catalina.l=
>
> oader.WebappClassLoader- The web application [/fmDirectoryService] appears
> = to have started a thread named [Thread-6] but has failed to stop it. This
> i= s very likely to create a memory leak. Stack trace of thread:
>
> java.lang.Thread.sleep(Native Method)
>
> net.atpco.cluster.support.BaseLocator$AdminTask.run(BaseLocator.java:141)
>
> 2016-05-19 14:03:31,197 [localhost-startStop-2] INFO
> org.apache.catalina.c=
>
> ore.ContainerBase.[Catalina].[localhost].[/fmbootstrap]- Destroying Spring
> = FrameworkServlet 'dispatcherServlet'
>
> 2016-05-19 14:03:31,210 [localhost-startStop-2] INFO
> org.apache.catalina.c=
>
> ore.ContainerBase.[Catalina].[localhost].[/fmbootstrap]- Closing Spring
> roo= t WebApplicationContext
>
> 2016-05-19 14:03:31,210 [localhost-startStop-2] INFO
> org.springframework.b=
>
> oot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext-
> Closing=
> org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebAppli=
>
> cationContext@5e119034 org.springframework.boot.context.embedded.Ann cationContext@5e119034
> %3cmailto:org.springframework.boot.context.embedded.Ann>=
>
> otationConfigEmbeddedWebApplicationContext@5e119034>: startup date [Thu
> May=
>
> 19 08:17:39 EDT 2016]; root of context hierarchy May 19, 2016 2:03:31 PM
> com.mongodb.util.management.jmx.JMXMBeanServer unre= gisterMBean
>
> WARNING: Unable to register MBean
> org.mongodb.driver:type=3DConnectionPool,=
>
> clusterId=3D1,host=3Dlocalhost,port=3D27017
>
> javax.management.InstanceNotFoundException:
> org.mongodb.driver:type=3DConne=
>
> ctionPool,clusterId=3D1,host=3Dlocalhost,port=3D27017
>
> at
> com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getMBean(D=
>
> efaultMBeanServerInterceptor.java:1095)
>
> at
> com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.exclusiveU=
>
> nregisterMBean(DefaultMBeanServerInterceptor.java:427)
>
> at
> com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.unregister=
>
> MBean(DefaultMBeanServerInterceptor.java:415)
>
> at
> com.sun.jmx.mbeanserver.JmxMBeanServer.unregisterMBean(JmxMBeanS=
>
> erver.java:546)
>
> at
> com.mongodb.util.management.jmx.JMXMBeanServer.unregisterMBean(J=
>
> MXMBeanServer.java:52)
>
> at
> com.mongodb.JMXConnectionPoolListener.connectionPoolClosed(JMXCo=
>
> nnectionPoolListener.java:68)
>
> at
> com.mongodb.PooledConnectionProvider.close(PooledConnectionProvi=
>
> der.java:107)
>
>
>
> Any kind of help is appreciated.
>

To get some free support please ask at us...@tomcat.apache.org mailing list.
Also please update to latest version of Tomcat (8.0.35) and try again.


>
> Thanks
>
> Ambica.
>
>


Using modern development tools for friendlier environment for newcomers

2016-06-07 Thread Martin Grigorov
Hi devs,

Recently a colleague of mine asked me what it takes to become an Apache
committer.
I've explained him that he has to choose a project that is interesting to
him and start participating in the mailing lists (helping others at users@,
giving opinion and testing releases at dev@), providing patches for open
issues, etc.
Few days later he came back with the following questions:

1) Why Tomcat still uses SVN?
I've told him that this is the SCM tool most of the committers have
experience with and there were some discussions to move to Git several
months back.
I've recommended him to use GitHub's Pull Requests for the time being - PRs
are monitored and merged if approved. Even if Tomcat was using Git, Apache
Infra doesn't provide tool with Pull Request support (GitLab, Gerrit, or
similar) anyway so there is no big difference from a contributor point of
view.

2) Why Tomcat uses Bugzilla?
It is archaic and its UI is unfriendly - he said.
To be honest I didn't have a good answer here. I also don't like Bugzilla.
Everybody knows how to use JIRA! It is hard to explain that Apache JIRA
runs on Tomcat, but Tomcat project itself uses Perl software for issue
tracking (no matter how good Bugzilla is).

I know that SVN, Git, JIRA, Bugzilla are just tools. We can do our work
with any of them.
Maybe there are more (and more important!) reasons why my colleague didn't
start contributing to Tomcat yet but I also agree with him that by moving
to more modern tools Tomcat will become easier and friendlier for newcomers.


Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: Using modern development tools for friendlier environment for newcomers

2016-06-08 Thread Martin Grigorov
Hi,


On Tue, Jun 7, 2016 at 11:33 AM, Mark Thomas  wrote:

> On 07/06/2016 10:17, Martin Grigorov wrote:
> > Hi devs,
> >
> > Recently a colleague of mine asked me what it takes to become an Apache
> > committer.
> > I've explained him that he has to choose a project that is interesting to
> > him and start participating in the mailing lists (helping others at
> users@,
> > giving opinion and testing releases at dev@), providing patches for open
> > issues, etc.
> > Few days later he came back with the following questions:
> >
> > 1) Why Tomcat still uses SVN?
> > I've told him that this is the SCM tool most of the committers have
> > experience with and there were some discussions to move to Git several
> > months back.
> > I've recommended him to use GitHub's Pull Requests for the time being -
> PRs
> > are monitored and merged if approved. Even if Tomcat was using Git,
> Apache
> > Infra doesn't provide tool with Pull Request support (GitLab, Gerrit, or
> > similar) anyway so there is no big difference from a contributor point of
> > view.
>
> If I recall correctly, the consensus last time around was that there was
> merit in exploring the options for using git further with a view to
> migrating if the majority were convinced there was a benefit to the move.
>
> There is an outstanding task (I need to chase it up) for the infra team
> to look at if we could move to a single git repo for multiple branches
> or would need multiple repos.
>

One repo should be possible.
Even if there are some problems with the initial conversion from SVN to Git
the person dealing with it could create N Git repos and then with the help
of "git remote add" combine them into one with N branches and finally push
those branches into a single repository.


>
> > 2) Why Tomcat uses Bugzilla?
> > It is archaic and its UI is unfriendly - he said.
> > To be honest I didn't have a good answer here. I also don't like
> Bugzilla.
> > Everybody knows how to use JIRA! It is hard to explain that Apache JIRA
> > runs on Tomcat, but Tomcat project itself uses Perl software for issue
> > tracking (no matter how good Bugzilla is).
>
> My personal view is Jira is overly complex and horribly slow. Bugzilla
>

I think JIRA is slower because the majority of the projects are there.
But I guess it would be an overkill for Infra to maintain several instances
of JIRA (e.g. sharded by project name).


> just works. We don't need any of the extra features Jira offers. Do we
> want any of them? None come to mind. Others may have a different view.
>

I personally like the JIRA plugins that integrate with the SCM tools.
Committing with "PROJECT_NAME-1234" in the commit message automatically
adds a comment to the respective ticket with a link to Git/SVN repo. It is
very easy to explore the history of a ticket.
Also it has a proper "Fix version" field. With it it is much easier to
create a changelog. No need to maintain one manually.


>
> > I know that SVN, Git, JIRA, Bugzilla are just tools. We can do our work
> > with any of them.
> > Maybe there are more (and more important!) reasons why my colleague
> didn't
> > start contributing to Tomcat yet but I also agree with him that by moving
> > to more modern tools Tomcat will become easier and friendlier for
> newcomers.
>
> The Tomcat community tends to change development technology when it can
> see some direct benefit from the change. It doesn't change just to use
> the latest shiny new toy.
>

I totally agree with "see some benefit"!
I don't agree with "new" :-) Both Git and JIRA are on the market for quite
some time.


>
> git does have some benefits but also some potential complications. My
> view is we are around the tipping point for svn -> git.
>
> Mark
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M8

2016-06-10 Thread Martin Grigorov
On Tue, Jun 7, 2016 at 6:02 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M8 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M6 release are:
> - Improvements to memory leak detection and prevention including the
>   change RMI memory leaks are now correctly treated as application bugs
>   rather than a JRE bug
> - Fix a couple of memory leaks found in Tomcat
> - The HTTP Server header is no longer set by default
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M8/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1085/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M8/
>
> The proposed 9.0.0.M8 release is:
> [ ] Broken - do not release
> [ ] Alpha - go ahead and release as 9.0.0.M8
>

[ X ] Alpha - go ahead and release as 9.0.0.M8

Regards,
Martin



>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Using modern development tools for friendlier environment for newcomers

2016-06-17 Thread Martin Grigorov
Hi Chris,

On Fri, Jun 17, 2016 at 12:51 PM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> Martin,
>
> On 6/8/16 3:25 AM, Martin Grigorov wrote:
> > On Tue, Jun 7, 2016 at 11:33 AM, Mark Thomas  wrote:
> >
> >> On 07/06/2016 10:17, Martin Grigorov wrote:
> >>> Hi devs,
> >>>
> >>> Recently a colleague of mine asked me what it takes to become an Apache
> >>> committer.
> >>> I've explained him that he has to choose a project that is interesting
> to
> >>> him and start participating in the mailing lists (helping others at
> >> users@,
> >>> giving opinion and testing releases at dev@), providing patches for
> open
> >>> issues, etc.
> >>> Few days later he came back with the following questions:
> >>>
> >>> 1) Why Tomcat still uses SVN?
> >>> I've told him that this is the SCM tool most of the committers have
> >>> experience with and there were some discussions to move to Git several
> >>> months back.
> >>> I've recommended him to use GitHub's Pull Requests for the time being -
> >> PRs
> >>> are monitored and merged if approved. Even if Tomcat was using Git,
> >> Apache
> >>> Infra doesn't provide tool with Pull Request support (GitLab, Gerrit,
> or
> >>> similar) anyway so there is no big difference from a contributor point
> of
> >>> view.
> >>
> >> If I recall correctly, the consensus last time around was that there was
> >> merit in exploring the options for using git further with a view to
> >> migrating if the majority were convinced there was a benefit to the
> move.
> >>
> >> There is an outstanding task (I need to chase it up) for the infra team
> >> to look at if we could move to a single git repo for multiple branches
> >> or would need multiple repos.
> >>
> >
> > One repo should be possible.
> > Even if there are some problems with the initial conversion from SVN to
> Git
> > the person dealing with it could create N Git repos and then with the
> help
> > of "git remote add" combine them into one with N branches and finally
> push
> > those branches into a single repository.
> >
> >
> >>
> >>> 2) Why Tomcat uses Bugzilla?
> >>> It is archaic and its UI is unfriendly - he said.
> >>> To be honest I didn't have a good answer here. I also don't like
> >> Bugzilla.
> >>> Everybody knows how to use JIRA! It is hard to explain that Apache JIRA
> >>> runs on Tomcat, but Tomcat project itself uses Perl software for issue
> >>> tracking (no matter how good Bugzilla is).
> >>
> >> My personal view is Jira is overly complex and horribly slow. Bugzilla
> >>
> >
> > I think JIRA is slower because the majority of the projects are there.
> > But I guess it would be an overkill for Infra to maintain several
> instances
> > of JIRA (e.g. sharded by project name).
>
> I think it's slower because it's a sledgehammer where a screwdriver will
> do the job. I've never liked JIRA, but as was previously said "tools are
> tools".
>

At my $dailyJob JIRA is not slow at all.
It is Apache JIRA installation problem, not every JIRA installation.
If you are subscribed to infra@ you will see that people complain
relatively often that it is either down or slow. Last such mail is from
yesterday!
IMO Apache JIRA should be split into several instances.
But here is not the place to discuss this topic!

What I was trying to explain is that Tomcat looks like an ageing product
from a tooling point of view: Bugzilla, SVN, ANT, Gump.
It is hard to make Tomcat development attractive to work with tools from
the 90s (figuratively said).

I am not saying that by changing the tooling suddenly a lot of developers
will want to contribute!
I just share the opinion that many developers consider these things when
trying to find an OSS to contribute to.


> >> just works. We don't need any of the extra features Jira offers. Do we
> >> want any of them? None come to mind. Others may have a different view.
> >>
> >
> > I personally like the JIRA plugins that integrate with the SCM tools.
> > Committing with "PROJECT_NAME-1234" in the commit message automatically
> > adds a comment to the respective ticket with a link to Git/SVN repo. It
> is
> > very easy to explore the history of a ticket.
>
> All of this can be done with svn + bugzilla, too. I guess just nobody
> bothered to do i

Re: [VOTE] Release Apache Tomcat 7.0.70

2016-06-17 Thread Martin Grigorov
On Wed, Jun 15, 2016 at 9:47 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.70 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.70/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1088/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_70/
>
> The proposed 7.0.70 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 7.0.70 Stable
>

[ X ] Stable - go ahead and release as 7.0.70 Stable

Tested our main application and Apache Wicket WebSockets integration.


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M9

2016-07-05 Thread Martin Grigorov
On Mon, Jul 4, 2016 at 9:03 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M9 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M8 release are:
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M9/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1089/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M9/
>
> The proposed 9.0.0.M9 release is:
> [ ] Broken - do not release
>

[ X ] Alpha - go ahead and release as 9.0.0.M9


> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.5.4

2016-07-11 Thread Martin Grigorov
On Wed, Jul 6, 2016 at 11:42 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.4 release is now available for voting.
>
> The major changes compared to the 8.5.3 release are:
>
> - Correct a regression in the embedded packaging
>
> - Add the ability to control the degree of concurrency when processing
>   HTTP/2 connections
>
> - Update to Tomcat Native 1.2.8
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.4/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1090/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_4/
>
> The proposed 8.5.4 release is:
> [ ] Broken - do not release
> [ ] Alpha  - go ahead and release as 8.5.4
> [ ] Beta   - go ahead and release as 8.5.4
>

[ X ] Stable - go ahead and release as 8.5.4


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: svn commit: r1757353 - in /tomcat/trunk: java/org/apache/catalina/filters/CorsFilter.java webapps/docs/changelog.xml

2016-08-23 Thread Martin Grigorov
Hi Mark,

On Tue, Aug 23, 2016 at 12:54 PM,  wrote:

> Author: markt
> Date: Tue Aug 23 10:54:28 2016
> New Revision: 1757353
>
> URL: http://svn.apache.org/viewvc?rev=1757353&view=rev
> Log:
> Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=60008
> When processing CORs requests, treat any origin with a URI scheme of file
> as a valid origin.
>
> Modified:
> tomcat/trunk/java/org/apache/catalina/filters/CorsFilter.java
> tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/java/org/apache/catalina/filters/CorsFilter.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> catalina/filters/CorsFilter.java?rev=1757353&r1=1757352&
> r2=1757353&view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/catalina/filters/CorsFilter.java
> (original)
> +++ tomcat/trunk/java/org/apache/catalina/filters/CorsFilter.java Tue Aug
> 23 10:54:28 2016
> @@ -826,8 +826,14 @@ public final class CorsFilter extends Ge
>  return true;
>  }
>
> -URI originURI;
> +// RFC6454, section 4. "If uri-scheme is file, the implementation
> MAY
> +// return an implementation-defined value.". No limits are okaced
> on
>

There is a typo in "okaced"


> +// that value so treat all file URIs as valid origins.
> +if (origin.startsWith("file://")) {
> +return true;
> +}
>
> +URI originURI;
>  try {
>  originURI = new URI(origin);
>  } catch (URISyntaxException e) {
>
> Modified: tomcat/trunk/webapps/docs/changelog.xml
> URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/
> changelog.xml?rev=1757353&r1=1757352&r2=1757353&view=diff
> 
> ==
> --- tomcat/trunk/webapps/docs/changelog.xml (original)
> +++ tomcat/trunk/webapps/docs/changelog.xml Tue Aug 23 10:54:28 2016
> @@ -191,6 +191,10 @@
>  Ensure that Semaphore.release is called in all
> cases. Even
>  when there is an exception. (violetagg)
>
> +  
> +60008: When processing CORs requests, treat any origin
> with a
> +URI scheme of file as a valid origin. (markt)
> +  
>  
>
>
>
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: The magic phrase to auto-close the PR in github

2016-08-31 Thread Martin Grigorov
Hi Violeta,

On Wed, Aug 31, 2016 at 9:47 AM, Violeta Georgieva 
wrote:

> Hi Mark,
>
> 2016-08-10 14:38 GMT+03:00 Violeta Georgieva :
> >
> >
> >
> > 2016-08-10 14:08 GMT+03:00 Mark Thomas :
> > >
> > > On 10/08/2016 11:45, violet...@apache.org wrote:
> > > > Author: violetagg
> > > > Date: Wed Aug 10 10:45:42 2016
> > > > New Revision: 1755717
> > > >
> > > > URL: http://svn.apache.org/viewvc?rev=1755717&view=rev
> > > > Log:
> > > > MBeans Descriptors How-To is moved to mbeans-descriptors-howto.html.
> Patch provided by Radoslav Husar. This solves Github PR#33
> > >
> > > The magic phrase to auto-close the PR is:
>
> Will the magic phrase auto-close the PR when it is not against trunk?
> https://github.com/apache/tomcat80/pull/6


I think if you merge the commit in tomcat80 branch it should work.
Both https://github.com/apache/tomcat and https://github.com/apache/tomcat80
have their own "trunk" branch in GitHub.


>
> Thanks a lot,
> Violeta
>


Re: The magic phrase to auto-close the PR in github

2016-08-31 Thread Martin Grigorov
Hi,


On Wed, Aug 31, 2016 at 10:25 AM, Violeta Georgieva 
wrote:

> 2016-08-31 11:17 GMT+03:00 Mark Thomas :
> >
> > On 31/08/2016 09:16, Violeta Georgieva wrote:
> > > 2016-08-31 10:59 GMT+03:00 Mark Thomas :
> > >>
> > >> On 31/08/2016 08:47, Violeta Georgieva wrote:
> > >>> Hi Mark,
> > >>>
> > >>> 2016-08-10 14:38 GMT+03:00 Violeta Georgieva :
> > 
> > 
> > 
> >  2016-08-10 14:08 GMT+03:00 Mark Thomas :
> > >
> > > On 10/08/2016 11:45, violet...@apache.org wrote:
> > >> Author: violetagg
> > >> Date: Wed Aug 10 10:45:42 2016
> > >> New Revision: 1755717
> > >>
> > >> URL: http://svn.apache.org/viewvc?rev=1755717&view=rev
> > >> Log:
> > >> MBeans Descriptors How-To is moved to
> mbeans-descriptors-howto.html.
> > >>> Patch provided by Radoslav Husar. This solves Github PR#33
> > >
> > > The magic phrase to auto-close the PR is:
> > >>>
> > >>> Will the magic phrase auto-close the PR when it is not against trunk?
> > >>> https://github.com/apache/tomcat80/pull/6
> > >>
> > >> GitHub integration is only configured for trunk. I can set it up for
> the
> > >> other branches if that is what we want.
> > >
> > > With "trunk" I meant Tomcat 9 repo https://github.com/apache/tomcat
> > >
> > > Is it configured only for Tomcat 9?
> >
> > Currently it is only configured for Tomcat 9.
> >
> > > If yes should we ask the people to prepare the patches against Tomcat 9
> > > only or we can extend this integration for other Tomcat versions?
> >
> > Either is an option. Generally patches are applied to trunk and
> > back-ported but we can't prevent pull requests against earlier versions.
> >
> > I have no preference. What do others think?
>

3rd option: merge all GitHub repos into one.
Currently each SVN branch has its own GitHub repositoty.
Is there a reason for that ?
There could be just one GitHub repo with the same branches as in Apache SVN.
IMO this will simplify the things for the contributors too.


>
> +1 for integration with the other Tomcat versions.
>
> > Mark
> >
> > -
> > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: dev-h...@tomcat.apache.org
> >
>


Re: [VOTE] Release Apache Tomcat 8.0.37

2016-09-02 Thread Martin Grigorov
On Sep 1, 2016 1:57 PM, "Mark Thomas"  wrote:
>
> The proposed Apache Tomcat 8.0.37 release is now available for voting.
>
> The main changes since 8.0.36 are:
>
> - treat paths used to obtain a request dispatcher as encoded
>   (configurable)
>
> - update the packaged version of the Tomcat Native Library to 1.2.8
>
> - various jdbc-pool fixes
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.37/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1093/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_37/
>
> The proposed 8.0.37 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.37

Tested with our main application.

>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>


Re: [VOTE] Release Apache Tomcat 7.0.71

2016-09-09 Thread Martin Grigorov
On Wed, Sep 7, 2016 at 1:00 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.71 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.71/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1094/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_71/
>
> The proposed 7.0.71 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.71 Stable
>

Tested our main application and Apache Wicket WebSocket integration.


Just one minor thingy:

==> logs/catalina.out <==
Sep 09, 2016 9:59:56 PM org.apache.catalina.core.StandardServer await
WARNING: StandardServer.await: Invalid command '' received

I haven't noticed such log entry before.


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 7.0.72

2016-09-14 Thread Martin Grigorov
On Wed, Sep 14, 2016 at 3:01 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.72 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.72/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1095/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_72/
>
> The proposed 7.0.72 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.72 Stable
>

+1 to release!


>
> Regards,
> Violeta
>


Re: How could I get involved into tomcat development?

2016-09-20 Thread Martin Grigorov
Hi,

On Tue, Sep 20, 2016 at 5:50 PM, Tiramisu Ling  wrote:

> How could I take it if I do interest in that bug and want to work on it? I
> see those bugs been assigned to mail list already.
>

You can add a comment that you are working on it.
If you have any questions about the functionality you can ask them here
(dev@) or at us...@tomcat.apache.org if the answer could be known by a
non-committer, e.g. related to configuration, deployment, etc.

If you plan to hang around for longer time I'd recommend to read
https://wiki.apache.org/tomcat/FAQ/Tomcat_User too.

Have fun!

Martin


>
> > 在 2016年9月20日,下午11:22,Mark Thomas  写道:
> >
> >> On 20/09/2016 15:40, Tiramisu Ling wrote:
> >> Hey Mark, thank you for your help :) Do you mean
> >> https://bz.apache.org/bugzilla/show_bug.cgi?id=60008 above instead of
> bug
> >> 6008? Because it tells me bug id is unavailable for
> https://bz.apache.org/
> >> bugzilla/show_bug.cgi?id=6008.
> >
> > Sorry, I meant
> > https://bz.apache.org/bugzilla/show_bug.cgi?id=60087
> >
> > The last digit was lost in the copy/paste.
> >
> > Mark
> >
> >
> >>
> >> 2016-09-20 21:06 GMT+08:00 Mark Thomas :
> >>
>  On 20/09/2016 13:28, Tiramisu Ling wrote:
>  hello everyone,
> 
>  I'm a newbie in tomcat and I would like to get involved into it. Could
> >>> you
>  tell me where to start with it? How could I find something like 'good
> >>> first
>  bug'? Thank you very much :)
> >>>
> >>> A good bug to get started on is usually one that you care about and/or
> >>> are interested in so you are motivated to fix it.
> >>>
> >>> Some possibilities:
> >>> https://bz.apache.org/bugzilla/show_bug.cgi?id=55969
> >>> I'd recommend starting with item 3, then 2 and finally 1.
> >>>
> >>> https://bz.apache.org/bugzilla/show_bug.cgi?id=6008
> >>> Not sure how complex fixing this would be. Just having a clear
> >>> explanation of what is going on would be useful.
> >>>
> >>> Other than that, take a look at the open bugs and pick one you think is
> >>> interesting. Even if you can't fix it, if you can put together a patch
> >>> that adds a test case that demonstrates it that would be a huge help.
> >>>
> >>> Mark
> >>>
> >>>
> >>> -
> >>> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> >>> For additional commands, e-mail: dev-h...@tomcat.apache.org
> >
> >
> > -
> > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: dev-h...@tomcat.apache.org
> >
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Deploying Tomcat on Snappy Ubuntu Core

2016-09-20 Thread Martin Grigorov
Hi Michael,

On Tue, Sep 20, 2016 at 3:10 PM, Michael Hall  wrote:

> Hi Coty,
>
> Have you had an opportunity to try this yet? If you need help please let
> me know, or you could find help on #snappy on Freenode or
> https://gitter.im/ubuntu/snappy-playpen (a new slack-like service
> connected to github)
>

I am an Ubuntu user and I've tried once Snap.
I've installed the featured Notes application and I was amazed to see that
it downloaded 60Mb for such a simple application! After being unzipped it
is 196MB !!
Then I removed it.
I hope Canonical will keep .deb around for the near future!

About your package:
I see it uses "plugs: [network-bind]" to be able to bind the ports, but
does this also allow to make connections to external resources like a
remote DB for example ?


Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov



>
> Michael Hall
> mhall...@gmail.com
>
> On 09/15/2016 10:06 AM, Michael Hall wrote:
> > Hi Coty,
> >
> > To learn more about snaps in general and how to make them you can go to
> > http://snapcraft.io/
> >
> > The tl;dr is that they are self-contained application bundles, including
> > dependencies, that are packed into a squashfs that is then loop-mounted
> > when installed. This means that the application's own files are
> > read-only and isolated from other apps and the system, which makes
> > updating them safe and simple. For Tomcat this means it includes a JRE,
> > OpenSSL, and anything else needed for Tomcat to run.
> >
> > I have attached the files needed to build a Tomcat snap using the the
> > Snapcraft tool (only available on Ubuntu currently), just run "snapcraft
> > snap" in the same directory as these files. The snapcrafy.yaml will pull
> > Tomcat 8.5.5 binary tarball as it's source, so no re-compiling is
> > needed. The run.sh simply sets some environment variables to their
> > proper snap-environment locations, copies the server.xml into
> > CATALINE_BASE (if it's not there), and starts Tomcat.
> >
> > Because the snapcraft.yaml declares this to be a daemon, it will create
> > a systemd service file upon installation and start it automatically.
> > Then you can copy a .war files into $CATALINA_BASE/webapps/ and Tomcat
> > will pick it up. I tested with the sample.war from
> > https://tomcat.apache.org/tomcat-8.0-doc/appdev/sample/ and it works
> > with the servlet portion, but not the JSP (I suspect the JSP compilation
> > is trying write to use a read-only space, but haven't dug too far into
> it).
> >
> > If you don't run Ubuntu the easiest way to build the snap is in a VM or
> > container that has Ubuntu 16.04, just install the snapcraft package from
> > the archive. If you just want to try a pre-built binary, you can
> > download mine from http://people.ubuntu.com/~mhall119/snaps/
> >
> > You can install it on Ubuntu 16.04 or a derivative right away with "snap
> > install $snapfile --force-dangerous". The --force-dangerous is required
> > because the resulting snap won't be signed. On non-Ubuntu distros you
> > can get snaps running by following the instructions on
> > http://snapcraft.io/docs/core/install
> >
> >
> > Michael Hall
> > mhall...@ubuntu.com
> >
> > On 09/14/2016 11:23 PM, Coty Sutherland wrote:
> >> Hi Micheal,
> >>
> >> I hadn't heard of snaps (or used Ubuntu much) but the concept seems
> >> interesting to me. Would you be able to send me links to what you have
> >> so far so I can check it out? I have a few questions, but I'll reserve
> >> those until I get a chance to review what you have.
> >>
> >> Thanks!
> >>
> >>
> >> On Sep 14, 2016 3:51 PM, "Michael Hall"  >> <mailto:mhall...@ubuntu.com>> wrote:
> >>
> >> Hi everyone,
> >>
> >> Ubuntu has developed a new platform for deploying applications using
> >> bundled packages called "snaps". These make it easier to deploy and
> >> update on Ubuntu independently of it's release cycle (and on
> non-Ubuntu
> >> distros too for that matter). I would like to make Tomcat available
> in
> >> this format so it can be more easily used on lightweight cloud
> instances
> >> or devices like the Raspberry Pi.
> >>
> >> I have a working example of Tomcat as a snap, and it works really
> well
> >> with a separate read-only CATALINE_HOME and a writable, versioned
> >> CATALINA_BASE that will allow for 

Re: Deploying Tomcat on Snappy Ubuntu Core

2016-09-20 Thread Martin Grigorov
Hi Michael,

On Tue, Sep 20, 2016 at 9:11 PM, Michael Hall  wrote:

> Hi Martin,
>
>
> On 09/20/2016 02:56 PM, Martin Grigorov wrote:
> > Hi Michael,
> >
> > On Tue, Sep 20, 2016 at 3:10 PM, Michael Hall 
> wrote:
> >
> >> Hi Coty,
> >>
> >> Have you had an opportunity to try this yet? If you need help please let
> >> me know, or you could find help on #snappy on Freenode or
> >> https://gitter.im/ubuntu/snappy-playpen (a new slack-like service
> >> connected to github)
> >>
> >
> > I am an Ubuntu user and I've tried once Snap.
> > I've installed the featured Notes application and I was amazed to see
> that
> > it downloaded 60Mb for such a simple application! After being unzipped it
> > is 196MB !!
> > Then I removed it.
> > I hope Canonical will keep .deb around for the near future!
> >
>
> .deb package aren't going away, snaps are just a new option that bring a
>

Yes, I know that .deb isn't going away.
I just said it to express my frustration with those 196MB.


> lot of benefit. Desktop apps like Notes are currently quite large
> because they bundle the whole GUI toolkit that they use. This is
> something that has a solution underway, but it won't affect services
> like tomcat nearly as much,
>
> The Tomcat snap does include a JRE though, so you always know that one
> is available and that Tomcat will work with it. Even with that the
>

What if I need different combination of Tomcat and JRE versions than what
your Snap versions provide ?
Let's say I experience some bug in the bundled JRE version (e.g. X) and
your next Snap version bundles JRE X+1 but also Tomcat Y+1.
What if I need JRE X+1 and Tomcat Y because there is a regression in Y+1 ?
Just thinking loud here.


> resulting snap is only 48MB. Snaps are never "unzipped", instead they
> are loop-mounted into your filesystem, so the download size is the
>

I haven't read about squashfs, so I'm not sure how exactly it works.
196MB is what "du" program reports.
If it is not disk size then I hope this 60MB download is not unzipped in
the RAM.
http://snapcraft.io/ says "That directory will be compressed into a
squashfs - a zipped directory - and then it will be mounted at
/snap//current when the snap is installed."


> installed size.
>
> > About your package:
> > I see it uses "plugs: [network-bind]" to be able to bind the ports, but
> > does this also allow to make connections to external resources like a
> > remote DB for example ?
> >
>
> I would have to double check. There is a "network" interface that allows
> only out-bound connection, which can be added if "network-bind" doesn't
> already do that.
>

Thanks!


>
> >
> > Martin Grigorov
> > Wicket Training and Consulting
> > https://twitter.com/mtgrigorov
> >
> >
> >
> >>
> >> Michael Hall
> >> mhall...@gmail.com
> >>
> >> On 09/15/2016 10:06 AM, Michael Hall wrote:
> >>> Hi Coty,
> >>>
> >>> To learn more about snaps in general and how to make them you can go to
> >>> http://snapcraft.io/
> >>>
> >>> The tl;dr is that they are self-contained application bundles,
> including
> >>> dependencies, that are packed into a squashfs that is then loop-mounted
> >>> when installed. This means that the application's own files are
> >>> read-only and isolated from other apps and the system, which makes
> >>> updating them safe and simple. For Tomcat this means it includes a JRE,
> >>> OpenSSL, and anything else needed for Tomcat to run.
> >>>
> >>> I have attached the files needed to build a Tomcat snap using the the
> >>> Snapcraft tool (only available on Ubuntu currently), just run
> "snapcraft
> >>> snap" in the same directory as these files. The snapcrafy.yaml will
> pull
> >>> Tomcat 8.5.5 binary tarball as it's source, so no re-compiling is
> >>> needed. The run.sh simply sets some environment variables to their
> >>> proper snap-environment locations, copies the server.xml into
> >>> CATALINE_BASE (if it's not there), and starts Tomcat.
> >>>
> >>> Because the snapcraft.yaml declares this to be a daemon, it will create
> >>> a systemd service file upon installation and start it automatically.
> >>> Then you can copy a .war files into $CATALINA_BASE/webapps/ and Tomcat
> >>> will pick it up. I tested with the sample.war from
> >>> https

Re: Deploying Tomcat on Snappy Ubuntu Core

2016-09-20 Thread Martin Grigorov
Hi Chris,

On Tue, Sep 20, 2016 at 10:51 PM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> Martin,
>
> On 9/20/16 3:28 PM, Martin Grigorov wrote:
> > Hi Michael,
> >
> > On Tue, Sep 20, 2016 at 9:11 PM, Michael Hall 
> wrote:
> >
> >> Hi Martin,
> >>
> >>
> >> On 09/20/2016 02:56 PM, Martin Grigorov wrote:
> >>> Hi Michael,
> >>>
> >>> On Tue, Sep 20, 2016 at 3:10 PM, Michael Hall 
> >> wrote:
> >>>
> >>>> Hi Coty,
> >>>>
> >>>> Have you had an opportunity to try this yet? If you need help please
> let
> >>>> me know, or you could find help on #snappy on Freenode or
> >>>> https://gitter.im/ubuntu/snappy-playpen (a new slack-like service
> >>>> connected to github)
> >>>>
> >>>
> >>> I am an Ubuntu user and I've tried once Snap.
> >>> I've installed the featured Notes application and I was amazed to see
> >> that
> >>> it downloaded 60Mb for such a simple application! After being unzipped
> it
> >>> is 196MB !!
> >>> Then I removed it.
> >>> I hope Canonical will keep .deb around for the near future!
> >>>
> >>
> >> .deb package aren't going away, snaps are just a new option that bring a
> >>
> >
> > Yes, I know that .deb isn't going away.
> > I just said it to express my frustration with those 196MB.
> >
> >
> >> lot of benefit. Desktop apps like Notes are currently quite large
> >> because they bundle the whole GUI toolkit that they use. This is
> >> something that has a solution underway, but it won't affect services
> >> like tomcat nearly as much,
> >>
> >> The Tomcat snap does include a JRE though, so you always know that one
> >> is available and that Tomcat will work with it. Even with that the
> >>
> >
> > What if I need different combination of Tomcat and JRE versions than what
> > your Snap versions provide ?
> > Let's say I experience some bug in the bundled JRE version (e.g. X) and
> > your next Snap version bundles JRE X+1 but also Tomcat Y+1.
> > What if I need JRE X+1 and Tomcat Y because there is a regression in Y+1
> ?
> > Just thinking loud here.
> >
> >
> >> resulting snap is only 48MB. Snaps are never "unzipped", instead they
> >> are loop-mounted into your filesystem, so the download size is the
> >>
> >
> > I haven't read about squashfs, so I'm not sure how exactly it works.
> > 196MB is what "du" program reports.
> > If it is not disk size then I hope this 60MB download is not unzipped in
> > the RAM.
> > http://snapcraft.io/ says "That directory will be compressed into a
> > squashfs - a zipped directory - and then it will be mounted at
> > /snap//current when the snap is installed."
>
> It's like an executable JAR file, except that the kernel loads the thing
> as a filesystem. So 'du' will tell you it's bigger than it actually is
> (it's bigger on the inside than it is on the outside).


> That 60MiB download isn't being uncompressed elsewhere on the disk or
> into RAM. It's being decompressed on the fly as necessary, just like a
> remotely-mounted filesystem isn't copied locally whenever you access
> files. Sore, a file or two might have some parts cached locally, but you
> aren't sucking-down your entire multi-petabyte SAN contents when you
> login to your corporate network.
>

Thanks for the explanation!
But I think the example with reading data from SAN is not exactly the same
as executing a process in the kernel.
To start the process the kernel needs to load (big?!) part of the zipped
bundle. Everything else might be loaded if needed later.

1) Dealing with compressed data is definitely slower than dealing with
uncompressed data, and this is valid both for startup time and runtime.
2) Snaps share nothing, by design. So if more than one app needs the same
dependency then it is not just about the disk space but also duplicated
stuff in memory. This is advertized as Pros but for me is Cons.
3) I cannot find any information about a running Notes app (I've installed
it again for the testing!) neither with 'ps', nor with 'htop', nor with
'snap'. All I can find is a parent 'snapd' process with several forks. If I
need to install a spy software I'll pack it as a Snap :-)

So far I see more drawbacks than benefits. But I am a developer with a
desktop. I guess the points above might not be a problem for server
administrators.


>
> -chris
>
>


Re: [VOTE] Release Apache Tomcat 8.5.6

2016-10-07 Thread Martin Grigorov
On Thu, Oct 6, 2016 at 10:33 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.6 release is now available for voting.
>
> The major changes compared to the 8.5.5 release are:
>
> - Refactoring the non-container thread Async complete()/dispatch()
>   handling to remove the possibility of deadlock
>
> - Update the packaged version of the Tomcat Native Library to
>   1.2.10 to pick up the latest Windows binaries built with
>   OpenSSL 1.0.2j
>
> - Improved UTF-8 handling for the RewriteValve
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.6/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1097/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_6/
>
> The proposed 8.5.6 release is:
> [ ] Broken - do not release
> [ ] Alpha  - go ahead and release as 8.5.6
> [ ] Beta   - go ahead and release as 8.5.6
> [ X ] Stable - go ahead and release as 8.5.6
>

The only thing that bothers me a bit is that I have a lot of those during
start:

07-Oct-2016 15:27:58.342 WARNING [RMI TCP Connection(4)-127.0.0.1]
org.apache.catalina.webresources.Cache.getResource Unable to add the
resource at [/WEB-INF/lib/lucene-memory-5.5.2.jar] to the cache because
there was insufficient free space available after evicting expired cache
entries - consider increasing the maximum size of the cache

I believe there is an entry for each library of my applications and for
(all ?!) .properties and .xml files in the classpath.

If this is normal then the message could be improved to say which cache I
need to touch.

The only thing I've changed in the default configuration was to enable the
HTTP2 connector:

07-Oct-2016 15:13:07.634 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR
based Apache Tomcat Native library 1.2.10 using APR version 1.5.2.
07-Oct-2016 15:13:07.634 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR
capabilities: IPv6 [true], sendfile [true], accept filters [false], random
[true].
07-Oct-2016 15:13:07.634 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR/OpenSSL
configuration: useAprConnector [false], useOpenSSL [true]
07-Oct-2016 15:13:07.637 INFO [main]
org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL
successfully initialized (OpenSSL 1.0.2e 3 Dec 2015)
07-Oct-2016 15:13:07.756 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["http-nio-8080"]
07-Oct-2016 15:13:07.769 INFO [main]
org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared
selector for servlet write/read
07-Oct-2016 15:13:07.773 INFO [main]
org.apache.coyote.http11.AbstractHttp11Protocol.configureUpgradeProtocol
The ["https-openssl-apr-8443"] connector has been configured to support
negotiation to [h2] via ALPN
07-Oct-2016 15:13:07.773 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["https-openssl-apr-8443"]











>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.5.6

2016-10-07 Thread Martin Grigorov
Hi Mark,

On Fri, Oct 7, 2016 at 6:39 PM, Mark Thomas  wrote:

> On 07/10/2016 15:51, Mark Thomas wrote:
> > On 07/10/2016 14:50, Martin Grigorov wrote:
> >> On Thu, Oct 6, 2016 at 10:33 PM, Mark Thomas  wrote:
> >>
> >>> The proposed Apache Tomcat 8.5.6 release is now available for voting.
> >>>
> >>> The major changes compared to the 8.5.5 release are:
> >>>
> >>> - Refactoring the non-container thread Async complete()/dispatch()
> >>>   handling to remove the possibility of deadlock
> >>>
> >>> - Update the packaged version of the Tomcat Native Library to
> >>>   1.2.10 to pick up the latest Windows binaries built with
> >>>   OpenSSL 1.0.2j
> >>>
> >>> - Improved UTF-8 handling for the RewriteValve
> >>>
> >>>
> >>> It can be obtained from:
> >>> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.6/
> >>> The Maven staging repo is:
> >>> https://repository.apache.org/content/repositories/
> orgapachetomcat-1097/
> >>> The svn tag is:
> >>> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_6/
> >>>
> >>> The proposed 8.5.6 release is:
> >>> [ ] Broken - do not release
> >>> [ ] Alpha  - go ahead and release as 8.5.6
> >>> [ ] Beta   - go ahead and release as 8.5.6
> >>> [ X ] Stable - go ahead and release as 8.5.6
> >>>
> >>
> >> The only thing that bothers me a bit is that I have a lot of those
> during
> >> start:
> >>
> >> 07-Oct-2016 15:27:58.342 WARNING [RMI TCP Connection(4)-127.0.0.1]
> >> org.apache.catalina.webresources.Cache.getResource Unable to add the
> >> resource at [/WEB-INF/lib/lucene-memory-5.5.2.jar] to the cache because
> >> there was insufficient free space available after evicting expired cache
> >> entries - consider increasing the maximum size of the cache
> >
> > I suspect that this is the cause:
> >
> > https://bz.apache.org/bugzilla/show_bug.cgi?id=60146
> >
> > We might need to tweak the caching algorithm and/or config.
>
> I haven't been able to reproduce this with a simple test. Can you do
> some debugging and see what code path is triggering the loading of the
> JAR files this way.
>

Here is the stacktrace: http://imgur.com/a/ioRY4
I use the sources of the voted 8.5.6, not the latest 8.5.x.


>
> >> I believe there is an entry for each library of my applications and for
> >> (all ?!) .properties and .xml files in the classpath.
> >>
> >> If this is normal then the message could be improved to say which cache
> I
> >> need to touch.
> >
> > The message could be improved regardless.
>
> Done.
>

It is still not clear to me.
Where I can change the maxSize of this cache ?
https://tomcat.apache.org/tomcat-8.5-doc/index.html doesn't mention
"cache". It is not searchable in the content of the linked pages. Also
Google doesn't give me good results - it finds the javadoc of this class
but this doesn't tell me as a user what should I do.
Is it a good idea to add more details in the log message like "...increase
the max size at $CATALINA_BASE/conf/some.xml > Host > Cache" ?


>
> Mark
>
>
> >
> > Mark
> >
> >
> >>
> >> The only thing I've changed in the default configuration was to enable
> the
> >> HTTP2 connector:
> >>
> >> 07-Oct-2016 15:13:07.634 INFO [main]
> >> org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR
> >> based Apache Tomcat Native library 1.2.10 using APR version 1.5.2.
> >> 07-Oct-2016 15:13:07.634 INFO [main]
> >> org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR
> >> capabilities: IPv6 [true], sendfile [true], accept filters [false],
> random
> >> [true].
> >> 07-Oct-2016 15:13:07.634 INFO [main]
> >> org.apache.catalina.core.AprLifecycleListener.lifecycleEvent
> APR/OpenSSL
> >> configuration: useAprConnector [false], useOpenSSL [true]
> >> 07-Oct-2016 15:13:07.637 INFO [main]
> >> org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL
> >> successfully initialized (OpenSSL 1.0.2e 3 Dec 2015)
> >> 07-Oct-2016 15:13:07.756 INFO [main]
> >> org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
> >> ["http-nio-8080"]
> >> 07-Oct-2016 15:13:07.769 INFO [main]
> >> org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Usin

Re: [VOTE] Release Apache Tomcat 9.0.0.M11

2016-10-08 Thread Martin Grigorov
On Thu, Oct 6, 2016 at 9:51 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M11 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M10 release are:
>
> - Refactoring the non-container thread Async complete()/dispatch()
>   handling to remove the possibility of deadlock
>
> - Update the packaged version of the Tomcat Native Library to
>   1.2.10 to pick up the latest Windows binaries built with
>   OpenSSL 1.0.2j
>
> - Improved UTF-8 handling for the RewriteValve
>
> Along with lots of other bug fixes and improvements
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M11/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1096/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M11/
>
> The proposed 9.0.0.M11 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M11
>

+1 to release


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: 8.5.6 @ central

2016-10-12 Thread Martin Grigorov
Hi,

I've just released 8.0.38, 8.5.6 and 9.0.0.M11 from Apache Nexus to Maven
Central.
They must be publicly available in few hours.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Wed, Oct 12, 2016 at 7:54 AM, Romain Manni-Bucau 
wrote:

> Hi guys,
>
> seems 8.5.6 didnt hit central yet and is still in staging even if the
> announce was sent, as it intended?
>
> PS: I'm interested in 8.5.6 but other "co-"votes are in the same state I
> think
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <https://blog-rmannibucau.rhcloud.com> | Old Wordpress Blog
> <http://rmannibucau.wordpress.com> | Github <https://github.com/
> rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
> <http://www.tomitribe.com> | JavaEE Factory
> <https://javaeefactory-rmannibucau.rhcloud.com>
>


Re: svn commit: r1764897 - in /tomcat/trunk: java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/startup/ java/org/apache/catalina/valves/rewrite/ test/org/apache/tomcat/

2016-10-15 Thread Martin Grigorov
Hi Remy,

On Fri, Oct 14, 2016 at 3:46 PM,  wrote:

> Author: remm
> Date: Fri Oct 14 13:46:45 2016
> New Revision: 1764897
>
> URL: http://svn.apache.org/viewvc?rev=1764897&view=rev
> Log:
> Inspired by 60161: Allow creating subcategories from the container logger
> name. The configuration remains compatible, but some possibly logging
> intensive components get their own playground. Use it for the rewrite valve.
>
> Modified:
> tomcat/trunk/java/org/apache/catalina/Container.java
> tomcat/trunk/java/org/apache/catalina/core/ContainerBase.java
> tomcat/trunk/java/org/apache/catalina/startup/FailedContext.java
> tomcat/trunk/java/org/apache/catalina/valves/rewrite/RewriteValve.java
> tomcat/trunk/test/org/apache/tomcat/unittest/TesterContext.java
> tomcat/trunk/test/org/apache/tomcat/unittest/TesterHost.java
> tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/java/org/apache/catalina/Container.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> catalina/Container.java?rev=1764897&r1=1764896&r2=1764897&view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/catalina/Container.java (original)
> +++ tomcat/trunk/java/org/apache/catalina/Container.java Fri Oct 14
> 13:46:45 2016
> @@ -123,6 +123,13 @@ public interface Container extends Lifec
>
>
>  /**
> + * Return the logger name that the container will use.
> + * @return the abbreviated name of this container for logging messages
> + */
> +public String getLogName();
> +
> +
> +/**
>   * Obtain the JMX name for this container.
>   *
>   * @return the JMX name associated with this container.
>
> Modified: tomcat/trunk/java/org/apache/catalina/core/ContainerBase.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> catalina/core/ContainerBase.java?rev=1764897&r1=1764896&
> r2=1764897&view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/catalina/core/ContainerBase.java
> (original)
> +++ tomcat/trunk/java/org/apache/catalina/core/ContainerBase.java Fri Oct
> 14 13:46:45 2016
> @@ -357,13 +357,41 @@ public abstract class ContainerBase exte
>
>  if (logger != null)
>  return (logger);
> -logger = LogFactory.getLog(logName());
> +logger = LogFactory.getLog(getLogName());
>

What would be the behavior here if #getLogName() returns null ?


>  return (logger);
>
>  }
>
>
>  /**
> + * @return the abbreviated name of this container for logging messages
> + */
> +@Override
> +public String getLogName() {
> +
> +if (logName != null) {
> +return logName;
> +}
> +String loggerName = null;
> +Container current = this;
> +while (current != null) {
> +String name = current.getName();
> +if ((name == null) || (name.equals(""))) {
> +name = "/";
> +} else if (name.startsWith("##")) {
> +name = "/" + name;
> +}
> +loggerName = "[" + name + "]"
> ++ ((loggerName != null) ? ("." + loggerName) : "");
> +current = current.getParent();
> +}
> +logName = ContainerBase.class.getName() + "." + loggerName;
> +return logName;
> +
> +}
> +
> +
> +/**
>   * Return the Cluster with which this Container is associated.  If
> there is
>   * no associated Cluster, return the Cluster associated with our
> parent
>   * Container (if any); otherwise return null.
> @@ -1183,33 +1211,6 @@ public abstract class ContainerBase exte
>  }
>
>
> -/**
> - * @return the abbreviated name of this container for logging messages
> - */
> -protected String logName() {
> -
> -if (logName != null) {
> -return logName;
> -}
> -String loggerName = null;
> -Container current = this;
> -while (current != null) {
> -String name = current.getName();
> -if ((name == null) || (name.equals(""))) {
> -name = "/";
> -} else if (name.startsWith("##")) {
> -name = "/" + name;
> -}
> -loggerName = "[" + name + "]"
> -+ ((loggerName != null) ? ("." + loggerName) : "");
> -current = current.getParent();
> -}
> -logName = ContainerBase.class.getName() + "." + loggerName;
> -return logName;
> -
> -}
> -
> -
>  //  JMX and Registration  
>
>  @Override
>
> Modified: tomcat/trunk/java/org/apache/catalina/startup/FailedContext.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> catalina/startup/FailedContext.java?rev=1764897&r1=1764896&r2=1764897&
> view=diff
> 

Re: svn commit: r1764897 - in /tomcat/trunk: java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/startup/ java/org/apache/catalina/valves/rewrite/ test/org/apache/tomcat/

2016-10-15 Thread Martin Grigorov
On Sat, Oct 15, 2016 at 5:26 PM, Rémy Maucherat  wrote:

> 2016-10-15 11:17 GMT+02:00 Martin Grigorov :
>
> > Hi Remy,
> >
> > On Fri, Oct 14, 2016 at 3:46 PM,  wrote:
> > >  return (logger);
> > > -logger = LogFactory.getLog(logName());
> > > +logger = LogFactory.getLog(getLogName());
> > >
> >
> > What would be the behavior here if #getLogName() returns null ?
> >
>
> It's bad and would cause NPEs.
>
> >
> > >  @Override
> > > +public String getLogName() { return null; }
> > >
> >
> > Maybe it is better to return something like "FailedContextLog" instead ?!
> > This is related to the first question above.
> >
>
> It's not used, and if it is it will cause a NPE like getLogger.
>

If it is never used then it is OK!
Thanks!


>
> Rémy
>


Re: [VOTE] Release Apache Tomcat 6.0.47

2016-10-15 Thread Martin Grigorov
On Thu, Oct 13, 2016 at 12:51 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 6.0.47 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-6/v6.0.47/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1100/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc6.0.x/tags/TOMCAT_6_0_47/
>
> The proposed 6.0.47 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 6.0.47 Stable
>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 8.5.12

2017-03-13 Thread Martin Grigorov
On Mar 8, 2017 7:56 PM, "Mark Thomas"  wrote:

The proposed Apache Tomcat 8.5.12 release is now available for voting.

The major changes compared to the 8.5.11 release are:

- Updates to the early access version of the Serlet 4.0 API to align it
  with the most recent discussions in the Servlet EG

- Support for Java 9 during annotation scanning

- Update Tomcat Native to 1.2.12 to pick up the latest Windows binaries
  built with OpenSSL 1.0.2k

It can be obtained from:
https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.12/
The Maven staging repo is:
https://repository.apache.org/content/repositories/orgapachetomcat-1121/
The svn tag is:
http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_12/

The proposed 8.5.12 release is:
[ ] Broken - do not release
[ X ] Stable - go ahead and release as 8.5.12


Regards,
Martin


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org


Re: [VOTE] Release Apache Tomcat 7.0.76

2017-03-13 Thread Martin Grigorov
On Thu, Mar 9, 2017 at 3:11 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 7.0.76 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.76/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1123/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_76/
>
> The proposed 7.0.76 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.76 Stable
>

Regards,
Martin


> Regards,
> Violeta
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.42

2017-03-13 Thread Martin Grigorov
On Thu, Mar 9, 2017 at 12:05 PM, Mark Thomas  wrote:

> Correcting the subject.
>
> On 08/03/17 20:26, Mark Thomas wrote:
> > The proposed Apache Tomcat 8.0.42 release is now available for voting.
> >
> > The main changes since 8.0.41 are:
> >
> > - Limited relaxation of the HTTP request line validation
> >
> > - Support for Java 9 during annotation scanning
> >
> > - Update Tomcat Native to 1.2.12 to pick up the latest Windows binaries
> >   built with OpenSSL 1.0.2k
> >
> > It can be obtained from:
> > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.42/
> > The Maven staging repo is:
> > https://repository.apache.org/content/repositories/orgapachetomcat-1122/
> > The svn tag is:
> > http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_42/
> >
> > The proposed 8.0.42 release is:
> > [ ] Broken - do not release
> > [ X ] Stable - go ahead and release as 8.0.42
>

Regards,
Martin


> >
> > -
> > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> > For additional commands, e-mail: dev-h...@tomcat.apache.org
> >
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: svn commit: r1788741 - in /tomcat/trunk: java/org/apache/catalina/connector/CoyoteAdapter.java webapps/docs/changelog.xml

2017-03-26 Thread Martin Grigorov
Hi Violeta,

On Sun, Mar 26, 2017 at 6:21 PM,  wrote:

> Author: violetagg
> Date: Sun Mar 26 16:21:03 2017
> New Revision: 1788741
>
> URL: http://svn.apache.org/viewvc?rev=1788741&view=rev
> Log:
> Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=60911
> Ensure NPE will not be thrown when looking for SSL session ID. Based on a
> pacth by Didier Gutacker.
>
> Modified:
> tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
> tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/java/org/apache/catalina/connector/
> CoyoteAdapter.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> catalina/connector/CoyoteAdapter.java?rev=1788741&r1=1788740&r2=1788741&
> view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
> (original)
> +++ tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
> Sun Mar 26 16:21:03 2017
> @@ -980,9 +980,11 @@ public class CoyoteAdapter implements Ad
>  SSL_ONLY.equals(request.getServletContext()
>  .getEffectiveSessionTrackingModes()) &&
>  request.connector.secure) {
> -request.setRequestedSessionId(
> -request.getAttribute(SSLSupport.SESSION_ID_KEY).
> toString());
> -request.setRequestedSessionSSL(true);
> +String sessionId = (String) request.getAttribute(
> SSLSupport.SESSION_ID_KEY);
>

Either this cast will lead to ClassCastException...


> +if (sessionId != null) {
> +request.setRequestedSessionId(sessionId.toString());
>

... or this this call to #toString() is not needed.


> +request.setRequestedSessionSSL(true);
> +}
>  }
>  }
>
>
> Modified: tomcat/trunk/webapps/docs/changelog.xml
> URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/
> changelog.xml?rev=1788741&r1=1788740&r2=1788741&view=diff
> 
> ==
> --- tomcat/trunk/webapps/docs/changelog.xml (original)
> +++ tomcat/trunk/webapps/docs/changelog.xml Sun Mar 26 16:21:03 2017
> @@ -93,6 +93,10 @@
>  single utility class and update the code to use the new utility
> class.
>  (markt)
>
> +  
> +60911: Ensure NPE will not be thrown when looking for
> SSL
> +session ID. Based on a pacth by Didier Gutacker. (violetagg)
> +  
>  
>
>
>
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: svn commit: r1788771 - in /tomcat/trunk/java/org/apache/coyote/http2: LocalStrings.properties Stream.java

2017-03-26 Thread Martin Grigorov
Hi Mark,


On Sun, Mar 26, 2017 at 9:31 PM,  wrote:

> Author: markt
> Date: Sun Mar 26 19:31:25 2017
> New Revision: 1788771
>
> URL: http://svn.apache.org/viewvc?rev=1788771&view=rev
> Log:
> Additional header validation
> Found with the h2spec tool written by Moto Ishizawa.
>
> Modified:
> tomcat/trunk/java/org/apache/coyote/http2/LocalStrings.properties
> tomcat/trunk/java/org/apache/coyote/http2/Stream.java
>
> Modified: tomcat/trunk/java/org/apache/coyote/http2/LocalStrings.
> properties
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> coyote/http2/LocalStrings.properties?rev=1788771&r1=
> 1788770&r2=1788771&view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/coyote/http2/LocalStrings.properties
> (original)
> +++ tomcat/trunk/java/org/apache/coyote/http2/LocalStrings.properties Sun
> Mar 26 19:31:25 2017
> @@ -74,10 +74,12 @@ pingManager.roundTripTime=Connection [{0
>
>  stream.closed=Connection [{0}], Stream [{1}], Unable to write to stream
> once it has been closed
>  stream.header.case=Connection [{0}], Stream [{1}], HTTP header name [{2}]
> must be in lower case
> +stream.header.connection=Connection [{0}], Stream [{1}], HTTP header
> [connection] is not permitted in an HTTP/2 request
>  stream.header.debug=Connection [{0}], Stream [{1}], HTTP header [{2}],
> Value [{3}]
>  stream.header.duplicate=Connection [{0}], Stream [{1}], received
> multiple [{3}] headers
>  stream.header.noPath=Connection [{0}], Stream [{1}], The [:path] pseudo
> header was empty
>  stream.header.required=Connection [{0}], Stream [{1}], One or more
> required headers was missing
> +stream.header.te=Connection [{0}], Stream [{1}], HTTP header [te] is not
> permitted tohave the value [{2}] in an HTTP/2 request
>

Small typo in "tohave" - misses space.


>  stream.header.unexpectedPseudoHeader=Connection [{0}], Stream [{1}],
> Pseudo header [{2}] received after a regular header
>  stream.header.unknownPseudoHeader=Connection [{0}], Stream [{1}],
> Unknown pseudo header [{2}] received
>  stream.notWritable=Connection [{0}], Stream [{1}], This stream is not
> writable
>
> Modified: tomcat/trunk/java/org/apache/coyote/http2/Stream.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> coyote/http2/Stream.java?rev=1788771&r1=1788770&r2=1788771&view=diff
> 
> ==
> --- tomcat/trunk/java/org/apache/coyote/http2/Stream.java (original)
> +++ tomcat/trunk/java/org/apache/coyote/http2/Stream.java Sun Mar 26
> 19:31:25 2017
> @@ -233,6 +233,18 @@ class Stream extends AbstractStream impl
>  getConnectionId(), getIdentifier(), name));
>  }
>
> +if ("connection".equals(name)) {
> +throw new HpackException(sm.getString("
> stream.header.connection",
> +getConnectionId(), getIdentifier()));
> +}
> +
> +if ("te".equals(name)) {
> +if (!"trailers".equals(value)) {
> +throw new HpackException(sm.getString("stream.header.te",
> +getConnectionId(), getIdentifier(), value));
> +}
> +}
> +
>  if (headerStateErrorMsg != null) {
>  // Don't bother processing the header since the stream is
> going to
>  // be reset anyway
>
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.5.13

2017-03-28 Thread Martin Grigorov
On Mon, Mar 27, 2017 at 5:13 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.13 release is now available for voting.
>
> The major changes compared to the 8.5.12 release are:
>
> - Various HTTP/2 improvements
>
> - Fixes for sendfile related issues that could cause subsequent requests
>   to experience IllegalStateExceptions
>
> - Servlet 4.0 updates
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.13/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1126/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_13/
>
> The proposed 8.5.13 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.5.13
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M19

2017-03-29 Thread Martin Grigorov
On Mon, Mar 27, 2017 at 2:56 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M19 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M18 release are:
>
> - Various HTTP/2 improvements
>
> - Fixes for sendfile related issues that could cause subsequent requests
>   to experience IllegalStateExceptions
>
> - Servlet 4.0 updates
>
>
> Along with lots of other bug fixes and improvements
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M19/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1125/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M19/
>
> The proposed 9.0.0.M19 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M19
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.43

2017-03-29 Thread Martin Grigorov
On Tue, Mar 28, 2017 at 5:28 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 8.0.43 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.43/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1127/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_43/
>
> The proposed 8.0.43 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.43
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 7.0.77

2017-03-30 Thread Martin Grigorov
On Tue, Mar 28, 2017 at 6:45 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.77 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.77/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1128/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_77/
>
> The proposed 7.0.77 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.77 Stable
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 8.5.14

2017-04-14 Thread Martin Grigorov
On Thu, Apr 13, 2017 at 3:12 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.14 release is now available for voting.
>
> The major changes compared to the 8.5.13 release are:
>
> - Correct a regression that broke JMX operations (including the Manager
>   web application) if the operation took parameters
>
> - Add JMX support for Tribes components
>
> - Calls to isReady() no longer throw exceptions after timeouts for async
>   servlets
>
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.14/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1132/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_14/
>
> The proposed 8.5.14 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.5.14
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M20

2017-04-14 Thread Martin Grigorov
On Wed, Apr 12, 2017 at 10:11 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M20 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M19 release are:
>
> - Correct a regression that broke JMX operations (including the Manager
>   web application) if the operation took parameters
>
> - Add JMX support for Tribes components
>
> - Calls to isReady() no longer throw exceptions after timeouts for async
>   servlets
>
>
> Along with lots of other bug fixes and improvements
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M20/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1131/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M20/
>
> The proposed 9.0.0.M20 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M20
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [ANN] New committer: Michael Osipov

2017-05-08 Thread Martin Grigorov
Welcome, Michael!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Mon, May 8, 2017 at 10:08 AM, Mark Thomas  wrote:

> On behalf of the Tomcat committers I am pleased to announce that
> Michael Osipov (michaelo) has been voted in as a new Tomcat committer.
>
> Please join me in welcoming him.
>
> Regards,
>
> Mark
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.5.15

2017-05-09 Thread Martin Grigorov
On Fri, May 5, 2017 at 1:38 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.15 release is now available for voting.
>
> The major changes compared to the 8.5.13 release are:
>
> - Various improvements to the handling of static custom error pages
>
> - Update to Eclipse JDT Compiler 4.6.3
>
> - Review those places where Tomcat re-encodes a URI or URI component
>   and ensure that that correct encoding is consistently applied.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.15/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1134/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_15/
>
> The proposed 8.5.15 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.5.15
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M21

2017-05-09 Thread Martin Grigorov
On Fri, May 5, 2017 at 11:03 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M21 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M20 release are:
>
> - Update the default URIEncoding for a Connector to UTF-8 as required
>   by the Servlet 4.0 specification.
>
> - Various improvements to the handling of static custom error pages
>
> - Update to Eclipse JDT Compiler 4.6.3
>
> Along with lots of other bug fixes and improvements
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M21/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1133/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M21/
>
> The proposed 9.0.0.M21 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M21
>


Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.44

2017-05-14 Thread Martin Grigorov
On Wed, May 10, 2017 at 8:41 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 8.0.44 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.44/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1136/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_44/
>
> The proposed 8.0.44 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.44
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 7.0.78

2017-05-15 Thread Martin Grigorov
On Wed, May 10, 2017 at 5:47 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.78 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.78/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1135/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_78/
>
> The proposed 7.0.78 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.78 Stable
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 8.5.8

2016-11-07 Thread Martin Grigorov
On Thu, Nov 3, 2016 at 10:50 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.8 release is now available for voting.
>
> 8.5.8 corrects a regression 8.5.7.
>
> The major changes compared to the 8.5.6 release are:
>
> - Implement header limits for HTTP/2
>
> - Improve handling of I/O errors with async processing
>
> - Fail earlier on invalid HTTP requests
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.8/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1104/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_8/
>
> The proposed 8.5.8 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.5.8
>

Tested my daily job app and Apache Wicket Native WebSocket demo app


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.39

2016-11-10 Thread Martin Grigorov
[ X ] Stable - go ahead and release as 8.0.39

On Wed, Nov 9, 2016 at 10:41 AM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 8.0.39 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.39/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1107/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_39/
>
> The proposed 8.0.39 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 8.0.39
>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 7.0.73

2016-11-10 Thread Martin Grigorov
[ X ] Stable - go ahead and release as 7.0.73 Stable

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Mon, Nov 7, 2016 at 11:15 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.73 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.73/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1106/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_73/
>
> The proposed 7.0.73 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 7.0.73 Stable
>
> Regards,
> Violeta
>


Re: svn commit: r1774526 - in /tomcat/trunk/java/org/apache/jasper: compiler/EncodingDetector.java security/SecurityClassLoad.java

2016-12-15 Thread Martin Grigorov
Hi Mark,

On Thu, Dec 15, 2016 at 10:34 PM,  wrote:

> Author: markt
> Date: Thu Dec 15 21:34:06 2016
> New Revision: 1774526
>
> URL: http://svn.apache.org/viewvc?rev=1774526&view=rev
> Log:
> Add a new encoding detector implementation.
> The BoM encoding detection is based in the previous code.
> The prolog encoding detection delegates to the JRE's XM than the custom Jasper parser.
>
> Added:
> tomcat/trunk/java/org/apache/jasper/compiler/EncodingDetector.java
>  (with props)
> Modified:
> tomcat/trunk/java/org/apache/jasper/security/SecurityClassLoad.java
>
> Added: tomcat/trunk/java/org/apache/jasper/compiler/EncodingDetector.java
> URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/
> jasper/compiler/EncodingDetector.java?rev=1774526&view=auto
> 
> ==
> --- tomcat/trunk/java/org/apache/jasper/compiler/EncodingDetector.java
> (added)
> +++ tomcat/trunk/java/org/apache/jasper/compiler/EncodingDetector.java
> Thu Dec 15 21:34:06 2016
> @@ -0,0 +1,214 @@
> +/*
> + * Licensed to the Apache Software Foundation (ASF) under one or more
> + * contributor license agreements.  See the NOTICE file distributed with
> + * this work for additional information regarding copyright ownership.
> + * The ASF licenses this file to You under the Apache License, Version 2.0
> + * (the "License"); you may not use this file except in compliance with
> + * the License.  You may obtain a copy of the License at
> + *
> + *  http://www.apache.org/licenses/LICENSE-2.0
> + *
> + * Unless required by applicable law or agreed to in writing, software
> + * distributed under the License is distributed on an "AS IS" BASIS,
> + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
> implied.
> + * See the License for the specific language governing permissions and
> + * limitations under the License.
> + */
> +package org.apache.jasper.compiler;
> +
> +import java.io.BufferedInputStream;
> +import java.io.IOException;
> +import java.io.InputStream;
> +
> +import javax.xml.stream.XMLInputFactory;
> +import javax.xml.stream.XMLStreamException;
> +import javax.xml.stream.XMLStreamReader;
> +
> +/*
> + * The BoM detection is derived from:
> + * http://svn.us.apache.org/viewvc/tomcat/trunk/java/org/
> apache/jasper/xmlparser/XMLEncodingDetector.java?annotate=1742248
> + */
> +class EncodingDetector {
> +
> +private static final XMLInputFactory XML_INPUT_FACTORY;
> +static {
> +XML_INPUT_FACTORY = XMLInputFactory.newFactory();
> +}
> +
> +private final BomResult bomResult;
> +private final String prologEncoding;
> +
> +
> +/*
> + * TODO: Refactor Jasper InputStream creation and handling so the
> + *   InputStream passed to this method is buffered and therefore
> saves
> + *   on multiple opening and re-opening of the same file.
> + */
> +EncodingDetector(InputStream is) throws IOException {
> +// Keep buffer size to a minimum here. BoM will be no more than 4
> bytes
> +// so that is the maximum we need to buffer
> +BufferedInputStream bis = new BufferedInputStream(is, 4);
> +bis.mark(4);
> +
> +bomResult = processBom(bis);
> +
> +// Reset the stream back to the start to allow the XML prolog
> detection
> +// to work. Skip any BoM we discovered.
> +bis.reset();
> +if (bomResult != null) {
> +for (int i = 0; i < bomResult.skip; i++) {
> +is.read();
> +}
> +}
> +
> +prologEncoding = getPrologEncoding(bis);
> +}
> +
> +
> +String getBomEncoding() {
> +return bomResult.encoding;
> +}
> +
> +
> +Boolean getBigEndian() {
> +return bomResult.bigEndian;
> +}
> +
> +
> +int getSkip() {
> +return bomResult.skip;
> +}
> +
> +
> +String getPrologEncoding() {
> +return prologEncoding;
> +}
> +
> +
> +private String getPrologEncoding(InputStream stream) {
> +String encoding = null;
> +try {
> +XMLStreamReader xmlStreamReader = XML_INPUT_FACTORY.
> createXMLStreamReader(stream);
> +encoding = xmlStreamReader.getCharacterEncodingScheme();
> +} catch (XMLStreamException e) {
> +// Ignore
> +}
> +return encoding;
> +}
> +
> +
> +private BomResult processBom(InputStream stream) {
> +// Read first four bytes (or as many are available) and determine
> +// encoding
> +try {
> +final byte[] b4 = new byte[4];
> +int count = 0;
> +int singleByteRead;
> +while (count < 4) {
> +singleByteRead = stream.read();
> +if (singleByteRead == -1) {
> +break;
> +}
> +b4[count] = (byte) singleByteRead;
> +count++;
> +}
> +
> +return parseBom(

Re: [VOTE] Release Apache Tomcat 8.5.10

2017-01-06 Thread Martin Grigorov
[ X ] Stable - go ahead and release as 8.5.10

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Fri, Jan 6, 2017 at 12:38 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.10 release is now available for voting.
>
> The major changes compared to the 8.5.9 release are:
>
> - HTTP/2 fixes and improvements
>
> - Simpler JSP file encoding detector that delegates XML prolog
>   encoding detection to the JRE rather than using a custom XML
>   parser.
>
> - Improve the logic that selects an address to use to unlock the
>   Acceptor to take account of platforms what do not listen on all
>   local addresses when configured with an address of 0.0.0.0 or ::
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.10/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_10/
>
> The proposed 8.5.10 release is:
> [ ] Broken - do not release
> [ ] Stable - go ahead and release as 8.5.10
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Wrong type of the value of javax.servlet.error.exception_type

2017-01-06 Thread Martin Grigorov
Hi,

I've just upgraded my local/development Tomcat to 8.5.10 and I've hit a
problem in Apache Wicket:

java.lang.ClassCastException: java.lang.String cannot be cast to
java.lang.Class
at
org.apache.wicket.protocol.http.servlet.ErrorAttributes.of(ErrorAttributes.java:152)


line 152 is:
Class type = (Class)request.getAttribute("javax.servlet.error.exception_type");

In a debugger I see that the value is the class name, not the class itself.

According to
http://download.oracle.com/otn-pub/jcp/servlet-3.0-fr-eval-oth-JSpec/servlet-3_0-final-spec.pdf,
p.10.9.1, table 10-1 the type of the value should be:

Request Attributes  Type
javax.servlet.error.status_code java.lang.Integer
javax.servlet.error.exception_type java.lang.Class   <<< a Class
javax.servlet.error.message java.lang.String
javax.servlet.error.exception java.lang.Throwable
javax.servlet.error.request_uri java.lang.String
javax.servlet.error.servlet_name java.lang.String


I didn't see any change related to this between 8.5.8 and 8.5.10 so I'm not
sure whether this should be a stopper for the release of 8.5.10.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


Re: Wrong type of the value of javax.servlet.error.exception_type

2017-01-09 Thread Martin Grigorov
Hi Chris,

On Fri, Jan 6, 2017 at 9:49 PM, Christopher Schultz <
ch...@christopherschultz.net> wrote:

> Martin,
>
> On 1/6/17 8:23 AM, Martin Grigorov wrote:
> > I've just upgraded my local/development Tomcat to 8.5.10 and I've hit a
> > problem in Apache Wicket:
> >
> > java.lang.ClassCastException: java.lang.String cannot be cast to
> > java.lang.Class
> > at
> > org.apache.wicket.protocol.http.servlet.ErrorAttributes.
> of(ErrorAttributes.java:152)
> >
> >
> > line 152 is:
> > Class type = (Class > Throwable>)request.getAttribute("javax.servlet.error.exception_type");
> >
> > In a debugger I see that the value is the class name, not the class
> itself.
> >
> > According to
> > http://download.oracle.com/otn-pub/jcp/servlet-3.0-fr-
> eval-oth-JSpec/servlet-3_0-final-spec.pdf,
> > p.10.9.1, table 10-1 the type of the value should be:
> >
> > Request Attributes  Type
> > javax.servlet.error.status_code java.lang.Integer
> > javax.servlet.error.exception_type java.lang.Class   <<< a Class
> > javax.servlet.error.message java.lang.String
> > javax.servlet.error.exception java.lang.Throwable
> > javax.servlet.error.request_uri java.lang.String
> > javax.servlet.error.servlet_name java.lang.String
> >
> >
> > I didn't see any change related to this between 8.5.8 and 8.5.10 so I'm
> not
> > sure whether this should be a stopper for the release of 8.5.10.
>
> I only see a single instance of javax.servlet.error.exception_type in
> 8.5 trunk (in javax/servlet/RequestDispatcher.ERROR_EXCEPTION_TYPE) and
> a single use of ERROR_EXCEPTION_TYPE itself (in
> o.a.c.core.StandardHostValve) and the code is fairly straightforward:
>
> // line 330:
> request.setAttribute(RequestDispatcher.ERROR_EXCEPTION_TYPE,
>   realError.getClass());
>
> The reference "realError" is a java.lang.Throwable, and, presumably,
> realError.getClass will always return a java.lang.Class object.
>
> Can you see where that request attribute is being set in your test? I
> wonder if either Wicket or the application itself is abusing that
> request attribute.
>

Thanks for your answer!
Since Tomcat is not guilty here it must be the middleware! I've found it
easily:
https://github.com/spring-projects/spring-boot/search?utf8=%E2%9C%93&q=ERROR_EXCEPTION_TYPE
I'll log an issue at Spring Boot!



>
> -chris
>
>


Re: [VOTE] Release Apache Tomcat 8.5.11

2017-01-12 Thread Martin Grigorov
On Tue, Jan 10, 2017 at 10:28 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.5.11 release is now available for voting.
>
> The major changes compared to the 8.5.9 release are:
>
> - HTTP/2 fixes and improvements
>
> - Improve the logic that selects an address to use to unlock the
>   Acceptor to take account of platforms what do not listen on all
>   local addresses when configured with an address of 0.0.0.0 or ::
>
> - Fix a bug in APR/native socket close handling that resulted in
>   unexpected errors for upgraded connections
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.5.11/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1113/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.5.x/tags/TOMCAT_8_5_11/
>
> The proposed 8.5.11 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.5.11
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M17

2017-01-12 Thread Martin Grigorov
On Tue, Jan 10, 2017 at 10:28 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M17 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M15 release are:
>
> - HTTP/2 fixes and improvements
>
> - Improve the logic that selects an address to use to unlock the
>   Acceptor to take account of platforms what do not listen on all
>   local addresses when configured with an address of 0.0.0.0 or ::
>
> - Fix a bug in APR/native socket close handling that resulted in
>   unexpected errors for upgraded connections
>
> Along with lots of other bug fixes and improvements
>
> For full details, see the changelog:
> http://svn.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M17/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1112/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M17/
>
> The proposed 9.0.0.M17 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M17
>

Regards,
Martin


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 7.0.74

2017-01-15 Thread Martin Grigorov
On Fri, Jan 13, 2017 at 11:55 AM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.74 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.74/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1115/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_74/
>
> The proposed 7.0.74 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.74 Stable
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 8.0.40

2017-01-15 Thread Martin Grigorov
On Fri, Jan 13, 2017 at 1:39 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 8.0.40 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.40/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1116/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_40/
>
> The proposed 8.0.40 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.40
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 7.0.75

2017-01-19 Thread Martin Grigorov
On Wed, Jan 18, 2017 at 10:45 PM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.75 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.75/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1117/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_75/
>
> The proposed 7.0.75 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.75 Stable
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [VOTE] Release Apache Tomcat 8.0.41

2017-01-19 Thread Martin Grigorov
On Thu, Jan 19, 2017 at 12:07 AM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 8.0.41 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.41/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1118/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_41/
>
> The proposed 8.0.41 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.41
>

Regards,
Martin


>
> Regards,
> Violeta
>


Re: [ANN] New committer: Emmanuel Bourg

2017-01-21 Thread Martin Grigorov
On Jan 20, 2017 7:12 PM, "Mark Thomas"  wrote:

On behalf of the Tomcat committers I am pleased to announce that
Emmanuel Bourg (ebourg) has been voted in as a new Tomcat committer.

Please join me in welcoming him.


Welcome, Emmanuel!
And thank you for your work on Debian too!


Regards,

Mark

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org


Re: Publish snapshots from the Buidlbot

2017-01-24 Thread Martin Grigorov
Hi,

On Mon, Jan 23, 2017 at 11:53 AM, Mark Thomas  wrote:

> I think it would be useful if we configured buildbot to publish
> snapshots (probably as part of the daily build) to repository.a.o.
> Therefore I have requested the appropriate credentials from infra and
> when I have them I'll make the necessary changes tot he buildbot config.
> It might also be necessary to tweak our build scripts.
>

+1
I think Spring Boot folks will find them useful! And anyone else who embeds
Tomcat.



>
> Mark
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Read events suspend/resume logic in websocket impl to achieve backpressure

2017-02-06 Thread Martin Grigorov
Hi Violeta,

On Mon, Feb 6, 2017 at 8:55 PM, Violeta Georgieva 
wrote:

> Hi,
>
> Currently JSR356 provides possibility to add message handlers in order to
> receive web socket
> messages but there is no way to instruct the web socket implementation to
> suspend for a while
> the incoming messages (backpressure) so that the application is able to
> process the already delivered messages.
> The other web containers (Jetty, Undertow) supports such functionality so I
> would like to introduce it in Tomcat.
> Here [1] I prepared one possible implementation.
>
> What do you think about this feature and the proposed implementation?
>

It think it would be better to create a Pull Request even if the work is
not complete.
This way others will be able to comment on the changes and everyone here at
dev@ will see the comments.
At the moment it is possible to comment on your commits (in your repo) but
then only you will receive the feedback.
With [2] it is much easier to see the whole diff but it is not possible to
comment on it.


>
> Regards,
> Violeta
> [1] https://github.com/violetagg/tomcat/commits/ws-suspend-resume
>

[2]
https://github.com/apache/tomcat/compare/trunk...violetagg:ws-suspend-resume


Re: [VOTE] Release Apache Tomcat 9.0.0.M2

2016-01-23 Thread Martin Grigorov
Hi,


On Fri, Jan 22, 2016 at 11:22 PM, Mark Thomas  wrote:

> On 21/01/2016 12:38, Mark Thomas wrote:
> > The proposed Apache Tomcat 9.0.0.M2 release is now available for voting.
> >
> > This is the second milestone release for the 9.0.x branch. It should be
> > noted that, as a milestone release:
> > - Servlet 4.0 is not finalised
> > - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
> >
> > The major changes compared to the 9.0.0.M1 branch are:
> > - Ability to use OpenSSL with JSSE configuration
> > - Update to Tomcat-native 1.2.4 to pick up Windows binaries based on
> >   OpenSSL 1.0.2e
> > - Allow HTTP redirects to be relative
> > - Lots of bug fixes
> >
> > For full details, see the changelog:
> >
> http://svn.us.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
> >
> > It can be obtained from:
> > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M2/
> > The Maven staging repo is:
> > https://repository.apache.org/content/repositories/orgapachetomcat-1059/
> > The svn tag is:
> > http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M2/
> >
> > The proposed 9.0.0.M2 release is:
> > [ ] Broken - do not release
> > [X] Alpha - go ahead and release as 9.0.0.M2
>
> Unit tests pass.
> Simple smoke tests pass.
>
> Mark
>
>


Here 9.0.0.M2 fails to start the AprEndpoint.


3-Jan-2016 17:36:58.787 INFO [main]
org.apache.catalina.startup.VersionLoggerListener.log Command line
argument: -Djava.library.path=/usr/local/apr/lib/
23-Jan-2016 17:36:58.787 INFO [main]
org.apache.catalina.startup.VersionLoggerListener.log Command line
argument: -Dcatalina.base=/tmp/tc9.0.0.M2/apache-tomcat-9.0.0.M2
23-Jan-2016 17:36:58.787 INFO [main]
org.apache.catalina.startup.VersionLoggerListener.log Command line
argument: -Dcatalina.home=/tmp/tc9.0.0.M2/apache-tomcat-9.0.0.M2
23-Jan-2016 17:36:58.788 INFO [main]
org.apache.catalina.startup.VersionLoggerListener.log Command line
argument: -Djava.io.tmpdir=/tmp/tc9.0.0.M2/apache-tomcat-9.0.0.M2/temp
23-Jan-2016 17:36:58.788 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent Loaded APR
based Apache Tomcat Native library 1.2.4 using APR version 1.5.2.
23-Jan-2016 17:36:58.788 INFO [main]
org.apache.catalina.core.AprLifecycleListener.lifecycleEvent APR
capabilities: IPv6 [true], sendfile [true], accept filters [false], random
[true].
23-Jan-2016 17:36:58.791 INFO [main]
org.apache.catalina.core.AprLifecycleListener.initializeSSL OpenSSL
successfully initialized (OpenSSL 1.0.2e 3 Dec 2015)
23-Jan-2016 17:36:58.891 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["http-apr-8080"]
23-Jan-2016 17:36:58.899 INFO [main]
org.apache.coyote.http11.AbstractHttp11Protocol.configureUpgradeProtocol
The ["https-apr-8443"] connector has been configured to support negotiation
to [h2] via ALPN
23-Jan-2016 17:36:58.900 INFO [main]
org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler
["https-apr-8443"]
23-Jan-2016 17:36:58.900 SEVERE [main]
org.apache.coyote.AbstractProtocol.init Failed to initialize end point
associated with ProtocolHandler ["https-apr-8443"]
 java.lang.NullPointerException
at org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:366)
at
org.apache.tomcat.util.net.AbstractEndpoint.init(AbstractEndpoint.java:790)
at
org.apache.coyote.AbstractProtocol.init(AbstractProtocol.java:547)
at
org.apache.coyote.http11.AbstractHttp11Protocol.init(AbstractHttp11Protocol.java:66)
at
org.apache.catalina.connector.Connector.initInternal(Connector.java:1010)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at
org.apache.catalina.core.StandardService.initInternal(StandardService.java:549)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at
org.apache.catalina.core.StandardServer.initInternal(StandardServer.java:855)
at
org.apache.catalina.util.LifecycleBase.init(LifecycleBase.java:107)
at org.apache.catalina.startup.Catalina.load(Catalina.java:606)
at org.apache.catalina.startup.Catalina.load(Catalina.java:629)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:311)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:494)

Line 366 is: for (String protocol : sslHostConfig.getEnabledProtocols()) {
sshHostConfig is used earlier, so it seems the result of
#getEnabledProtocols() is null.

My conf/server.conf looks like:







I just uncommented it and changed the paths to the certificate files.

I run Ubuntu 15.10, Apr 1.5.2, Openssl 1.0.2e, Tomcat Native 1

Re: [VOTE] Release Apache Tomcat 8.0.31

2016-01-23 Thread Martin Grigorov
On Fri, Jan 22, 2016 at 11:21 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.0.31 release is now available for voting.
>
> The main changes since 8.0.30 are:
>
> - Restore the default for mapperContextRootRedirectEnabled to true
>
> - Update the packaged version of the Tomcat Native Library to 1.2.4
>   to pick up the Windows binaries that are based on OpenSSL 1.0.2e
>
> - Expand session attribute filtering on load/unload to all managers
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.31/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1060/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_31/
>
> The proposed 8.0.31 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.31
>

Tested my main application and Apache Wicket WebSocket integration (JSR356).


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M2

2016-01-23 Thread Martin Grigorov
Hi Rémy,


On Sat, Jan 23, 2016 at 6:37 PM, Rémy Maucherat  wrote:

> 2016-01-23 17:51 GMT+01:00 Martin Grigorov :
>
> > Hi,
> > 23-Jan-2016 17:36:58.900 SEVERE [main]
> > org.apache.coyote.AbstractProtocol.init Failed to initialize end point
> > associated with ProtocolHandler ["https-apr-8443"]
> >  java.lang.NullPointerException
> > at
> > org.apache.tomcat.util.net.AprEndpoint.bind(AprEndpoint.java:366)
> >
>
>
> > Line 366 is: for (String protocol : sslHostConfig.getEnabledProtocols())
> {
> > sshHostConfig is used earlier, so it seems the result of
> > #getEnabledProtocols() is null.
> >
> > My conf/server.conf looks like:
> >  > protocol="org.apache.coyote.http11.Http11AprProtocol"
> >maxThreads="150" SSLEnabled="true" >
> >  className="org.apache.coyote.http2.Http2Protocol"
> > />
> > 
> >  > certificateKeyFile="/tmp/tc9.0.0.M2/private-key.pem"
> >  certificateFile="/tmp/tc9.0.0.M2/cert.pem"
> >  type="RSA" />
> > 
> > 
> >
> > I just uncommented it and changed the paths to the certificate files.
> >
> > I run Ubuntu 15.10, Apr 1.5.2, Openssl 1.0.2e, Tomcat Native 1.2.4.
> > Please let me know if you need more information!
> >
> > Ok, well, it doesn't work ... Maybe it would be a great time to give a
> shot to the NIO(2) + OpenSSL support ! :)
>

What changes I should apply to be able to test HTTP2 ?
I've changed the protocol:







and created ~/.keystore.
Now I can start Tomcat and test my apps successfully with HTTP 1.1.
The "Server" response header is "Apache-Coyote/1.1". And my plugin for
Google Chrome says that SPDY/HTTP2 is not enabled.


>
> Besides that, the JSSE code went into a refactoring, and the APR connector
> didn't get it. The enabled protocols are now parsed in the superclass of
> the SSLUtil and the set on the host config, that doesn't happen with APR. I
> don't really understand why the APR connector didn't continue using
> sslHostConfig.getProtocols.
>
> Rémy
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M2

2016-01-26 Thread Martin Grigorov
On Thu, Jan 21, 2016 at 1:38 PM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M2 release is now available for voting.
>
> This is the second milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M1 branch are:
> - Ability to use OpenSSL with JSSE configuration
> - Update to Tomcat-native 1.2.4 to pick up Windows binaries based on
>   OpenSSL 1.0.2e
> - Allow HTTP redirects to be relative
> - Lots of bug fixes
>
> For full details, see the changelog:
> http://svn.us.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M2/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1059/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M2/
>
> The proposed 9.0.0.M2 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M2
>

With Rémy's help I was able to test my apps with HTTP2 without APR.
My conf/server.conf looks like:







Thanks, Rémy!


>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 8.0.32

2016-02-04 Thread Martin Grigorov
On Wed, Feb 3, 2016 at 10:05 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 8.0.32 release is now available for voting.
>
> The main changes since 8.0.30 are:
>
> - Restore the default for mapperContextRootRedirectEnabled to true
>
> - Update the packaged version of the Tomcat Native Library to 1.2.4
>   to pick up the Windows binaries that are based on OpenSSL 1.0.2e
>
> - Expand session attribute filtering on load/unload to all managers
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.32/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1063/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_32/
>
> The proposed 8.0.32 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 8.0.32
>
>
Regards,
Martin


> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 9.0.0.M3

2016-02-04 Thread Martin Grigorov
On Tue, Feb 2, 2016 at 1:20 AM, Mark Thomas  wrote:

> The proposed Apache Tomcat 9.0.0.M3 release is now available for voting.
>
> This is a milestone release for the 9.0.x branch. It should be
> noted that, as a milestone release:
> - Servlet 4.0 is not finalised
> - The EGs have not started work on JSP 2.4, EL 3.1 or WebSocket 1.2/2.0
>
> The major changes compared to the 9.0.0.M1 branch are:
> - Ability to use OpenSSL with JSSE configuration
> - Update to Tomcat-native 1.2.4 to pick up Windows binaries based on
>   OpenSSL 1.0.2e
> - Allow HTTP redirects to be relative
> - Lots of bug fixes
>
> For full details, see the changelog:
> http://svn.us.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-9/v9.0.0.M3/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1062/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_9_0_0_M3/
>
> The proposed 9.0.0.M3 release is:
> [ ] Broken - do not release
> [ X ] Alpha - go ahead and release as 9.0.0.M3
>
>
Regards,
Martin


> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: [VOTE] Release Apache Tomcat 7.0.68

2016-02-11 Thread Martin Grigorov
On Tue, Feb 9, 2016 at 8:18 AM, Violeta Georgieva 
wrote:

> The proposed Apache Tomcat 7.0.68 release is now available for voting.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.68/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-1064/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_68/
>
> The proposed 7.0.68 release is:
> [ ] Broken - do not release
> [ X ] Stable - go ahead and release as 7.0.68 Stable
>

Tested our main application and Apache Wicket WebSocket integration.


>
> Regards,
> Violeta
>


Re: svn commit: r1733080 - in /tomcat/trunk: java/org/apache/tomcat/util/buf/UriUtil.java webapps/docs/changelog.xml

2016-03-01 Thread Martin Grigorov
Hi Mark,

On Tue, Mar 1, 2016 at 3:37 PM,  wrote:

> Author: markt
> Date: Tue Mar  1 14:37:46 2016
> New Revision: 1733080
>
> URL: http://svn.apache.org/viewvc?rev=1733080&view=rev
> Log:
> Expand the fix for BZ 59001 to cover the special sequences used in
> Tomcat's custom jar:war: URL
>
> Modified:
> tomcat/trunk/java/org/apache/tomcat/util/buf/UriUtil.java
> tomcat/trunk/webapps/docs/changelog.xml
>
> Modified: tomcat/trunk/java/org/apache/tomcat/util/buf/UriUtil.java
> URL:
> http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/buf/UriUtil.java?rev=1733080&r1=1733079&r2=1733080&view=diff
>
> ==
> --- tomcat/trunk/java/org/apache/tomcat/util/buf/UriUtil.java (original)
> +++ tomcat/trunk/java/org/apache/tomcat/util/buf/UriUtil.java Tue Mar  1
> 14:37:46 2016
> @@ -106,6 +106,9 @@ public final class UriUtil {
>  private static String makeSafeForJarUrl(String input) {
>



>  // Since "!/" has a special meaning in a JAR URL, make sure that
> the
>  // sequence is properly escaped if present.
> -return input.replaceAll("!/", "%21/");
> +String tmp = input.replaceAll("!/", "%21/");
> +// Tomcat's custom jar:war: URL handling treats */ and ^/ as
> special
> +tmp = tmp.replaceAll("^/", "%5e/");
> +return tmp.replaceAll("\\*/", "%2a/");
>

How often this method is expected to be called? I guess at least once per
request.

My concern is about the performance of String#replaceAll. It uses Regex and
is slower than custom solutions like
https://github.com/apache/wicket/blob/ffa34c6bfbd2ccd8340e23ff1601edd3e0e941d6/wicket-util/src/main/java/org/apache/wicket/util/string/Strings.java#L748

When I don't have access to such util methods in the classpath then I
prefer to pre-compile the Pattern as a constant and just match on it:
e.g. PERCENT_21_PATTERN.matcher(input).replaceAll("%21/")

Additionally I have the feeling that 'tmp.replaceAll("^/", "%5e/");' won't
behave as desired. I think it would match for any String that starts with a
slash because of '^'. You may need to Pattern.quote() it.


>  }
>  }
>
> Modified: tomcat/trunk/webapps/docs/changelog.xml
> URL:
> http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1733080&r1=1733079&r2=1733080&view=diff
>
> ==
> --- tomcat/trunk/webapps/docs/changelog.xml (original)
> +++ tomcat/trunk/webapps/docs/changelog.xml Tue Mar  1 14:37:46 2016
> @@ -107,6 +107,10 @@
>  59001: Correctly handle the case when Tomcat is
> installed on
>  a path where one of the segments ends in an exclamation mark.
> (markt)
>
> +  
> +Expand the fix for 59001 to cover the special
> sequences used
> +in Tomcat's custom jar:war: URLs. (markt)
> +  
>
>  Switch to the web application class loader to the
>  ParallelWebappClassLoader by default. (markt)
>
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: svn commit: r1733080 - in /tomcat/trunk: java/org/apache/tomcat/util/buf/UriUtil.java webapps/docs/changelog.xml

2016-03-02 Thread Martin Grigorov
Hi Mark,


On Tue, Mar 1, 2016 at 6:53 PM, Mark Thomas  wrote:

> On 01/03/2016 14:57, Martin Grigorov wrote:
> > On Tue, Mar 1, 2016 at 3:37 PM,  wrote:
> >
> >> Author: markt
> >> Date: Tue Mar  1 14:37:46 2016
> >> New Revision: 1733080
> >>
> >> URL: http://svn.apache.org/viewvc?rev=1733080&view=rev
> >> Log:
> >> Expand the fix for BZ 59001 to cover the special sequences used in
> >> Tomcat's custom jar:war: URL
>
> 
>
> > How often this method is expected to be called? I guess at least once per
> > request.
>
> That is not correct. It is generally called during web application
> start. I'd typically expect it to be called twice per JAR plus a few
> more times per web application for configuration files (depending on
> Host configuration).
>

OK. If the method is not called very often then it is not a big deal.


>
> > My concern is about the performance of String#replaceAll. It uses Regex
> and
> > is slower than custom solutions like
> >
> https://github.com/apache/wicket/blob/ffa34c6bfbd2ccd8340e23ff1601edd3e0e941d6/wicket-util/src/main/java/org/apache/wicket/util/string/Strings.java#L748
> >
> > When I don't have access to such util methods in the classpath then I
> > prefer to pre-compile the Pattern as a constant and just match on it:
> > e.g. PERCENT_21_PATTERN.matcher(input).replaceAll("%21/")
>
> Given how infrequently this code will be called, when it will be called
> and the overhead of JAR handling overall compared to the contribution of
> these calls I don't think a custom replaceAll() is necessary (although
> if user feedback is different for some use cases we can always revisit
> that).
>
> The pre-compiled Pattern approach might be worth looking at. I'll see if
> I can put together a simple benchmark and add it to the unit tests.
>

I've seen the following commit with the compiled Pattern!


>
> > Additionally I have the feeling that 'tmp.replaceAll("^/", "%5e/");'
> won't
> > behave as desired. I think it would match for any String that starts
> with a
> > slash because of '^'. You may need to Pattern.quote() it.
>
> It does behave as intended. There was a test case that checked that that
> wasn't checked in with the original commit.
>

Are you sure? ;-)

public static void main(String[] args) {
System.err.println("aaa^/bbb".replaceAll("^/", "C"));
System.err.println("aaa^/bbb".replaceAll("\\^/", "C"));
}

Executing this prints:
aaa^/bbb
aaaCbbb

In the following commit this is escaped and works correctly!
Thanks!


>
> Mark
>
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: dev-h...@tomcat.apache.org
>
>


Re: Cloud clustering support using Kubernetes

2018-10-04 Thread Martin Grigorov
Hi,

I cannot find the original mail now (I think it was sent by Bertrand
Delacretaz two years ago) but json.org's licence is not ASL2 compatible.
For that reason several Apache projects (Apache Wicket one of them) had to
migrate to something else.
Wicket choose https://github.com/tdunning/open-json and then improved it to
https://github.com/openjson/openjson. The APIs are almost identical to make
the transition easier.

On Thu, Oct 4, 2018 at 12:27 PM Rémy Maucherat  wrote:

> On Wed, Oct 3, 2018 at 10:27 PM Christopher Schultz <
> ch...@christopherschultz.net> wrote:
>
> > -BEGIN PGP SIGNED MESSAGE-
> > Hash: SHA256
> >
> > Rémy,
> >
> > On 10/3/18 09:48, Rémy Maucherat wrote:
> > > Hi,
> > >
> > > As I talked about during the latest TomcatCon (and the previous one
> > > in London actually ...), there's a cloud aware cluster members
> > > provider that can be contributed to Tomcat.
> > >
> > > The current code is here:
> > > https://github.com/rmaucher/tomcat-in-the-cloud It uses Kubernetes
> > > to retrieve the members of a cluster, rather than multicast (which
> > > isn't available) or static (which is well ... static) member
> > > providers.
> > >
> > > Credits: Maxime Beck and JGroups did the initial code Keiichi
> > > Fujino explained how to refactor it to fit in the Catalina cluster
> > > API and I refactored it as he told me to
> > >
> > > Problems: Only does Kubernetes for now (which is likely ok since
> > > it's now widely available) JSON parser dependency (org.json) that
> > > is likely not ok to have as is in the lib folder (solutions:
> > > package renaming using a script or include json code in Tomcat)
> >
> > Solr uses this JSON parser which is quite fast, although the API is a
> > little little awkward because of it:
> >
> > https://github.com/yonik/noggit
> >
> > AL2 license
> >
> > I'm not sure it's necessary to have a "streaming JSON" parser as
> > opposed to a more "traditional" one where the whole JSON object is
> > converted into objects before the client code can do anything with them.
> >
>
> The json from Kube is simple.
>
> The org.json parser is very dom like, this event based one looks good I
> guess. Is it worth changing my code ? Given the parser size, event based
> nature and the presence of a "writer", this noggit could be worth package
> renaming (IMO for this one that's the only viable strategy as I'm not sure
> there's much maintenance or use going on - maybe it's bug free ;) ). After
> all, we might need/use more json handling in Tomcat in the future (right
> ?).
>
> Rémy
>


  1   2   3   4   5   >