[Resin-interest] Resin 4.0.44 killing itself?
Something is killing my resin process. The watchdog log shows this when it happens: [2015/06/01 21:13:45.624] {watchdog-app-0} Watchdog detected close of Resin[app-0,pid=3728] exit reason: SIGKILL (signal=9) [2015/06/01 21:13:45.628] {watchdog-app-0} WatchdogChild[app-0] starting [2015/06/01 21:13:45.677] {watchdog-app-0} Watchdog starting Resin[app-0] This seems to correlate with invoking an action that spawns some threaded activity. Note that this is a webapp I've been running for years on an older VM, and a few days ago I moved it to a new VM. ps shows this: 4985 ?Sl 0:25 /usr/lib/jvm/java-8-oracle/bin/java -Xmx2048m -XX:MaxPermSize=256m -Dresin.server=app-0 -Djava.util.logging.manager=com.caucho.log.LogManagerImpl -Djava.system.class.loader=com.caucho.loader.SystemClassLoader -Djava.endorsed.dirs=/usr/lib/jvm/java-8-oracle/jre/lib/endorsed:/lz/usr/resin/current//endorsed:/lz/var/www/endorsed -Djavax.management.builder.initial=com.caucho.jmx.MBeanServerBuilderImpl -Djava.awt.headless=true -Djava.awt.headlesslib=true -Dresin.home=/lz/usr/resin/current/ -Xss1m -d64 -server com.caucho.server.resin.Resin --root-directory /lz/var/www -conf /lz/etc/resin/resin.xml -server app-0 -socketwait 50229 -root-directory /lz/var/www -log-directory /logs/resin restart 21256 ?Sl11:12 /usr/lib/jvm/java-8-oracle/bin/java -Dresin.watchdog=app-0 -Djava.util.logging.manager=com.caucho.log.LogManagerImpl -Djavax.management.builder.initial=com.caucho.jmx.MBeanServerBuilderImpl -Djava.awt.headless=true -Djava.awt.headlesslib=true -Dresin.home=/lz/usr/resin/current/ -Dresin.root=/lz/var/www -Xrs -Xss256k -Xmx32m -d64 -server com.caucho.boot.WatchdogManager -root-directory /lz/var/www -conf /lz/etc/resin/resin.xml -log-directory /logs/resin start --log-directory /logs/resin I started resin as root with resinctl start. I'm not sure what else to look at. Any suggestions? Thanks! -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Resin 4.0.44 killing itself?
0 sudo Jun 1 22:09:05 tycho2 kernel: [945096.296139] [ 8147] 0 8147 1868 24 90 0 tail Jun 1 22:09:05 tycho2 kernel: [945096.296141] Out of memory: Kill process 4985 (java) score 614 or sacrifice child Jun 1 22:09:05 tycho2 kernel: [945096.296208] Killed process 4985 (java) total-vm:4146944kB, anon-rss:313332kB, file-rss:0kB On Jun 1, 2015, at 14:39 , Scott Ferguson f...@caucho.com wrote: On 6/1/15 2:19 PM, Rick Mann wrote: Something is killing my resin process. The watchdog log shows this when it happens: [2015/06/01 21:13:45.624] {watchdog-app-0} Watchdog detected close of Resin[app-0,pid=3728] exit reason: SIGKILL (signal=9) [2015/06/01 21:13:45.628] {watchdog-app-0} WatchdogChild[app-0] starting [2015/06/01 21:13:45.677] {watchdog-app-0} Watchdog starting Resin[app-0] This seems to correlate with invoking an action that spawns some threaded activity. Note that this is a webapp I've been running for years on an older VM, and a few days ago I moved it to a new VM. ps shows this: Is there anything in the resin log? The only 'kill' is in the watchdog, and it doesn't use a sigkill. It just calls the JVM's process.close(). I checked the JNI and there's no kill there. Anything in /var/log possibly? -- Scott 4985 ?Sl 0:25 /usr/lib/jvm/java-8-oracle/bin/java -Xmx2048m -XX:MaxPermSize=256m -Dresin.server=app-0 -Djava.util.logging.manager=com.caucho.log.LogManagerImpl -Djava.system.class.loader=com.caucho.loader.SystemClassLoader -Djava.endorsed.dirs=/usr/lib/jvm/java-8-oracle/jre/lib/endorsed:/lz/usr/resin/current//endorsed:/lz/var/www/endorsed -Djavax.management.builder.initial=com.caucho.jmx.MBeanServerBuilderImpl -Djava.awt.headless=true -Djava.awt.headlesslib=true -Dresin.home=/lz/usr/resin/current/ -Xss1m -d64 -server com.caucho.server.resin.Resin --root-directory /lz/var/www -conf /lz/etc/resin/resin.xml -server app-0 -socketwait 50229 -root-directory /lz/var/www -log-directory /logs/resin restart 21256 ?Sl11:12 /usr/lib/jvm/java-8-oracle/bin/java -Dresin.watchdog=app-0 -Djava.util.logging.manager=com.caucho.log.LogManagerImpl -Djavax.management.builder.initial=com.caucho.jmx.MBeanServerBuilderImpl -Djava.awt.headless=true -Djava.awt.headlesslib=true -Dresin.home=/lz/usr/resin/current/ -Dresin.root=/lz/var/www -Xrs -Xss256k -Xmx32m -d64 -server com.caucho.boot.WatchdogManager -root-directory /lz/var/www -conf /lz/etc/resin/resin.xml -log-directory /logs/resin start --log-directory /logs/resin I started resin as root with resinctl start. I'm not sure what else to look at. Any suggestions? Thanks! ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Using gradle Spring Boot to deploy a WAR in resin
I'm just getting started moving my ant-based Spring 3/Servlet 3 app to gradle. I'm starting from scratch. The getting started guides all show using an embedded Tomcat, but I want to deploy a webapp in my resin instance. This page describes how to do that: http://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#build-tool-plugins-gradle-packaging Unfortunately, it uses a Tomcat-specific thing, and I don't see how to modify that for Resin. To go a bit further: I don't actually want a WAR file. I want the unpackaged directory structure, and I'll point my resin at it. Does anyone know what the minimal build.gradle file looks like to meet all those needs? Thanks! -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] https libcurl support in Quercus?
On Jan 23, 2015, at 14:27 , Nam Nguyen n...@caucho.com wrote: Message: 1 Date: Thu, 22 Jan 2015 11:09:24 -0800 From: Rick Mann rm...@latencyzero.com Subject: Re: [Resin-interest] resin-interest Digest, Vol 101, Issue 1 To: General Discussion for the Resin application server resin-interest@caucho.com Message-ID: 5d0f03b8-db84-4fa2-8214-f3fdc1b6b...@latencyzero.com Content-Type: text/plain;charset=us-ascii I thought Wordpress was a sort of flagship app you guys intended to support. Hi Rick, We're moving away from apps because: 1. it's a neverending battle 2. there's no monetary benefit in it for us Does that mean you're moving away from PHP support in general? Is Quercus going away? If so, can you publish a good connector strategy to have Resin front PHP apps? Thanks. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Quercus DateTime::setISODate()?
I just updated WordPress, and got this: com.caucho.quercus.UnimplementedException: `DateTime::setISODate()' has not been implemented. I'm on Resin 4.0.37. The Caucho website shows Quercus up to 4.0.39 but Resin is 4.0.41. Is setISODate() implemented in 4.0.41? -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] resin-interest Digest, Vol 101, Issue 1
I thought Wordpress was a sort of flagship app you guys intended to support. Sent from my iPhone On Jan 22, 2015, at 09:36, Nam Nguyen n...@caucho.com wrote: Message: 1 Date: Tue, 20 Jan 2015 12:11:09 -0800 From: Rick Mann rm...@latencyzero.com Subject: [Resin-interest] https libcurl support in Quercus? To: General Discussion for the Resin application server resin-interest@caucho.com Message-ID: bb27f58e-5d66-422e-be5f-7545303c9...@latencyzero.com Content-Type: text/plain; charset=us-ascii What's the status of this problem in Resin's PHP support these days? http://bugs.caucho.com/view.php?id=5649 http://bugs.caucho.com/view.php?id=5634 The last report is '10065' is CURLOPT_CAINFO and I just stubbed it out because Quercus currently does not support non-JVM certificates. Root issue: I think this is a pretty serious weakness in terms of supporting WordPress. Hi Rick, We do not plan on updating libcurl, so there will be issues with Wordpress going forward. -- Nam ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] https libcurl support in Quercus?
What's the status of this problem in Resin's PHP support these days? http://bugs.caucho.com/view.php?id=5649 http://bugs.caucho.com/view.php?id=5634 The last report is '10065' is CURLOPT_CAINFO and I just stubbed it out because Quercus currently does not support non-JVM certificates. Root issue: I think this is a pretty serious weakness in terms of supporting WordPress. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] requires compiled JNI started with 'start'. Resin cannot use user-name when started as a console process?
What does user-name requires compiled JNI started with 'start'. Resin cannot use user-name when started as a console process mean? I just updated from 4.0.38 and 4.0.41, and now I'm getting that message. (It's possible the .38 version was not pro). I used the following to configure and install resin: cd resin-pro-4.0.41 ./configure --prefix /lz/usr/resin/4.0.41 --enable-64bit --enable-ssl --with-resin-root=/lz/var --with-resin-conf=/lz/etc/resin --with-resin-log=/logs/resin make sudo make install -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] OpenSSL Issues Building/Installing 4.0.41 on OS X 10.10 Yosemite
I just tried to download and install 4.0.41, and got this: OPENSSL : No OpenSSL has been found *** OpenSSL libraries cannot be compiled *** The full output is here: http://pastebin.com/VfB7NsNY I think this is due to Apple deprecating OpenSSL. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] OpenSSL Issues Building/Installing 4.0.41 on OS X 10.10 Yosemite
Yes, of course Xcode is installed. I see what your solution is doing, but that's a pretty heavy-handed fix, especially if one has brew installed. I'm trying to install openssl via brew; we'll see where that leads. On Oct 26, 2014, at 14:18 , Keith Fetterman keithfetter...@gmail.com wrote: Hi Rick Do you have Xcode installed? I have not tried to build resin on OS X 10.10, but I had a similar problem on OS X 10.9 until I installed Xcode. When I was building Resin 4.0.37, I also had to create the symlink /usr/local/include that pointed to: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include I hope this helps Keith On Oct 26, 2014, at 2:12 PM, Rick Mann rm...@latencyzero.com wrote: I just tried to download and install 4.0.41, and got this: OPENSSL : No OpenSSL has been found *** OpenSSL libraries cannot be compiled *** The full output is here: http://pastebin.com/VfB7NsNY I think this is due to Apple deprecating OpenSSL. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Warnings while building 4.0.41
Got a few warnings in the C code: http://pastebin.com/BSJGrvZp I'd feel a lot better if it built with these warnings corrected. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] OpenSSL Issues Building/Installing 4.0.41 on OS X 10.10 Yosemite
It worked, to use brew to install openssl (or update to the latest): $ brew update brew upgrade $ brew install openssl brew link openssl --force On Oct 26, 2014, at 14:19 , Rick Mann rm...@latencyzero.com wrote: Yes, of course Xcode is installed. I see what your solution is doing, but that's a pretty heavy-handed fix, especially if one has brew installed. I'm trying to install openssl via brew; we'll see where that leads. On Oct 26, 2014, at 14:18 , Keith Fetterman keithfetter...@gmail.com wrote: Hi Rick Do you have Xcode installed? I have not tried to build resin on OS X 10.10, but I had a similar problem on OS X 10.9 until I installed Xcode. When I was building Resin 4.0.37, I also had to create the symlink /usr/local/include that pointed to: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include I hope this helps Keith On Oct 26, 2014, at 2:12 PM, Rick Mann rm...@latencyzero.com wrote: I just tried to download and install 4.0.41, and got this: OPENSSL : No OpenSSL has been found *** OpenSSL libraries cannot be compiled *** The full output is here: http://pastebin.com/VfB7NsNY I think this is due to Apple deprecating OpenSSL. -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick Mann rm...@latencyzero.com ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Anyone got Spring Security experience?
I realize this is a bit off-topic, but the Spring Security forum is nothing but crickets, so I was hoping there were Resin users who've successfully used Spring Security (in particular, using pure Java config). Am I in luck? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Any way to tell resin to put WEB-INF/tmp somewhere else?
On Mar 12, 2014, at 19:57 , Alex Rojkov a...@caucho.com wrote: On Mar 12, 2014, at 7:51 PM, Rick Mann rm...@latencyzero.com wrote: It would be nice for it to create its work directories somewhere else, not inside my webapp distros. Is this possible? Should be possible with work-dir and temp-dir tags. http://www.caucho.com/resin-4.0/reference.xtp#workdir http://www.caucho.com/resin-4.0/reference.xtp#tempdir One more question: Can I set this in app-default.xml web-app-default with some suitable ${appname} EL variable? work-dir${resin.root}/resin-data/work/${appname}//work-dir temp-dir${resin.root}/resin-data/tmp/${appname}//temp-dir -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Any way to tell resin to put WEB-INF/tmp somewhere else?
Hmm. I found docs that suggested ${webApp.name} would work, but it evaluated to empty. On Mar 31, 2014, at 19:00 , Rick Mann rm...@latencyzero.com wrote: On Mar 12, 2014, at 19:57 , Alex Rojkov a...@caucho.com wrote: On Mar 12, 2014, at 7:51 PM, Rick Mann rm...@latencyzero.com wrote: It would be nice for it to create its work directories somewhere else, not inside my webapp distros. Is this possible? Should be possible with work-dir and temp-dir tags. http://www.caucho.com/resin-4.0/reference.xtp#workdir http://www.caucho.com/resin-4.0/reference.xtp#tempdir One more question: Can I set this in app-default.xml web-app-default with some suitable ${appname} EL variable? work-dir${resin.root}/resin-data/work/${appname}//work-dir temp-dir${resin.root}/resin-data/tmp/${appname}//temp-dir -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Unsupported operation error
I'm trying to add Spring Security to my pure-JavaConfig web app, and I'm getting this error on my first request. Any idea what it means? Is this a Resin problem (v 4.0.36)? [14-03-20 02:48:37.355] FINE com.caucho.server.http.HttpRequest handleRequest: java.lang.UnsupportedOperationException: unimplemented at com.caucho.server.webapp.ServletContextImpl.setSessionTrackingModes(ServletContextImpl.java:552) at org.springframework.security.web.context.AbstractSecurityWebApplicationInitializer.onStartup(AbstractSecurityWebApplicationInitializer.java:120) at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174) at com.caucho.server.webapp.WebApp.callInitializer(WebApp.java:3471) -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Unsupported operation error
THANKS!! If this is the kind of news that comes out of you being stupid, then please be stupid more often ;-) On Mar 20, 2014, at 12:47 , Paul Cowan co...@caucho.com wrote: Oh I feel stupid now - my Resin 4 codebase was out of date (been working on Resin 5). There already was a bug and we just added session tracking mode support in version 4.0.38. So you’ll just need to upgrade your Resin version to get it. -Paul On Mar 20, 2014, at 3:11 PM, Rick Mann rm...@latencyzero.com wrote: Please enter the bug, at least. I'll look into seeing if there's a way around the problem. On Mar 20, 2014, at 11:29 , Paul Cowan co...@caucho.com wrote: On Mar 20, 2014, at 6:00 AM, Rick Mann rm...@latencyzero.com wrote: I'm trying to add Spring Security to my pure-JavaConfig web app, and I'm getting this error on my first request. Any idea what it means? Is this a Resin problem (v 4.0.36)? That’s definitely being thrown by Resin. I looked at our code and we don’t implement the Servlet 3.0 session tracking modes API and throw the UnsupportedOperationException on call. I’m not sure why; it must have been an optional part of the spec or TCK. I can enter a bug report to implement it but I’m afraid you may be out of luck on Resin 4.0.36 if Spring depends on that call. Thanks, Paul [14-03-20 02:48:37.355] FINE com.caucho.server.http.HttpRequest handleRequest: java.lang.UnsupportedOperationException: unimplemented at com.caucho.server.webapp.ServletContextImpl.setSessionTrackingModes(ServletContextImpl.java:552) at org.springframework.security.web.context.AbstractSecurityWebApplicationInitializer.onStartup(AbstractSecurityWebApplicationInitializer.java:120) at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174) at com.caucho.server.webapp.WebApp.callInitializer(WebApp.java:3471) -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Problem building 4.0.38
Dunno if I did something wrong. Mavericks 10.9.2, Xcode 5.1 http://pastebin.com/r5QgX5vS -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Problem building 4.0.38
On Mar 20, 2014, at 13:44 , Paul Cowan co...@caucho.com wrote: On Mar 20, 2014, at 4:39 PM, Rick Mann rm...@latencyzero.com wrote: Oops, it was 'cause I tried to build in a subdirectory. NOT doing that seems to work, but gets me a TON of deprecation warnings in SSL (first deprecated in OS X 10.7). Yep, Apple has deprecated OpenSSL! http://stackoverflow.com/questions/7406946/why-is-apple-deprecating-openssl-in-macos-10-7-lion It should still build, but yes there’s lots of warnings now, we get them too. Interesting. I went through their slides (will watch the video later). I wonder how they plan to support so many open source projects that rely on it. http://pastebin.com/haPFZPtc On Mar 20, 2014, at 13:35 , Rick Mann rm...@latencyzero.com wrote: Dunno if I did something wrong. Mavericks 10.9.2, Xcode 5.1 http://pastebin.com/r5QgX5vS -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Unsupported operation error
4.0.38 *seems* to be working. It's always a bit clunky to update to a new version of Resin, getting all the config back to what I had gotten to with the previous version (in this case, I just copied all my config from .36). Now my webapp jumps to an ugly login page, which I think is the Spring Security doing its job. At the very least, I don't get the unimplemented exception. Thanks! On Mar 20, 2014, at 12:47 , Paul Cowan co...@caucho.com wrote: Oh I feel stupid now - my Resin 4 codebase was out of date (been working on Resin 5). There already was a bug and we just added session tracking mode support in version 4.0.38. So you’ll just need to upgrade your Resin version to get it. -Paul On Mar 20, 2014, at 3:11 PM, Rick Mann rm...@latencyzero.com wrote: Please enter the bug, at least. I'll look into seeing if there's a way around the problem. On Mar 20, 2014, at 11:29 , Paul Cowan co...@caucho.com wrote: On Mar 20, 2014, at 6:00 AM, Rick Mann rm...@latencyzero.com wrote: I'm trying to add Spring Security to my pure-JavaConfig web app, and I'm getting this error on my first request. Any idea what it means? Is this a Resin problem (v 4.0.36)? That’s definitely being thrown by Resin. I looked at our code and we don’t implement the Servlet 3.0 session tracking modes API and throw the UnsupportedOperationException on call. I’m not sure why; it must have been an optional part of the spec or TCK. I can enter a bug report to implement it but I’m afraid you may be out of luck on Resin 4.0.36 if Spring depends on that call. Thanks, Paul [14-03-20 02:48:37.355] FINE com.caucho.server.http.HttpRequest handleRequest: java.lang.UnsupportedOperationException: unimplemented at com.caucho.server.webapp.ServletContextImpl.setSessionTrackingModes(ServletContextImpl.java:552) at org.springframework.security.web.context.AbstractSecurityWebApplicationInitializer.onStartup(AbstractSecurityWebApplicationInitializer.java:120) at org.springframework.web.SpringServletContainerInitializer.onStartup(SpringServletContainerInitializer.java:174) at com.caucho.server.webapp.WebApp.callInitializer(WebApp.java:3471) -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Any way to tell resin to put WEB-INF/tmp somewhere else?
Awesome! On Mar 12, 2014, at 19:57 , Alex Rojkov a...@caucho.com wrote: On Mar 12, 2014, at 7:51 PM, Rick Mann rm...@latencyzero.com wrote: It would be nice for it to create its work directories somewhere else, not inside my webapp distros. Is this possible? Should be possible with work-dir and temp-dir tags. http://www.caucho.com/resin-4.0/reference.xtp#workdir http://www.caucho.com/resin-4.0/reference.xtp#tempdir Alex -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
On Mar 12, 2014, at 20:23 , Alex Rojkov a...@caucho.com wrote: Did you remove resin:import for app-default.xml by any chance ? Why do you ask? signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
On Mar 13, 2014, at 14:13 , Alex Rojkov a...@caucho.com wrote: Are your servlets in WB-INF/classes? Yes. Try adding a compiling-loader (or a simple-loader if classes are compiled already) to your class-loader. class-loader compiling-loader path=WEB-INF/classes”/ tree-loader../ /class-loader I had that in there originally, but it wasn't working. I removed it because I never want .java files in classes/ to be compiled (that's what it's for, right?). Just to be sure, I added it and tried again. No go. -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
On Mar 13, 2014, at 14:56 , Alex Rojkov a...@caucho.com wrote: And can you move the class-loader registration inside the web-app please? If that doesn’t work please post log and conf/*.xml conf/*.properties someplace. It's inside the web-app inside resin.xml. resin.xml: http://pastebin.com/tY8MRf3S app-defaults.xml: http://pastebin.com/iF8F6Ug9 cluster-default.xml:http://pastebin.com/n84jPp1S properties: http://pastebin.com/sMBTiNfi It's probably something really stupid that I did, and I'll be suitably embarrassed when you point it out. Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
Hmm. I don't have the connector jar outside my webapps in any other environment. I can't remember what it is I did to fix it last time. On Mar 13, 2014, at 15:37 , Rick Mann rm...@latencyzero.com wrote: Oh! Sorry. That was it. Argh. I am embarrassed (and annoyed with myself, since I've lost precious development time). Thank you. Now I'm back to an issue I had earlier (which I realize now I was solving when I created this problem), and that is that Resin can't find the MySQL driver in WEB-INF/lib when it goes to create the DataSource. This is a problem that has plagued me for years, and each time I eventually get things to work, but each new environment seem to trip me up. It seems to me that if the tree-loader points to lib, and the MySQL connector jar is in there, Resin should be able to find it. Is it trying to create this datasource before the tree-loader can load classes? I guess that also makes sense, since this configuration is outside of my webapp, and therefore not controlled by it. Is that the right understanding? By that understanding, I should be able to instantiate the datasource inside my webapp instead, using the jar inside the webapp, no? Thanks again for spotting my error! On Mar 13, 2014, at 15:31 , Alex Rojkov a...@caucho.com wrote: Hm… In the referenced resin.xml the classloader is in the host section. Can you move it into the web-app section and try accessing one of your mapped servlets? Alex And can you move the class-loader registration inside the web-app please? If that doesn’t work please post log and conf/*.xml conf/*.properties someplace. It's inside the web-app inside resin.xml. resin.xml: http://pastebin.com/tY8MRf3S app-defaults.xml: http://pastebin.com/iF8F6Ug9 cluster-default.xml:http://pastebin.com/n84jPp1S properties: http://pastebin.com/sMBTiNfi It's probably something really stupid that I did, and I'll be suitably embarrassed when you point it out. Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
And, stopping and re-starting resin again solved that problem. On Mar 13, 2014, at 15:43 , Rick Mann rm...@latencyzero.com wrote: Hmm. I don't have the connector jar outside my webapps in any other environment. I can't remember what it is I did to fix it last time. On Mar 13, 2014, at 15:37 , Rick Mann rm...@latencyzero.com wrote: Oh! Sorry. That was it. Argh. I am embarrassed (and annoyed with myself, since I've lost precious development time). Thank you. Now I'm back to an issue I had earlier (which I realize now I was solving when I created this problem), and that is that Resin can't find the MySQL driver in WEB-INF/lib when it goes to create the DataSource. This is a problem that has plagued me for years, and each time I eventually get things to work, but each new environment seem to trip me up. It seems to me that if the tree-loader points to lib, and the MySQL connector jar is in there, Resin should be able to find it. Is it trying to create this datasource before the tree-loader can load classes? I guess that also makes sense, since this configuration is outside of my webapp, and therefore not controlled by it. Is that the right understanding? By that understanding, I should be able to instantiate the datasource inside my webapp instead, using the jar inside the webapp, no? Thanks again for spotting my error! On Mar 13, 2014, at 15:31 , Alex Rojkov a...@caucho.com wrote: Hm… In the referenced resin.xml the classloader is in the host section. Can you move it into the web-app section and try accessing one of your mapped servlets? Alex And can you move the class-loader registration inside the web-app please? If that doesn’t work please post log and conf/*.xml conf/*.properties someplace. It's inside the web-app inside resin.xml. resin.xml: http://pastebin.com/tY8MRf3S app-defaults.xml: http://pastebin.com/iF8F6Ug9 cluster-default.xml:http://pastebin.com/n84jPp1S properties: http://pastebin.com/sMBTiNfi It's probably something really stupid that I did, and I'll be suitably embarrassed when you point it out. Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Any way to tell resin to put WEB-INF/tmp somewhere else?
It would be nice for it to create its work directories somewhere else, not inside my webapp distros. Is this possible? -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Fresh resin install won't run my app or log
Well, that's not exactly true, but I'm baffled. I have my webapp running just fine locally, and just find on a 4.0.37/Java 1.6/Ubuntu 10.10 server I've had running for years. I just created an Ubuntu 13.10/Java 1.7/4.0.38 server using the Pro distribution (but no license file yet) that I build myself (rather than using apt-get) because I wanted to control the directories used. It started up and ran fine. I then installed my app, and modified resin.xml to point to it. Resin seems to create the app, and the resin-file handler is able to serve up some top-level files in my app. But it does not appear to be actually executing any of the code in my app. My app is pure-java configed, and uses Log4J. No log files are getting created. I tried logging some stuff using System.out, but it's not appearing in any of the logs I do get. I'm executing with resinctl console, as much logging as I can set to ALL. I've little by little gone through the various Resin config files removing references to other apps, virtual hosts, and other logging. My app's entry in resin.xml looks like this: http://pastebin.com/6STAmNBS Any ideas what else to try? I have the following logs to look at: rmann@clarke $ ls /logs/resin/ out.log rmann@clarke $ ls /logs/inote/ access.log resin.log Plus what comes out of the resinctl console. I'm baffled. Some possible issues? [03-13 03:01:20.176] {main} ALL (com.caucho.env.deploy.ExpandDeployController) java.io.FileNotFoundException: /lz/var/www/com/latencyzero/inote/META-INF/resin.application-hash GETting / results in 404: [03-13 03:11:38.506] {resin-port-80-46} FINER (com.caucho.server.dispatch.ServletInvocation) Dispatch '/' to AccessLogFilterChain[http://inote.latencyzero.com, next=WebAppFilterChain[http://inote.latencyzero.com, next=ServletFilterChain[resin-file]]] GETting /css/site.css returns the css file: [03-13 03:01:36.023] {resin-port-80-22} FINER (com.caucho.server.dispatch.ServletInvocation) Dispatch '/css/site.css' to AccessLogFilterChain[http://inote.latencyzero.com, next=WebAppFilterChain[http://inote.latencyzero.com, next=ServletFilterChain[resin-file]]] TIA, -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Fresh resin install won't run my app or log
No, but I adjusted that file, too, for logging. Sent from my iPhone On Mar 12, 2014, at 20:23, Alex Rojkov a...@caucho.com wrote: Did you remove resin:import for app-default.xml by any chance ? Alex On Mar 12, 2014, at 8:12 PM, Rick Mann rm...@latencyzero.com wrote: Well, that's not exactly true, but I'm baffled. I have my webapp running just fine locally, and just find on a 4.0.37/Java 1.6/Ubuntu 10.10 server I've had running for years. I just created an Ubuntu 13.10/Java 1.7/4.0.38 server using the Pro distribution (but no license file yet) that I build myself (rather than using apt-get) because I wanted to control the directories used. It started up and ran fine. I then installed my app, and modified resin.xml to point to it. Resin seems to create the app, and the resin-file handler is able to serve up some top-level files in my app. But it does not appear to be actually executing any of the code in my app. My app is pure-java configed, and uses Log4J. No log files are getting created. I tried logging some stuff using System.out, but it's not appearing in any of the logs I do get. I'm executing with resinctl console, as much logging as I can set to ALL. I've little by little gone through the various Resin config files removing references to other apps, virtual hosts, and other logging. My app's entry in resin.xml looks like this: http://pastebin.com/6STAmNBS Any ideas what else to try? I have the following logs to look at: rmann@clarke $ ls /logs/resin/ out.log rmann@clarke $ ls /logs/inote/ access.log resin.log Plus what comes out of the resinctl console. I'm baffled. Some possible issues? [03-13 03:01:20.176] {main} ALL (com.caucho.env.deploy.ExpandDeployController) java.io.FileNotFoundException: /lz/var/www/com/latencyzero/inote/META-INF/resin.application-hash GETting / results in 404: [03-13 03:11:38.506] {resin-port-80-46} FINER (com.caucho.server.dispatch.ServletInvocation) Dispatch '/' to AccessLogFilterChain[http://inote.latencyzero.com, next=WebAppFilterChain[http://inote.latencyzero.com, next=ServletFilterChain[resin-file]]] GETting /css/site.css returns the css file: [03-13 03:01:36.023] {resin-port-80-22} FINER (com.caucho.server.dispatch.ServletInvocation) Dispatch '/css/site.css' to AccessLogFilterChain[http://inote.latencyzero.com, next=WebAppFilterChain[http://inote.latencyzero.com, next=ServletFilterChain[resin-file]]] TIA, -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] EL 2.2?
I'm trying to access a bean in request scope (in a JSP page) that takes a parameter. The method is getFieldError(String field); I'm trying to write EL like this: span${br.fieldError(email)}/span But it renders nothing. Note that the void parameter list version of the method works correctly (if I call it without an argument list). As I understand it, EL 2.2 should work this way. Do I need to do something to ensure the JSP page is executing EL 2.2? Does it need to be enabled in some way? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Any way to set jsp page-encoding with Servlet 3.0 Java-only configuration?
I apologize, since this isn't strictly a Resin issue, but: I used to have this in my web.xml: jsp-config jsp-property-group url-pattern*.jsp/url-pattern page-encodingUTF-8/page-encoding /jsp-property-group /jsp-config How do I duplicate that effect in Servlet 3.0/Spring Java-only configuration? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Any way to set jsp page-encoding with Servlet 3.0 Java-only configuration?
Yeah, I've got this as the first line in my resin.xml: character-encodingUTF-8/character-encoding But it is insufficient. On Mar 11, 2014, at 16:45 , Alex Rojkov a...@caucho.com wrote: In Resin you should be able to specify that with character-encoding tag at web-app | host | cluster | resin level. http://www.caucho.com/resin-4.0/reference.xtp#characterencoding Thanks, Alex I apologize, since this isn't strictly a Resin issue, but: I used to have this in my web.xml: jsp-config jsp-property-group url-pattern*.jsp/url-pattern page-encodingUTF-8/page-encoding /jsp-property-group /jsp-config How do I duplicate that effect in Servlet 3.0/Spring Java-only configuration? Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] EL 2.2?
Hmm, I tried again, and it does indeed seem to work. On Mar 11, 2014, at 18:56 , Rick Mann rm...@latencyzero.com wrote: I'm trying to access a bean in request scope (in a JSP page) that takes a parameter. The method is getFieldError(String field); I'm trying to write EL like this: span${br.fieldError(email)}/span But it renders nothing. Note that the void parameter list version of the method works correctly (if I call it without an argument list). As I understand it, EL 2.2 should work this way. Do I need to do something to ensure the JSP page is executing EL 2.2? Does it need to be enabled in some way? Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Registering my CanDI producer with InjectionManager?
I'm trying to create a factory to let me @Inject Loggers as shown here: http://docs.jboss.org/cdi/api/1.0/javax/enterprise/inject/spi/InjectionPoint.html But I get: [14-03-08 23:59:23.129] WARNING com.caucho.server.webapp.WebApp setConfigException: javax.enterprise.inject.UnsatisfiedResolutionException: Can't find a bean for 'class org.apache.log4j.Logger' because no beans implementing that class have been registered with the injection manager InjectManager[singleton:null#UsageMapServer]. at com.caucho.config.inject.InjectManager.unsatisfiedException(InjectManager.java:2471) at com.caucho.config.inject.InjectManager.resolveByInjectionPoint(InjectManager.java:2656) at com.caucho.config.inject.InjectManager.getReferenceFactory(InjectManager.java:2614) at com.caucho.config.inject.InjectManager.getReferenceFactory(InjectManager.java:2593) Here's my code (first class needs the injection, second class is the factory): http://pastebin.com/nHiGZyzf One additional question: when this works, how many LoggerFactory instances can I expect? Is it a singleton? Can I use its constructor or static init to initialize Log4J? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] already a root application context present
Any word on this in 4.0.38? On Jul 9, 2013, at 13:18 , Scott Ferguson f...@caucho.com wrote: On 7/8/13 12:38 PM, Rick Mann wrote: On Jul 8, 2013, at 09:43 , Scott Ferguson f...@caucho.com wrote: On 7/6/13 4:54 PM, Rick Mann wrote: I'm still getting this error with resin-4.0-36. It seems benign, in that the app continues to run, but I'd like to know what I'm doing wrong. I've added a bug report. I'll see if there's some double scanning or double initializing. It's behaving as if there were two spring jars in the WEB-INF/lib. (I'm sure there's not, but the behavior seems to be the same as if that was happening.) It's entirely possible I did something wrong. I don't have a web.xml any more, but I might have some annotation wrong. I still don't fully understand how that's all supposed to work. Here's every *spring* file in my WEB-INF/lib dir: Thanks. Unless you had two copies of the jars, I don't think it would be a problem on your end. -- Scott ./WEB-INF/lib/org/springframework/security/spring-security-core/3.1.3.RELEASE/spring-security-core-3.1.3.RELEASE.jar ./WEB-INF/lib/org/springframework/spring-aop/3.2.0.RC2/spring-aop-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-beans/3.2.0.RC2/spring-beans-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-context/3.2.0.RC2/spring-context-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-core/3.2.0.RC2/spring-core-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-expression/3.2.0.RC2/spring-expression-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-jdbc/3.2.0.RC2/spring-jdbc-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-orm/3.2.0.RC2/spring-orm-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-test/3.2.0.RC2/spring-test-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-tx/3.2.0.RC2/spring-tx-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-web/3.2.0.RC2/spring-web-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-webmvc/3.2.0.RC2/spring-webmvc-3.2.0.RC2.jar The Resin installation is fresh; no extra libs in there. -- Scott [13-07-06 16:52:02.422] INFO com.caucho.server.webapp.WebApp log: WebApp[production/webapp/default/ROOT,STARTING] Spring WebApplicationInitializers detected on classpath: [com.latencyzero.gamecenter.web.WebappInitializer@7c739ebd] [13-07-06 16:52:02.456] INFO com.caucho.server.webapp.WebApp log: WebApp[production/webapp/default/ROOT,STARTING] Initializing Spring root WebApplicationContext [13-07-06 16:52:03.931] WARNING com.caucho.server.webapp.WebApp startImpl: java.lang.IllegalStateException: Cannot initialize context because there is already a root application context present - check whether you have multiple ContextLoader* definitions in your web.xml! at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:264) at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112) at com.caucho.server.webapp.WebApp.startImpl(WebApp.java:3677) at com.caucho.server.webapp.WebApp$StartupTask.run(WebApp.java:5196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] @WebServlet and Hessian
Well, I added @WebServlet to my Hessian servlet implementation, and making a GET request results in the expected Hessian Requires POST response. But when my client accesses it properly, the response is empty, and there's no evidence that my actual implementation is being called. Is it possible to use @WebServlet on something that inherits from HttpServlet? -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Best way to start background task?
Developments in Java EE never cease to leave me behind, given that my day job is iOS development, and I poke at my server dev more as a hobby than anything else. I'm a moderately experienced using Spring, Hibernate and Resin. CanDI is new to me, but I'd like to understand it better. I think it standardizes a lot of functionality that Spring provides, is that a fair assessment? My current need is to run a lengthy process (10 seconds) independent of the web request that triggers it. Right now, a client makes a request of my webapp, it updates some internal state, then starts this 10-second synchronous process. The result of the process is not needed by the client, so I'd like to conduct it in the background. I know JMS is one way to do this. But currently, my entire webapp runs in a single Resin instance, and I don't think I need to set up all the JMS stuff. What's the most modern way to do what I'd like to do? Ideally, if one of these background tasks is already in flight, any more that come in will be coalesced into a single additional task, so a little coordination would be good (i.e., they shouldn't be completely independent instances of the task). Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Wiki page broken
Looks like a lot of tags are confused on this page: http://wiki4.caucho.com/Resin_4_CDI_Dependency_Injection_Binding_Examples Also, it seems the bugs.caucho.com forgot who I am... -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Wiki page broken
On Mar 8, 2014, at 22:57 , Rick Mann rm...@latencyzero.com wrote: Also, it seems the bugs.caucho.com forgot who I am... Nevermind, it was I who forgot who I am. Is Mantis still in use? I see very few bug reports. Maybe they're mostly private? -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] CanDI, @Startup, and Log4J
I have a Servlet 2-style webapp. web.xml causes an InitServlet to be instantiated at startup, and one of its tasks is to initialize Log4J using JNDI to find the name of the log4j.xml file. The @startup singleton I just got working gets instantiated before this happens, and so in its @PostConstruct method, Log4J isn't working yet. I realize I can create a singleton to initialize Log4J, and then set up a dependency on it from other classes, but that seems tedious and a bit redundant, since each class already has a static Logger member. What's the right way to handle this dependency? TIA, -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] WebSockets Chatroom example
I'm trying to do the WebSockets example here: http://wiki4.caucho.com/WebSocket_API_Chat_Room_using_JSR_356 But it needs javax.ejb.Startup (among other things). My ant build script fails on this, because I don't seem to be including the right JAR. I tried to use the maven ant plugin (which is how I get all my dependencies), but there's no jar here: http://mirrors.ibiblio.org/maven2/javax/ejb/ejb/ It suggests I get it from Oracle and manually install it. But I don't see how to get the right jar. I downloaded the massive Java EE 7 dev kit, but I'm not confident it's going to have what I need, nor do I know what version of EJB it will be. Any suggestions? How do I get set up to properly build apps like these? Thanks, -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] WebSockets Chatroom example
On Mar 6, 2014, at 09:47 , Paul Cowan co...@caucho.com wrote: For EJB you want: http://mirrors.ibiblio.org/maven2/javax/ejb/ejb-api/3.0/ Hmm, I still get [javac] /Users/rmann/.../UsageMapServer.java:9: error: cannot find symbol [javac] import javax.ejb.Startup; -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] WebSockets Chatroom example
Awesome, thanks! On Mar 6, 2014, at 09:47 , Paul Cowan co...@caucho.com wrote: On Mar 6, 2014, at 3:37 AM, Rick Mann rm...@latencyzero.com wrote: I'm trying to do the WebSockets example here: http://wiki4.caucho.com/WebSocket_API_Chat_Room_using_JSR_356 But it needs javax.ejb.Startup (among other things). My ant build script fails on this, because I don't seem to be including the right JAR. I tried to use the maven ant plugin (which is how I get all my dependencies), but there's no jar here: http://mirrors.ibiblio.org/maven2/javax/ejb/ejb/ It suggests I get it from Oracle and manually install it. But I don't see how to get the right jar. I downloaded the massive Java EE 7 dev kit, but I'm not confident it's going to have what I need, nor do I know what version of EJB it will be. For EJB you want: http://mirrors.ibiblio.org/maven2/javax/ejb/ejb-api/3.0/ You just need the APIs to code against, Resin will provide the implementation when run. I've actually been meaning to write a Wiki page for questions related to JEE Maven dependencies, so I just did so. Please see: http://wiki4.caucho.com/Resin_4_Maven_Dependencies -Paul Any suggestions? How do I get set up to properly build apps like these? Thanks, -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest === Paul Cowan, Software Engineer Caucho Technology co...@caucho.com http://blog.caucho.com http://twitter.com/cauchoresin ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Character encoding in root vs included JSP
I thought I had UTF-8 set throughout my app; source files are encoded in it, I set it everywhere I can think of (requests, responses, JVM, HTML and JSP tags). I we re-doing the HTML for my site, fancifying it with bootstrap and all that goodness, when I noticed that the copyright symbol I typed wasn't rendering correctly. It used to with the old HTML, so I investigated. Turns out, it only renders correctly if I jsp:include the HTML snippet that contains the symbol. If it's typed directly into the page, it doesn't work. Any ideas? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Character encoding in root vs included JSP
Hmm. Seems like if I %@ include a file that contains %@ page contentType=text/html; charset=UTF-8% Then it doesn't work. If I include that @ page line directly, it gets the encoding right. On Feb 28, 2014, at 04:45 , Rick Mann rm...@latencyzero.com wrote: I thought I had UTF-8 set throughout my app; source files are encoded in it, I set it everywhere I can think of (requests, responses, JVM, HTML and JSP tags). I we re-doing the HTML for my site, fancifying it with bootstrap and all that goodness, when I noticed that the copyright symbol I typed wasn't rendering correctly. It used to with the old HTML, so I investigated. Turns out, it only renders correctly if I jsp:include the HTML snippet that contains the symbol. If it's typed directly into the page, it doesn't work. Any ideas? Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Character encoding in root vs included JSP
On Feb 28, 2014, at 08:55 , Scott Ferguson f...@caucho.com wrote: On 2/28/14, 4:47 AM, Rick Mann wrote: Hmm. Seems like if I %@ include a file that contains %@ page contentType=text/html; charset=UTF-8% Then it doesn't work. If I include that @ page line directly, it gets the encoding right. I believe that's correct, though. The top page is responsible for deciding encoding. I found I need to include it in both the top page, AND the page that gets included. Wish there were a way to just set it once for the whole container. -- Scott On Feb 28, 2014, at 04:45 , Rick Mann rm...@latencyzero.com wrote: I thought I had UTF-8 set throughout my app; source files are encoded in it, I set it everywhere I can think of (requests, responses, JVM, HTML and JSP tags). I we re-doing the HTML for my site, fancifying it with bootstrap and all that goodness, when I noticed that the copyright symbol I typed wasn't rendering correctly. It used to with the old HTML, so I investigated. Turns out, it only renders correctly if I jsp:include the HTML snippet that contains the symbol. If it's typed directly into the page, it doesn't work. Any ideas? Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Character encoding in root vs included JSP
Thank you. Adding this: jsp-config jsp-property-group url-pattern*.jsp/url-pattern page-encodingUTF-8/page-encoding /jsp-property-group /jsp-config To the bottom of my web.xml seems to have done the trick. Initially, I had the url-pattern /*, but that broke the mapping of / (which was supposed to be handled by Spring WebMVC; I find it very fragile, the routing of a request through a servlet container). On Feb 28, 2014, at 12:21 , Knut Forkalsrud knut-cau...@forkalsrud.org wrote: Traditionally the JSP spec has mandated ISO-8859-1 if nothing else is explicitly specified. However I notice recent versions have a facility to specify it more broadly in web.xml Case in point is section JSP.3.3.4 in version 2.2 of the spec: http://download.oracle.com/otn-pub/jcp/jsp-2.2-mrel-eval-oth-JSpec/jsp-2_2-mrel-spec.pdf The syntax would look something like jsp-property-group url-pattern/*/url-pattern page-encodingUTF-8/page-encoding /jsp-property-group I haven't used JSPs in years, and have no idea of whether Resin supports this. Knut Forkalsrud On Fri, Feb 28, 2014 at 11:41 AM, Rick Mann rm...@latencyzero.com wrote: On Feb 28, 2014, at 08:55 , Scott Ferguson f...@caucho.com wrote: On 2/28/14, 4:47 AM, Rick Mann wrote: Hmm. Seems like if I %@ include a file that contains %@ page contentType=text/html; charset=UTF-8% Then it doesn't work. If I include that @ page line directly, it gets the encoding right. I believe that's correct, though. The top page is responsible for deciding encoding. I found I need to include it in both the top page, AND the page that gets included. Wish there were a way to just set it once for the whole container. -- Scott On Feb 28, 2014, at 04:45 , Rick Mann rm...@latencyzero.com wrote: I thought I had UTF-8 set throughout my app; source files are encoded in it, I set it everywhere I can think of (requests, responses, JVM, HTML and JSP tags). I we re-doing the HTML for my site, fancifying it with bootstrap and all that goodness, when I noticed that the copyright symbol I typed wasn't rendering correctly. It used to with the old HTML, so I investigated. Turns out, it only renders correctly if I jsp:include the HTML snippet that contains the symbol. If it's typed directly into the page, it doesn't work. Any ideas? Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Rewriting hostnames across webapps?
On Jan 17, 2014, at 06:05 , Paul Cowan co...@caucho.com wrote: On Jan 16, 2014, at 4:32 PM, Rick Mann rm...@latencyzero.com wrote: I'm trying to update a virtual server that runs a handful of webapps in Resin. The old machine was tycho.latencyzero.com and a bunch of DNS entries point to it. The web apps are configured to respond to those varying hostnames. The new machine temporarily has the name stage.latencyzero.com. I copied everything from the old machine to the new, including the resin config file. Obviously, I can't just go to stage.latencyzero.com, because resin has no idea which webapp I really want. Is there any way to configure resin to rewrite a request with a host like foo.bar.latencyzero.com.stage.latencyzero.com into a request for the webapp that responds to foo.bar.latencyzero.com, while keeping the actual hostname intact for the purposes of rendering links in the pages, etc.? Hi Rick, I'm not exactly understanding what you want to do, but it sounds like I a similar situation I had on one of my sites. This configuration below is what I used. The new real host is listed first in resin.xml, then the default host id= with host-alias * will catch all, and the redirect regex will redirect to the new site while appending the requested URI. host id=foo root-directory=hosts/foo host-alias-regexp.*foo.com/host-alias-regexp … /host host id= root-directory=hosts/default host-alias*/host-alias web-app id=/ root-directory=webapps/ROOT resin:Redirect regexp=(.*) target=http://www.foo.com$1/ resin:Redirect regexp=(.*) target=https://www.foo.com$1; resin:IfSecure value=true/ /resin:Redirect /web-app /host Hope this helps, Hmm, not sure. Basically, I have entries in resin.xml on machine tycho.latencyzero.com like this: host host-name=latencyzero.com root-directory=/lz/var/www/com/latencyzero host-alias-regexp^tycho.latencyzero.com[\.]?$/host-alias-regexp host-alias-regexp^(www\.)?latencyzero.com[\.]?$/host-alias-regexp web-app id=/ document-directory=www/webapp /host host id=comics\.roderickmann\.org\.? root-directory=/lz/var/www/org/roderickmann/comics host-namecomics.roderickmann.org/host-name web-app id=/ document-directory=./webapp /host host host-name=www.roderickmann.org root-directory=/lz/var/www/org/roderickmann/www host-alias-regexp^(www\.)?roderickmann.org[\.]?$/host-alias-regexp host-alias-regexp^(www\.)?rickmann.org[\.]?$/host-alias-regexp web-app id=/ document-directory=./webapp /host host host-name=mgfb.roderickmann.org root-directory=/lz/var/www/org/roderickmann/mgfb host-alias-regexp^mgfb\.roderickmann.org[\.]?$/host-alias-regexp host-alias-regexp^blog\.roderickmann.org[\.]?$/host-alias-regexp web-app id=/ document-directory=./webapp /host I have DNS entries for all of the above that are all CNAMEs to tycho.latencyzero.com. I want to move all of those apps to a new machine (upgrading hardware and OS), but I want to test it first. The machine is called stage.latencyzero.com, and I need to make new DNS entries for each webapp (perhaps adding stage to each name, or something). The most straightforward thing would be simply to modify each name to add stage to them, but then when I decide to make the new machine permanent, and change all the old DNS entries to point to the new IP address, I'd have to modify the entries. Or I could simply add host-aliases for all the new names. But I was hoping there'd be a trick so that I only have to modify one line, and each of the host entries would pick it up. I realize that might require me to modify all the entries once (as you did with your redirects). But once I do this once, it should work for similar changes in the future. One thing I need to preserve: if I'm hitting one of my webapps through the new name (e.g. stage.mgfb.roderickmann.org or whatever), when code in the webapp uses the host name to render URIs, it needs to use that same hostname, so that links point to the right place, and not back to the old instance. All this discussion, of course, has taken longer than it would have to simply modify the entries a couple times, but I was curious. Thanks, Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Rewriting hostnames across webapps?
Yep, I think it would. The problem is, what if I want a more complex transformation next time? Or just a different string other than stage inserted? It's okay, this works well enough for me now. On Jan 17, 2014, at 15:24 , Chris Pratt thechrispr...@gmail.com wrote: Wouldn't adding (stage\.)? to each host-alias-regexp and changing the host-name to regexp allow it to work as you want it? For example: host regexp=(stage\.)?latencyzero.com root-directory=/lz/var/www/com/latencyzero host-alias-regexp^tycho.(stage\.)?latencyzero.com[\.]?$/host-alias-regexp host-alias-regexp^(www\.)?(stage\.)?latencyzero.com[\.]?$/host-alias-regexp web-app id=/ document-directory=www/webapp /host On Fri, Jan 17, 2014 at 3:18 PM, Rick Mann rm...@latencyzero.com wrote: On Jan 17, 2014, at 06:05 , Paul Cowan co...@caucho.com wrote: On Jan 16, 2014, at 4:32 PM, Rick Mann rm...@latencyzero.com wrote: I'm trying to update a virtual server that runs a handful of webapps in Resin. The old machine was tycho.latencyzero.com and a bunch of DNS entries point to it. The web apps are configured to respond to those varying hostnames. The new machine temporarily has the name stage.latencyzero.com. I copied everything from the old machine to the new, including the resin config file. Obviously, I can't just go to stage.latencyzero.com, because resin has no idea which webapp I really want. Is there any way to configure resin to rewrite a request with a host like foo.bar.latencyzero.com.stage.latencyzero.com into a request for the webapp that responds to foo.bar.latencyzero.com, while keeping the actual hostname intact for the purposes of rendering links in the pages, etc.? Hi Rick, I'm not exactly understanding what you want to do, but it sounds like I a similar situation I had on one of my sites. This configuration below is what I used. The new real host is listed first in resin.xml, then the default host id= with host-alias * will catch all, and the redirect regex will redirect to the new site while appending the requested URI. host id=foo root-directory=hosts/foo host-alias-regexp.*foo.com/host-alias-regexp … /host host id= root-directory=hosts/default host-alias*/host-alias web-app id=/ root-directory=webapps/ROOT resin:Redirect regexp=(.*) target=http://www.foo.com$1/ resin:Redirect regexp=(.*) target=https://www.foo.com$1; resin:IfSecure value=true/ /resin:Redirect /web-app /host Hope this helps, Hmm, not sure. Basically, I have entries in resin.xml on machine tycho.latencyzero.com like this: host host-name=latencyzero.com root-directory=/lz/var/www/com/latencyzero host-alias-regexp^tycho.latencyzero.com[\.]?$/host-alias-regexp host-alias-regexp^(www\.)?latencyzero.com[\.]?$/host-alias-regexp web-app id=/ document-directory=www/webapp /host host id=comics\.roderickmann\.org\.? root-directory=/lz/var/www/org/roderickmann/comics host-namecomics.roderickmann.org/host-name web-app id=/ document-directory=./webapp /host host host-name=www.roderickmann.org root-directory=/lz/var/www/org/roderickmann/www host-alias-regexp^(www\.)?roderickmann.org[\.]?$/host-alias-regexp host-alias-regexp^(www\.)?rickmann.org[\.]?$/host-alias-regexp web-app id=/ document-directory=./webapp /host host host-name=mgfb.roderickmann.org root-directory=/lz/var/www/org/roderickmann/mgfb host-alias-regexp^mgfb\.roderickmann.org[\.]?$/host-alias-regexp host-alias-regexp^blog\.roderickmann.org[\.]?$/host-alias-regexp web-app id=/ document-directory=./webapp /host I have DNS entries for all of the above that are all CNAMEs to tycho.latencyzero.com. I want to move all of those apps to a new machine (upgrading hardware and OS), but I want to test it first. The machine is called stage.latencyzero.com, and I need to make new DNS entries for each webapp (perhaps adding stage to each name, or something). The most straightforward thing would be simply to modify each name to add stage to them, but then when I decide to make the new machine permanent, and change all the old DNS entries to point to the new IP address, I'd have to modify the entries. Or I could simply add host-aliases for all the new names. But I was hoping there'd be a trick so that I only have to modify one line, and each of the host entries would pick it up. I realize that might require me to modify all the entries once (as you did with your redirects). But once I do this once, it should work for similar changes in the future. One thing I need to preserve: if I'm hitting one of my webapps through the new name (e.g. stage.mgfb.roderickmann.org or whatever), when code in the webapp
[Resin-interest] Rewriting hostnames across webapps?
I'm trying to update a virtual server that runs a handful of webapps in Resin. The old machine was tycho.latencyzero.com and a bunch of DNS entries point to it. The web apps are configured to respond to those varying hostnames. The new machine temporarily has the name stage.latencyzero.com. I copied everything from the old machine to the new, including the resin config file. Obviously, I can't just go to stage.latencyzero.com, because resin has no idea which webapp I really want. Is there any way to configure resin to rewrite a request with a host like foo.bar.latencyzero.com.stage.latencyzero.com into a request for the webapp that responds to foo.bar.latencyzero.com, while keeping the actual hostname intact for the purposes of rendering links in the pages, etc.? Is there another technique to make this kind of migration easier? I did manually edit resin.xml for one of my webapps to respond to comics.stage.roderickmann.org, and created a DNS entry to match. But it can be tedious to change them all (not too bad, really, just looking for a nicer way). Eventually, all the stage nonesense will go away and the new machine will completely replace the old and the old will go away. -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] PHP iconv?
I just updated my WordPress 2.9.2 installation to 3.8. After some difficulty (auto upgrade didn't work), it's mostly working, but I'm getting some errors. One is this: wp-includes/class-http.php:1163: Warning: CURL option '10065' unknown or unimplemented RSS Error: The data could not be converted to UTF-8. You MUST have either the iconv or mbstring extension installed. Upgrading to PHP 5.x (which includes iconv) is highly recommended. I have resin 4.0.37. Is this really a PHP problem, or my CURL? Thanks, -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Can't use host-name in host?
I have Resin set up on my local machine to support development of a handful of web sites. In order to shorten startup times, I have the main resin.xml file include other config files: cluster id=app host id= root-directory=/Users/rmann/Projects/ resin:import fileset dir=/lz/config/resin/enabled include name=*.xml/ /fileset /resin:import ... Inside /lz/config/resin/enabled I have a bunch of .xml files like this: host xmlns=http://caucho.com/ns/resin; xmlns:resin=urn:java:com.caucho.resin host-namedev.latencyzero.com/host-name web-app id=/ document-directory=LZWeb/trunk/target/build ... If I don't include the host-name tag, it works fine, but I can only have one .xml file in the enabled directory at a time. Now I'm finding I'm flipping between two sites frequently (they have related functionality), and I'd like to enable both. I added two entries to my /etc/hosts file so that I could identify them separately (in the example above, one entry is 127.0.0.1 dev.latencyzero.com), but Resin balks with [13-12-09 14:37:36.491] WARNING com.caucho.server.webapp.ErrorPageManager sendServletErrorImpl: lz.xml:2: 'host-name' is an unknown property of 'com.caucho.server.host.Host'. Is there any way of accomplishing what I want to do, which is to enable and disable apps by moving config files in and out of the enabled folder, and also have virtual hosts? Thanks! -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Can't use host-name in host?
Actually, I first tried host-name as an attribute of the host tag, then I tried host-alias inside it. It failed in the same way. Then I tried host-name inside it, which failed the way you see. On Dec 9, 2013, at 15:26 , Scott Ferguson f...@caucho.com wrote: On 12/9/13, 2:57 PM, Rick Mann wrote: I have Resin set up on my local machine to support development of a handful of web sites. In order to shorten startup times, I have the main resin.xml file include other config files: Try host-alias instead. I've added a bug report. I think what's happening is that the resin:import isn't getting evaluated when you expect. It's being saved until the Host is configured. So it's evaluated too late to set the host-name, which is an early identifier like the id. -- Scott ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] javax.validation and 4.0.23 - 4.0.36?
I'm having a heck of a time with javax.validation and hibernate-validator. Works fine in 4.0.36, but fails with varying levels of inability to create the validation stack on .23. Before I go through the pain of updating resin on my server, was something fixed in the interim that would address this? TIA, -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Resin .37 download link points to .36
FYI, some of the non-pro links for .37 point to .36. -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Resin 4.0 admin manual section 1.3.3
The formatting is wonky and it seems to have placeholder text (some details on the starting-resin-command-line.xtp). http://www.caucho.com/download/resin-4.0-admin.pdf -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] BAM/hmtp errors?
I'm trying to upgrade to 4.0.37, and transition all my old config over to the new thing. I only run a single instance of resin, so it's confusing, but I took the default files and just inserted my hostweb-app block into resin.xml. It seems to run, but I get a lot of the following. Is it something to worry about? - Dec 9, 2013 7:46:08 PM com.caucho.bam.client.OutboundMessageStream query FINER: com.caucho.bam.RemoteConnectionFailedException: Cannot connect to http://127.0.0.1:6600/hmtp java.net.ConnectException: Connection refused com.caucho.bam.RemoteConnectionFailedException: Cannot connect to http://127.0.0.1:6600/hmtp java.net.ConnectException: Connection refused at com.caucho.hmtp.HmtpLinkFactory.open(HmtpLinkFactory.java:146) at com.caucho.bam.client.OutboundMessageStream.getLink(OutboundMessageStream.java:165) at com.caucho.bam.client.OutboundMessageStream.query(OutboundMessageStream.java:120) at com.caucho.bam.packet.Query.dispatch(Query.java:86) at com.caucho.bam.mailbox.MultiworkerMailbox$PacketProcessor.process(MultiworkerMailbox.java:408) at com.caucho.bam.mailbox.MultiworkerMailbox$PacketProcessor.process(MultiworkerMailbox.java:394) at com.caucho.env.actor.ValueActorQueue$ValueItemProcessor.process(ValueActorQueue.java:183) at com.caucho.env.actor.ValueActorQueue$ValueItemProcessor.process(ValueActorQueue.java:161) at com.caucho.env.actor.ActorQueue$ActorConsumer.doConsume(ActorQueue.java:453) at com.caucho.env.actor.ActorQueue$ActorConsumer.consumeAll(ActorQueue.java:406) at com.caucho.env.actor.ActorQueue$ActorConsumer.access$300(ActorQueue.java:340) at com.caucho.env.actor.ActorQueue$ActorWorker.runTask(ActorQueue.java:555) at com.caucho.env.thread2.AbstractTaskWorker2.run(AbstractTaskWorker2.java:240) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) Caused by: java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:529) at com.caucho.remote.websocket.WebSocketClient.connectImpl(WebSocketClient.java:180) at com.caucho.remote.websocket.WebSocketClient.connect(WebSocketClient.java:130) at com.caucho.remote.websocket.WebSocketClient.connect(WebSocketClient.java:121) at com.caucho.hmtp.HmtpLinkFactory.open(HmtpLinkFactory.java:138) ... 14 more Dec 9, 2013 7:46:08 PM com.caucho.bam.BamError create FINER: com.caucho.bam.RemoteConnectionFailedException: Cannot connect to http://127.0.0.1:6600/hmtp java.net.ConnectException: Connection refused com.caucho.bam.RemoteConnectionFailedException: Cannot connect to http://127.0.0.1:6600/hmtp java.net.ConnectException: Connection refused at com.caucho.hmtp.HmtpLinkFactory.open(HmtpLinkFactory.java:146) at com.caucho.bam.client.OutboundMessageStream.getLink(OutboundMessageStream.java:165) at com.caucho.bam.client.OutboundMessageStream.query(OutboundMessageStream.java:120) at com.caucho.bam.packet.Query.dispatch(Query.java:86) at com.caucho.bam.mailbox.MultiworkerMailbox$PacketProcessor.process(MultiworkerMailbox.java:408) at com.caucho.bam.mailbox.MultiworkerMailbox$PacketProcessor.process(MultiworkerMailbox.java:394) at com.caucho.env.actor.ValueActorQueue$ValueItemProcessor.process(ValueActorQueue.java:183) at com.caucho.env.actor.ValueActorQueue$ValueItemProcessor.process(ValueActorQueue.java:161) at com.caucho.env.actor.ActorQueue$ActorConsumer.doConsume(ActorQueue.java:453) at com.caucho.env.actor.ActorQueue$ActorConsumer.consumeAll(ActorQueue.java:406) at com.caucho.env.actor.ActorQueue$ActorConsumer.access$300(ActorQueue.java:340) at com.caucho.env.actor.ActorQueue$ActorWorker.runTask(ActorQueue.java:555) at com.caucho.env.thread2.AbstractTaskWorker2.run(AbstractTaskWorker2.java:240) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) Caused by: java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at
[Resin-interest] Thread Dump generated?
Is this a message I should be concerned about? I see it when I'm running a local development instance of Resin Open Source on OS X 10.9, in console mode. [13-11-30 21:24:59.790] INFO com.caucho.util.ThreadDump dumpThreads: Thread Dump generated Sat Nov 30 21:24:59 PST 2013 -- Rick signature.asc Description: Message signed with OpenPGP using GPGMail ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] already a root application context present
On Jul 8, 2013, at 09:43 , Scott Ferguson f...@caucho.com wrote: On 7/6/13 4:54 PM, Rick Mann wrote: I'm still getting this error with resin-4.0-36. It seems benign, in that the app continues to run, but I'd like to know what I'm doing wrong. I've added a bug report. I'll see if there's some double scanning or double initializing. It's behaving as if there were two spring jars in the WEB-INF/lib. (I'm sure there's not, but the behavior seems to be the same as if that was happening.) It's entirely possible I did something wrong. I don't have a web.xml any more, but I might have some annotation wrong. I still don't fully understand how that's all supposed to work. Here's every *spring* file in my WEB-INF/lib dir: ./WEB-INF/lib/org/springframework/security/spring-security-core/3.1.3.RELEASE/spring-security-core-3.1.3.RELEASE.jar ./WEB-INF/lib/org/springframework/spring-aop/3.2.0.RC2/spring-aop-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-beans/3.2.0.RC2/spring-beans-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-context/3.2.0.RC2/spring-context-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-core/3.2.0.RC2/spring-core-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-expression/3.2.0.RC2/spring-expression-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-jdbc/3.2.0.RC2/spring-jdbc-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-orm/3.2.0.RC2/spring-orm-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-test/3.2.0.RC2/spring-test-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-tx/3.2.0.RC2/spring-tx-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-web/3.2.0.RC2/spring-web-3.2.0.RC2.jar ./WEB-INF/lib/org/springframework/spring-webmvc/3.2.0.RC2/spring-webmvc-3.2.0.RC2.jar The Resin installation is fresh; no extra libs in there. -- Scott [13-07-06 16:52:02.422] INFO com.caucho.server.webapp.WebApp log: WebApp[production/webapp/default/ROOT,STARTING] Spring WebApplicationInitializers detected on classpath: [com.latencyzero.gamecenter.web.WebappInitializer@7c739ebd] [13-07-06 16:52:02.456] INFO com.caucho.server.webapp.WebApp log: WebApp[production/webapp/default/ROOT,STARTING] Initializing Spring root WebApplicationContext [13-07-06 16:52:03.931] WARNING com.caucho.server.webapp.WebApp startImpl: java.lang.IllegalStateException: Cannot initialize context because there is already a root application context present - check whether you have multiple ContextLoader* definitions in your web.xml! at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:264) at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112) at com.caucho.server.webapp.WebApp.startImpl(WebApp.java:3677) at com.caucho.server.webapp.WebApp$StartupTask.run(WebApp.java:5196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick Mann rm...@matterport.com Matterport, Inc. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] 4.0.35 works great locally on OS X, slightly busted on Rackspace Ubuntu 12.04
I have a server that's completely annotation-driven, and it was mostly working on .33, but .35 fixes an issue I had with mappings. Now it works perfectly locally on my OS X laptop, but when I run it on the server, everything seems to load except some resources under /css, which come back as 404. I get errors like this in the log: 19:32:14.099 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/tt.css] in DispatcherServlet with name 'dispatcher' 19:32:14.102 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/foundation.css] in DispatcherServlet with name 'dispatcher' It's very nearly an out-of-box installation. The only differences I can think of: - on OS X, I didn't run configure/make/make install. On Ubuntu I did. On OS X, I just unzipped and dragged to the install location. - on OS X, resin.properties is more stock, without an admin user, no setuid user/group, port 8080. As to the dispatcher servlet, getServletMappings looks like this: protected java.lang.String[] getServletMappings() { String[] mappings = { / }; return mappings; } I have a Spring controller at /service/* that works great. Just stuff under /css is 404. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] 4.0.35 works great locally on OS X, slightly busted on Rackspace Ubuntu 12.04
I may have spoken too soon. Looks like they might've been cached locally, as now it's also failing locally. More investigating... On Apr 8, 2013, at 19:37 , Rick Mann rm...@latencyzero.com wrote: I have a server that's completely annotation-driven, and it was mostly working on .33, but .35 fixes an issue I had with mappings. Now it works perfectly locally on my OS X laptop, but when I run it on the server, everything seems to load except some resources under /css, which come back as 404. I get errors like this in the log: 19:32:14.099 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/tt.css] in DispatcherServlet with name 'dispatcher' 19:32:14.102 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/foundation.css] in DispatcherServlet with name 'dispatcher' It's very nearly an out-of-box installation. The only differences I can think of: - on OS X, I didn't run configure/make/make install. On Ubuntu I did. On OS X, I just unzipped and dragged to the install location. - on OS X, resin.properties is more stock, without an admin user, no setuid user/group, port 8080. As to the dispatcher servlet, getServletMappings looks like this: protected java.lang.String[] getServletMappings() { String[] mappings = { / }; return mappings; } I have a Spring controller at /service/* that works great. Just stuff under /css is 404. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] 4.0.35 works great locally on OS X, slightly busted on Rackspace Ubuntu 12.04
On Apr 8, 2013, at 19:45 , Scott Ferguson f...@caucho.com wrote: That's not a Resin message (I just searched to make sure), so I'm not sure what the context is. You're right, that's from Spring, I'm pretty sure. From that getServletMappings() method, I'm wondering if you've overridden the default servlet. I'm not sure. I still don't know how the new servlet hotness is supposed to work. If you have, then it makes sense that Resin is no longer service static files like css, because your servlet has taken over for Resin's default servlet (resin-file). So, *something* is still serving up *.jsp. I can even find /css/test.jsp. I see that in app-default.xml, it has: servlet-mapping url-pattern=/ servlet-name=resin-file default=true/ Can I change that to *.css and *.js, etc? I wish there was a way to say, anything one of my Spring controllers maps, let my code handle it, anything else, resin should try. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] 4.0.35 works great locally on OS X, slightly busted on Rackspace Ubuntu 12.04
Trying changing my mappings to: /service/ didn't work /service/* didn't work But I noticed requesting /service (no trailing slash) actually did hit the right method, but none of the others under /service, including /, work. Is there an explanation of how a request is handled in a purely annotation-configured webapp? -- Rick On Apr 8, 2013, at 19:45 , Scott Ferguson f...@caucho.com wrote: On 4/8/13 7:37 PM, Rick Mann wrote: I have a server that's completely annotation-driven, and it was mostly working on .33, but .35 fixes an issue I had with mappings. Now it works perfectly locally on my OS X laptop, but when I run it on the server, everything seems to load except some resources under /css, which come back as 404. I get errors like this in the log: 19:32:14.099 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/tt.css] in DispatcherServlet with name 'dispatcher' 19:32:14.102 WARN servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/css/foundation.css] in DispatcherServlet with name 'dispatcher' That's not a Resin message (I just searched to make sure), so I'm not sure what the context is. From that getServletMappings() method, I'm wondering if you've overridden the default servlet. If you have, then it makes sense that Resin is no longer service static files like css, because your servlet has taken over for Resin's default servlet (resin-file). -- Scott It's very nearly an out-of-box installation. The only differences I can think of: - on OS X, I didn't run configure/make/make install. On Ubuntu I did. On OS X, I just unzipped and dragged to the install location. - on OS X, resin.properties is more stock, without an admin user, no setuid user/group, port 8080. As to the dispatcher servlet, getServletMappings looks like this: protected java.lang.String[] getServletMappings() { String[] mappings = { / }; return mappings; } I have a Spring controller at /service/* that works great. Just stuff under /css is 404. Any ideas? ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] 4.0.35 works great locally on OS X, slightly busted on Rackspace Ubuntu 12.04
On Apr 8, 2013, at 19:52 , Rick Mann rm...@latencyzero.com wrote: I see that in app-default.xml, it has: servlet-mapping url-pattern=/ servlet-name=resin-file default=true/ Can I change that to *.css and *.js, etc? So, the answer appears to be no. Not sure how it is that *.jsp is handled but *.css isn't. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Easing Development
On Jan 7, 2013, at 0:26 , Mattias Jiderhamn mj-li...@expertsystems.se wrote: I have reported a classloader / memory leak that I believe Scott tried to fix for 4.0.33. Haven't had time to verify yet though. Then add this library to your web app, to get rid of third party leaks: http://java.jiderhamn.se/2012/03/04/classloader-leaks-vi-this-means-war-leak-prevention-library/ I'll check it out. I often need to restart, anyway, because I use Spring MVC, but that might help. ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Easing Development
I typically work on web apps as a component of other projects. At any given time on my local machine I've got three or four web apps that I rotate through. To speed things up, I reconfigure resin.xml each time I switch to a new one, so I don't have to wait for the others to start up. I run resin in console mode to make it easy to kill and restart I find it a little cumbersome to go to resin.xml and uncomment one webapp and comment out another. I'm wondering if I can't accomplish the same thing by moving the webapp declarations to separate files in a known directory, and just have resin.xml include all the files in that directory. That way, I can just move the fragment files in and out of this enabled apps directory. So, I tried changing resin.xml to: cluster id=app !-- define the servers in the cluster -- server-multi id-prefix=app- address-list=${app_servers} port=6800/ !-- the default host, matching any host name -- host id= root-directory=/Projects/ resin:import fileset dir=/config/resin/enabled include name=*.xml/ /fileset /resin:import // and I'm trying to include a file that contains: web-app id=/ document-directory=MyApp/web/trunk/target/build ... /web-app But it doesn't like web-app at the top level. So I wrapped that in resin tags, but it doesn't like that, either. Can I not do this? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Easing Development
On Jan 3, 2013, at 14:32 , Scott Ferguson f...@caucho.com wrote: You need to use host in this case. The resin:import expects the current tag as the included top-level tag. That way, your foo.xml could have multiple web-app items or other host children. I tried that, too, but got the same error. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Resin on Raspberry Pi?
Has anyone tried running resin on Raspberry Pi? So far I've got the JDK up, but it won't run in server mode (it's an armv6, and the JVM says server mode requires armv7+). -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] server 'app-0' is an unknown server in the configuration file?
# properties_import_url : http://169.254.169.254/latest/user-data On Dec 18, 2012, at 22:46 , Rick Mann rm...@latencyzero.com wrote: I just built a new machine, by installing resin .33-snap, and copying over the resin.xml and resin.properties files from a working machine with .32 on it. When I launch with resin.sh console, I get: com.caucho.config.ConfigException: -server 'app-0' is an unknown server in the configuration file. at com.caucho.server.resin.Resin.initTopology(Resin.java:1069) at com.caucho.server.resin.Resin.initServletSystem(Resin.java:1275) at com.caucho.server.resin.Resin.configure(Resin.java:997) at com.caucho.server.resin.Resin.initMain(Resin.java:979) at com.caucho.server.resin.Resin.main(Resin.java:1437) -server 'app-0' is an unknown server in the configuration file. Am I missing something? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] More servlet 3.0 issues
Hi. I'm able to register a servlet to match /* (and my servlet ends up matching only some paths under /service). But if I register it under /service/*, then none of the paths match (well, only /service matches, anything else, include /service/, doesn't match. /service: 15:19:49.771 WARN springframework.web.servlet.DispatcherServlet (DispatcherServlet.java:1108) No mapping found for HTTP request with URI [/service/] in DispatcherServlet with name 'dispatcher' -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] server 'app-0' is an unknown server in the configuration file?
I just built a new machine, by installing resin .33-snap, and copying over the resin.xml and resin.properties files from a working machine with .32 on it. When I launch with resin.sh console, I get: com.caucho.config.ConfigException: -server 'app-0' is an unknown server in the configuration file. at com.caucho.server.resin.Resin.initTopology(Resin.java:1069) at com.caucho.server.resin.Resin.initServletSystem(Resin.java:1275) at com.caucho.server.resin.Resin.configure(Resin.java:997) at com.caucho.server.resin.Resin.initMain(Resin.java:979) at com.caucho.server.resin.Resin.main(Resin.java:1437) -server 'app-0' is an unknown server in the configuration file. Am I missing something? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/servlet/ServletException
I've been working on this Spring-based webapp. It was originally a servlet-2.5, XML-configured webapp that ran great under Resin and I had a nice spring-test-mvc-based test class for it, and it all worked well. After upgrading it to servlet-3.0, and using only annotations to configure (no XML!), the webapp works, but I can't get my test class to work. I'm fairly sure I still haven't configured it correctly, but in the Spring forums I'm being told that I'm linking against the javaee-web-api 6.0 jar, which contains no implementation. While this is true, it was also true before the configuration changes. So the guy (a fair expert on Spring) tells me it must be due to some JAR load order difference that's causing the error to appear now. Thing is, in the test environment, I don't have any part of resin involved. I don't know where else I might be getting an implementation. The exception is [junit] java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/servlet/ServletException [junit] at java.lang.ClassLoader.defineClass1(Native Method) ... [junit] at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors(AutowiredAnnotationBeanPostProcessor.java:230) ... [junit] at org.springframework.test.context.TestContext.getApplicationContext(TestContext.java:148) [junit] at org.springframework.test.context.web.ServletTestExecutionListener.setUpRequestContextIfNecessary(ServletTestExecutionListener.java:105) ... So, I'm just curious if anyone here can shed some light on how this can come to be. Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] resin .33 loading listener?
It seems, but I can't be sure, that resin is taking it upon itself to load a ServletContextListener implementation in Spring. Unfortunately, doing so causes an error. [12-13 02:10:06.091] WARNING com.caucho.server.webapp.WebApp start: java.lang.IllegalStateException: Cannot initialize context because there is already a root application context present - check whether you have multiple ContextLoader* definitions in your web.xml! at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:264) at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:112) at com.caucho.server.webapp.WebApp.start(WebApp.java:3637) at com.caucho.env.deploy.DeployController.startImpl(DeployController.java:688) at com.caucho.env.deploy.StartAutoRedeployAutoStrategy.startOnInit(StartAutoRedeployAutoStrategy.java:77) ... I have no .xml files in my webapp, so I'm not sure where this is coming from. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Resin 4.0.33 not dispatching servlet-3.0?
Hi guys. The .33 snapshot is instantiating my initializer correctly, and that code is calling this: ServletRegistration.Dynamic registration = servletContext.addServlet(servletName, dispatcherServlet); registration.setLoadOnStartup(1); registration.addMapping(new String[/]); However, I don't see anything in the Caucho logging indicating that it registered a servlet (not sure if there is anything). I did see this, which doesn't seem right: [12-12-13 03:50:11.038] CONFIG com.caucho.server.dispatch.ServletMapper addUrlMapping: servlet-mapping / - resin-file It also doesn't respond to a request for http://localhost:8080/. I see this much: [12-12-13 03:50:22.636] FINER com.caucho.network.listen.TcpSocketLink requestAccept: TcpSocketLink[id=http://*:8080-5,http://*:8080,INIT] request-accept http://*:8080-5 (count=4, idle=3) [12-12-13 03:50:22.636] FINEST com.caucho.network.listen.TcpSocketLink startThread: TcpSocketLink[id=http://*:8080-5,http://*:8080,INIT] start thread resin-port-8080-22 (count=5, idle=4) [12-12-13 03:50:22.637] FINEST com.caucho.network.listen.TcpSocketLink initSocket: TcpSocketLink[id=1,app-0] starting connection TcpSocketLink[id=http://*:8080-1,http://*:8080,ACCEPT], total=5 [12-12-13 03:50:22.637] FINER com.caucho.network.listen.TcpSocketLink handleAcceptTaskImpl: TcpSocketLink[id=http://*:8080-1,http://*:8080,ACCEPT] accept from [::1]:8080 [12-12-13 03:50:22.645] FINE com.caucho.server.http.HttpRequest parseRequest: Http[app-0, 1] GET / HTTP/1.1 [12-12-13 03:50:22.645] FINE com.caucho.server.http.HttpRequest parseRequest: Http[app-0, 1] Remote-IP: [::1]:8080 [12-12-13 03:50:22.645] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Host: localhost:8080 [12-12-13 03:50:22.645] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.17 (KHTML, like Gecko) Version/6.0.2 Safari/536.26.17 [12-12-13 03:50:22.645] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 [12-12-13 03:50:22.646] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] DNT: 1 [12-12-13 03:50:22.646] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Cache-Control: max-age=0 [12-12-13 03:50:22.646] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Accept-Language: en-us [12-12-13 03:50:22.646] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Accept-Encoding: gzip, deflate [12-12-13 03:50:22.646] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Cookie: __utma=111872281.1148524109.1354299737.1354304258.1355118330.3; __utmz=111872281.1354299737.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); JSESSIONID=aaaCemYsZ1z9x6D_VaoUt; uid=1; crucibleprefs1=D%3D1343201447093; remember=rmann:0:cb76f8d95c02b5fae41a3fa0206a927c [12-12-13 03:50:22.647] FINE com.caucho.server.http.HttpRequest parseHeaders: Http[app-0, 1] Connection: keep-alive [12-12-13 03:50:22.651] FINEST com.caucho.server.webapp.WebApp getRealPath: real-path / - /Users/rmann/Projects/Clients/RedBirdStudios/repo/web/trunk/target/build/ [12-12-13 03:50:22.651] FINEST com.caucho.server.webapp.ServletContextImpl getResourceAsStream: java.io.FileNotFoundException: /Users/rmann/Projects/Clients/RedBirdStudios/repo/web/trunk/target/build/ at com.caucho.vfs.JniFilePathImpl.openReadImpl(JniFilePathImpl.java:402) at com.caucho.vfs.Path.openRead(Path.java:1149) at com.caucho.server.webapp.ServletContextImpl.getResourceAsStream(ServletContextImpl.java:404) at com.caucho.server.dispatch.ServletMapper.mapServlet(ServletMapper.java:252) at com.caucho.server.webapp.WebApp.buildInvocation(WebApp.java:3906) at com.caucho.server.webapp.WebAppContainer.buildInvocation(WebAppContainer.java:781) at com.caucho.server.host.Host.buildInvocation(Host.java:752) at com.caucho.server.host.HostContainer.buildInvocation(HostContainer.java:319) at com.caucho.server.cluster.ServletService.buildInvocation(ServletService.java:1014) at com.caucho.server.dispatch.InvocationServer.buildInvocation(InvocationServer.java:247) at com.caucho.server.dispatch.InvocationServer.buildInvocation(InvocationServer.java:220) at com.caucho.server.http.AbstractHttpRequest.buildInvocation(AbstractHttpRequest.java:1597) at com.caucho.server.http.AbstractHttpRequest.getInvocation(AbstractHttpRequest.java:1570) at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:820) at
Re: [Resin-interest] Resin 4.0.33 not dispatching servlet-3.0?
On Dec 13, 2012, at 11:32 , Scott Ferguson f...@caucho.com wrote: That behavior is part of the spec. If the mapping already exists, the addMapping does nothing. It's not an override. Wait, really? In my web.xml, I used to have: servlet servlet-nameDispatcher/servlet-name servlet-classorg.springframework.web.servlet.DispatcherServlet/servlet-class init-param param-namecontextConfigLocation/param-name param-value/WEB-INF/config/springWebDispatcherConfig.xml/param-value /init-param load-on-startup3/load-on-startup /servlet servlet-mapping servlet-nameDispatcher/servlet-name url-pattern//url-pattern /servlet-mapping And you're saying that the new hotness doesn't allow me to do that? Or is there a way to avoid the resin mapping? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Resin 4.0.33 not dispatching servlet-3.0?
Okay, so it sounds like I'll have to go back to pre-3.0 configuration for the foreseeable future. Hate to say it, because you guys do such great work, but it seems that as currently implemented, resin can't be used as a servlet 3.0 container. Let me ask this: the only URL I really need to run through Spring's DispatcherServet is /service/**. I had been running everything through it so my Spring controllers could handle everything, but I don't need that right now. Should I be able to register it for /service and get what I need? Also, is resin creating that ContextLoaderListener on its own? Sent from my iPhone On Dec 13, 2012, at 12:36, Scott Ferguson f...@caucho.com wrote: On 12/13/12 12:16 PM, Rick Mann wrote: On Dec 13, 2012, at 11:32 , Scott Ferguson f...@caucho.com wrote: That behavior is part of the spec. If the mapping already exists, the addMapping does nothing. It's not an override. Wait, really? In my web.xml, I used to have: ... And you're saying that the new hotness doesn't allow me to do that? Yep, the new spec feature works backwards from Resin's configuration behavior. (No, I don't know why they chose that definition.) Or is there a way to avoid the resin mapping? That's what the bug report would be. We'd have to add some kind of configuration or marker to let Resin's configuration be a lower priority. -- Scott ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Configuration for scaling
Hi. I'm running resin 4.0.32 (?) on a couple of virtual hosts at Rackspace on Ubuntu. These are small machines, 512 MB of RAM, but they're pretty much only running their resin (free) instance. I'm doing some rudimentary load testing with JMeter. I have a script that makes three calls to the REST service implemented in my webapp. When I try to do 1000 simultaneous connections (via round-robin load balancing onto two nodes, so figure ~500 near-simultaneous connections), my app starts throwing exceptions about not being able to open connections to the DB: Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: User gcs already has more than 'max_user_connections' active connections So, clearly I need to expand the DB's capabilities. But JMeter also reports a nunch of these: httpSample t=1 lt=0 ts=1355286080856 s=false lb=HTTP Request rc=Non HTTP response code: java.net.SocketException rm=Non HTTP response message: Too many open files tn=Thread Group 1-918 dt=text by=1436/ My configuration is basically out-of-the-box resin.xml. I can increase the amount of RAM available, there's no session state being stored. I'm wondering what config settings to look into increasing (number of threads? Connections allowed?) Any guidance on how much RAM one needs for a given number of threads and connections? Sorry for the rudimentary question, but this is the first time I've been responsible for making sure our web app stays up, and I don't have a good idea how many requests we might need to support. Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Aughh!!
On Nov 14, 2012, at 7:30 , Paul Cowan co...@caucho.com wrote: Thanks, I have verified this is a bug and entered a report: http://bugs.caucho.com/view.php?id=5275 Please try modifying the entry as I included below, it should work around the issue. Let me know if otherwise. host id=missiondb.lz.com root-directory=/lz/var/www/ host-alias-regexpsatdb.org[\.]?/host-alias-regexp host-alias-regexpmissiondb.lz.com[\.]?/host-alias-regexp host-alias-regexpkepler.lz.com[\.]?/host-alias-regexp Thanks, Paul. That's what I ended up doing. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Sudden startup error java.lang.ClassNotFoundException: com.caucho.admin.ProAdminServices
On Nov 14, 2012, at 6:46 , Paul Cowan co...@caucho.com wrote: Are you still seeing this issue? It certainly appears to be some mixup in library versions. Perhaps resin.home and/or resin.root are set to point to an older version. Hmm. That's possible. I'll take a look next time I run into the error (I rotate between a lot of projects on vastly different platforms, seem to promptly forget what I was doing on the previous one :-) ). -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] fmt.sprintf leads to NPEs
On Nov 14, 2012, at 6:42 , Paul Cowan co...@caucho.com wrote: I do not think the NPE causes any issue, as it only shows up for me using finer level logging. However it's certainly a bug, and I have entered a report: http://bugs.caucho.com/view.php?id=5274 Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Sudden startup error java.lang.ClassNotFoundException: com.caucho.admin.ProAdminServices
I'm suddenly getting a couple of exceptions during startup (resin.sh console) on Resin 4.0.30. [12-11-11 02:47:52.096] {main} Resin-4.0.30 (built Mon, 20 Aug 2012 10:00:11 PDT) [12-11-11 02:47:52.096] {main} [12-11-11 02:47:52.096] {main} Mac OS X 10.8.2 x86_64 [12-11-11 02:47:52.096] {main} Java(TM) SE Runtime Environment 1.6.0_37-b06-434-11M3909, MacRoman, en [12-11-11 02:47:52.096] {main} Java HotSpot(TM) 64-Bit Server VM 20.12-b01-434, 64, mixed mode, Apple Inc. [12-11-11 02:47:52.096] {main} [12-11-11 02:47:52.096] {main} user.name = rmann [12-11-11 02:47:52.104] {main} java.lang.ClassNotFoundException: com.caucho.admin.ProAdminServices and [12-11-11 02:47:52.333] {main} javax.management.InstanceAlreadyExistsException: 'resin:type=AccessLog,Host=default' in MBeanContext[EnvironmentClassLoader[host:default,NEW]] I tried removing the resin-data and watchdog-data directories to no avail. I also noticed this in the logs (on a run after the first one after deleting resin-data): [12-11-11 02:53:20.060] {main} Table[data] Resin-DB 4.0.28 loading CREATE TABLE data(id IDENTITY PRIMARY KEY,data BLOB) The version shown is 4.0.28, I'm running 4.0.30. The app still seems to run after this, but it's puzzling. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Aughh!!
Wow, it must be dump-on-Rick day. Not only is my local resin (4.0.30) startup suddenly bonkers, so is one of my long-standing servers (4.0.19). I made some minor changes to the webapp, uploaded the changed files, saw it restart, everything was fine. Then I stopped and re-started resin, like I always do on that machine, basically running this: java -jar $RESIN_HOME/lib/resin.jar -verbose -root-directory /path/to/dir -conf /path/to/resin.xml start|stop Now, it complains about the native libraries missing and JNI being a resin pro feature (this is just resin open source), which is fine, but it finishes startup in no time at all, and near as I can tell, never starts my webapp. Like it's not even there. No error messages in the logs, nothing. Since it's 4:30 am and no one can respond to this, I don't know what else to do but install the newest resin and rebuild my server from scratch. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] fmt.sprintf leads to NPEs
When I use this format for the main log-handler in 4.0.32, I get numerous NPEs during startup: format= ${fmt.sprintf('%-7s %-20.20s %s', log.level, thread, log.message)}/ -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Aughh!!
Well, even installing 4.0.32 I had very similar behavior; my webapp is just ignored. Then I noticed something. I access it via an alias. It's configured like this: host regexp=kepler.lz.com[\.]? root-directory=/lz/var/www/ host-alias-regexpsatdb.org[\.]?/host-alias-regexp host-alias-regexpmissiondb.lz.com[\.]?/host-alias-regexp host-namemissiondb.lz.com/host-name Resin doesn't try to start it up if I hit missiondb.lz.com first. But if I hit kepler.lz.com, then it inits. I wonder if the same thing was happening in 4.0.19. I just don't know why I've only now started seeing this. -- Rick On Nov 11, 2012, at 4:23 , Rick Mann rm...@lz.com wrote: Wow, it must be dump-on-Rick day. Not only is my local resin (4.0.30) startup suddenly bonkers, so is one of my long-standing servers (4.0.19). I made some minor changes to the webapp, uploaded the changed files, saw it restart, everything was fine. Then I stopped and re-started resin, like I always do on that machine, basically running this: java -jar $RESIN_HOME/lib/resin.jar -verbose -root-directory /path/to/dir -conf /path/to/resin.xml start|stop Now, it complains about the native libraries missing and JNI being a resin pro feature (this is just resin open source), which is fine, but it finishes startup in no time at all, and near as I can tell, never starts my webapp. Like it's not even there. No error messages in the logs, nothing. Since it's 4:30 am and no one can respond to this, I don't know what else to do but install the newest resin and rebuild my server from scratch. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Scaling Up
On Nov 9, 2012, at 0:19 , Riccardo Cohen r.co...@realty-property.com wrote: Hello Rick I haven't worked a lot on this, but if you want I can provide my resin.xml : in my application I have one resin front loadbalancer, with N application servers (all IP are known) and potentially 2 mysql db servers . I use resin 4.0.13 pro on linux debian Thanks, Riccardo, couldn't hurt! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Scaling Up
On Nov 9, 2012, at 18:19 , Scott Ferguson f...@caucho.com wrote: - My current app has no session state at all, but does intantiate a lot of Hibernate objects in the app. Hibernate caching adds to this (I don't know how writes are handled). Do you have recommendations for ensuring failover works properly in this situation? Since I'm not a hibernate expert, someone else might need to answer this. I might actually be wrong about this one. Without explicit (Hibernate) caching, I think it's actually creating a persistence session on each request, and so all objects are created and destroyed in the request. Hibernate caching is its own beast, I'm sure I'll have to tackle that next. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Scaling Up
On Nov 9, 2012, at 18:19 , Scott Ferguson f...@caucho.com wrote: There's failover to backup triad members if the primary fails. There's an ack from the triad to tell when it's been completed. That's the basic idea. The cache is actually a fairly complicated messaging application. It's been lots of fun to implement. Does that ack happen before the session.setAttribute() call returns? If not, it seems like there might be a hole. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Scaling Up
I've used Resin for 6 or 8 years now, ever since working at a company that used it. I use it for a lot of little personal projects and web sites, nothing very substantial. But there's a chance that something I did recently will grow, and I'm looking at how to use Resin with Rackspace virtual hosts. I'm finding it hard to get through some of Caucho's concepts. How is a web server different from an app server? Is a web server the same as a load balancer? All my apps run completely self-contained on a single server, talking to a MySQL instance running on the same machine, using Hibernate and no special caching. I'm having a hard time quickly learning how to move from that environment to the triad and elastic servers. Can I take the intermediate step of running just two servers? How does load balancing work? I've only ever used a Big IP F5. Do I want to bother with Rackspace's load balancers? Stuff like that. Is there a good introductory document (not just a set of slides)? So far, everything I've read assumes a certain level of knowledge. Thanks, -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Scaling Up
Thanks, Scott, I'll read through that more carefully shortly. One question. Do I set up one server with the multi-machine additions as you show, and then just replicate the config file (and server, webapp, et al) onto all the machines? I realize that may seem obvious, but I want to be sure. Also, how do I get them to talk to each other via private interfaces? Or does that happen magically with Rackspace? -- Rick On Nov 8, 2012, at 19:08 , Scott Ferguson f...@caucho.com wrote: On 11/8/12 6:11 PM, Rick Mann wrote: I've used Resin for 6 or 8 years now, ever since working at a company that used it. I use it for a lot of little personal projects and web sites, nothing very substantial. But there's a chance that something I did recently will grow, and I'm looking at how to use Resin with Rackspace virtual hosts. I'm finding it hard to get through some of Caucho's concepts. How is a web server different from an app server? Is a web server the same as a load balancer? All my apps run completely self-contained on a single server, talking to a MySQL instance running on the same machine, using Hibernate and no special caching. I'm having a hard time quickly learning how to move from that environment to the triad and elastic servers. Can I take the intermediate step of running just two servers? How does load balancing work? I've only ever used a Big IP F5. Do I want to bother with Rackspace's load balancers? Stuff like that. Is there a good introductory document (not just a set of slides)? So far, everything I've read assumes a certain level of knowledge. We're working on a video that should help. In the meantime: 1) Basically, we start with a single server, just like you're using now. That's an app server because it runs your applications (it also serves static web requests of course.). app_servers : 127.0.0.1:6800 2) Now you either want or need a second app server, either because of load or memory or reliability. That would be two servers. The two servers would be the first two in the triad. The triad stuff happens automatically. The first servers in your list are triad members. In truth, you don't usually need to know about the triad, except you should take a little care to put them on different hardware for reliability. app_servers : 192.168.0.10:6800, 192.168.0.11:6800 (You can also put two Resin servers on one box. Just use the same IP and different ports, like 6801. We use this for testing all the time, and some people do that for reliability or better memory management on one machine.) 3) load balancing But now there's a difficulty because some how the requests need to be shared across the multiple servers, so you need a load balancer of some sort. Resin doesn't care what load balancer you use. We're trying to support whatever configuration you want, assuming that you have a better idea of how you want to balance your own load. Resin's load balancer is mostly provided as an option for medium sites so you don't need to use a hardware load balancer, and because it's easy to configure. (Some sites even use a hardware load balancer in combination with Resin's load balancer.) If you're using a non-Resin load balancer, just point it to the 2 server's http ports. If you're using Resin's load balancer, just add a web_server entry: web_servers : 192.168.1.10:6820 In this case, I put the load balancer on the first machine. That's a perfectly reasonable configuration for a smallish configuration. Make sure all servers are using the same resin.xml and resin.properties. The entire point of Resin's design is to allow you to use a single configuration for your entire cluster. 4) Adding servers. You can keep adding servers to the app_servers list. The first three are automatically the triad. You don't need to do anything special, but if you have different physical servers, it's a good idea to split them for reliability. As long as every server sees that app_servers, the load balancing will just work with the new servers. 5) web vs app tiers. The idea of those two is to mirror the common Apache/Resin or nginx/Resin reverse proxy configuration where you replace Apache with another Resin. You can use that configuration even if you have one app-server. (Benefit is that it isolates the application from the actual network. The penalty is a bit of performance.) The web tier is simple and more reliable because it's only serving HTTP requests and cached data. It also isolates the web from the app tier, because only the web tier needs to worry about things like flaky network connections. When you're using Resin as a load balancer the web tier is the load balancer. 6) The triad. Mostly, it's an internal Resin clustering concept. The main purpose is to handle clustering for fairly large sites that have large variations in load where they want
Re: [Resin-interest] Scaling Up
On Nov 8, 2012, at 19:08 , Scott Ferguson f...@caucho.com wrote: We're working on a video that should help. One more request: I really prefer text descriptions. I find videos excruciatingly difficult to sit through, whereas a well-written textual how-to allows me to skim over parts I'm familiar with. One of the keys to making it well-written is to put the actual steps to carry out in a bullet-point or numbered list, so that a crucial bit of info isn't buried in a paragraph somewhere. Thanks! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Scaling Up
On Nov 8, 2012, at 19:28 , Scott Ferguson f...@caucho.com wrote: Yes, all the servers will have the same configuration. Okay, so, I can set one up with the config, make a snapshot of that machine, then bring up more instances from that snapshot. I'll have to figure out how to manage the IP addresses of the hosts that I bring up; might have to manually edit the config file after they're brought up. Similar question for elastic servers. Also, how do I get them to talk to each other via private interfaces? Or does that happen magically with Rackspace? Ah. I wasn't explicit about that. (You're right about assumptions.) :-) The IP addresses you put in app_servers and web_servers are *private* addresses. You shouldn't put public addresses in the app_servers and web_servers, if you have the option. If you have 1 machine, you should use 127.0.0.1, otherwise use the private IP. I don't specifically know about Rackspace, but you might need to change the firewall settings so each server is allowed to connect to 6800. Amazon, for example, has a security group firewall, so only the servers in the security group are allowed to see 6800. Outside servers can't get to it. I'm sure Rackspace has something similar. Yes, I remember dealing with that on EC2, I'll figure out what Rackspace does. I did find the two IPs, internal and external. One thing that's becoming clear is what was listening on 6800 vs 80: 6800 is for internal communication among servers. Not sure if it's used in the single-server case, but I understand. When you start Resin with start-all (or the /etc/init.d script), Resin will compare its own IP address with the configuration IP addresses in app_servers and web_servers and start itself as the local address. (Does that make sense?) Yes, I think so. After I make some dinner I'll try to go through your original email and get a couple servers running. The first server will be my load balancer, which will hit itself and the other server. MySQL can sit on the first server (although I imagine in that configuration, it might make sense for it to sit on the other server, since the first has the added burden of being the load balancer). Thanks! I'm rather excited to try running multiple machines, and see how badly my code breaks. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] server-multi?
What is this tag? It's not listed in the reference: http://www.caucho.com/resin-4.0/reference.xtp -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] server-multi?
On Oct 24, 2012, at 14:56 , Scott Ferguson f...@cauchomail.com wrote: On 10/24/12 2:47 PM, Rick Mann wrote: What is this tag? It's not listed in the reference: http://www.caucho.com/resin-4.0/reference.xtp Thanks. We'll need to fix that. The server-multi is meant to work together with the resin.properties file to simplify defining a cluster. The main purpose is to allow the resin.properties to define a 3-server cluster with a single property like: app_servers : 192.168.1.10:6800 192.168.1.11:6800 192.168.1.12:6800 Essentially, it's a macro that creates multiple server entries, one for each item in the address-list. The names of the servers are generated automatically, app-0, app-1, app-2. It's equivalent to creating the three server items individually. Thanks, Scott! -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] Weird 404 problem
I just made a fairly minor change to a webapp that's been running well for years. I uploaded it to a new directory on the server, and then modified the resin.xml to point to the new location. I stopped and restarted resin to be sure. resin 4.0.19 I tried loading up /, and it gave me a 404 error. I double-checked the paths, tried slightly different ways of specifying them (host tag vs web-app tag), no luck. Then I loaded my server using the host name specified in the host tag (I usually use the host alias). Suddenly, things loaded. After that, I was able to go back to using the host alias. I bounced the server, and had the same issue. My host looks like this: host regexp=kepler.latencyzero.com[\.]? root-directory=/lz/var/www/ host-alias-regexpsatdb.org[\.]?/host-alias-regexp host-alias-regexpmissiondb.latencyzero.com[\.]?/host-alias-regexp I was unable to access it via missiondb.latencyzero.com until I had first accessed it via kepler.latencyzero.com. Note that before, when the web-app was configured to point to a different directory, I never experienced this problem. The log shows this on the 404: [10-24 19:44:25.611] {main} INFO (com.caucho.server.resin.Resin) Resin[id=default] started in 1513ms [10-24 19:45:36.037] {http://*:80-1} FINE (com.caucho.network.listen.TcpSocketLink) TcpSocketLink[id=1,default] starting connection TcpSocketLink[id=http://*:80-1,http://*:80,ACCEPT], total=4 [10-24 19:45:36.107] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] GET / HTTP/1.1 [10-24 19:45:36.108] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Remote-IP: 24.6.132.52:39388 [10-24 19:45:36.108] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Host: missiondb.latencyzero.com [10-24 19:45:36.108] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.14 (KHTML, like Gecko) Version/6.0.1 Safari/536.26.14 [10-24 19:45:36.109] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 [10-24 19:45:36.109] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] DNT: 1 [10-24 19:45:36.109] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Cache-Control: max-age=0 [10-24 19:45:36.109] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Accept-Language: en-us [10-24 19:45:36.109] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Accept-Encoding: gzip, deflate [10-24 19:45:36.110] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Cookie: JSESSIONID=aaaWfBTI_5iQ4fiKgLuQt; uid=1; __utma=268186515.520977954.1346150693.1348185637.1350813288.11; __utmz=268186515.1346150693.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none) [10-24 19:45:36.110] {http://*:80-1} FINE (com.caucho.server.http.HttpRequest) Http[default, 1] Connection: keep-alive [10-24 19:45:36.151] {http://*:80-1} FINE (com.caucho.env.deploy.EnvironmentDeployController) Host[error/host/error] initializing [10-24 19:45:36.152] {http://*:80-1} FINE (com.caucho.env.deploy.EnvironmentDeployController) Host[error/host/error] root-directory=/error [10-24 19:45:36.215] {http://*:80-1} FINE (com.caucho.env.deploy.EnvironmentDeployController) WebApp[error/webapp//error,NEW] initializing [10-24 19:45:36.218] {http://*:80-1} FINE (com.caucho.env.deploy.EnvironmentDeployController) WebApp[error/webapp//error,NEW] root-directory=/error-root [10-24 19:45:36.325] {http://*:80-1} CONFIG (com.caucho.server.dispatch.ServletMapper) servlet-mapping *.jsp - resin-jsp [10-24 19:45:36.326] {http://*:80-1} CONFIG (com.caucho.server.dispatch.ServletMapper) servlet-mapping *.jspf - resin-jsp [10-24 19:45:36.327] {http://*:80-1} CONFIG (com.caucho.server.dispatch.ServletMapper) servlet-mapping *.jspx - resin-jspx [10-24 19:45:36.327] {http://*:80-1} CONFIG (com.caucho.server.dispatch.ServletMapper) servlet-mapping *.php - resin-php [10-24 19:45:36.327] {http://*:80-1} CONFIG (com.caucho.server.dispatch.ServletMapper) servlet-mapping / - resin-file [10-24 19:45:36.386] {http://*:80-1} FINE (com.caucho.server.http.AbstractHttpResponse) Http[default, 1] HTTP/1.1 404 Not Found [10-24 19:45:36.386] {http://*:80-1} FINE (com.caucho.server.http.AbstractHttpResponse) Http[default, 1] Content-Type: text/html; charset=utf-8 [10-24 19:45:36.387] {http://*:80-1} FINE (com.caucho.server.http.AbstractHttpResponse) Http[default, 1] Content-Length: 186 [10-24 19:45:36.387] {http://*:80-1} FINE (com.caucho.server.http.HttpResponseStream) Http[default, 1] finish/keepalive Any ideas? Thanks. -- Rick ___ resin-interest mailing list
Re: [Resin-interest] Strange class loading issues
I figured it out. Missing path component in the web-app config. Kinda wish it would say NO DIRECTORY AT BLAH BLAH DUMBASS :-) -- Rick On Oct 17, 2012, at 4:07 , Rick Mann rm...@latencyzero.com wrote: I have two webapps in the same host tag. They're nearly identical (one was cloned from the other). But when resin starts, it complains about not being able to load the MySQL driver: [12-10-17 03:37:47.450] {resin-19} /Library/Resin/current/conf/resin.xml:188: com.caucho.sql.DriverConfig.setType(): com.caucho.config.ConfigRuntimeException: java.lang.ClassNotFoundException: com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource in EnvironmentClassLoader[web-app:production/webapp/default/ROOT,NEW] 186: max-idle-time30s/max-idle-time 187: driver 188: typecom.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource/type 189: urljdbc:mysql://localhost:3306/gamecenter/url 190: usergamecenter/user Thing is, the other webapp loads it exactly the same way, and has no problem. Both apps have the .jar file in the same place inside WEB-INF/lib (using the tree loader). This kind of thing seems to happen a lot, and it's always a pain to debug. Thanks, -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] JSP encoding issues
On Aug 28, 2012, at 13:55 , Aaron Freeman aaron.free...@layerz.com wrote: We had that issue when using jsp:include (jsp:include content wouldn't get UTF-8 encoded), but switching it out for c:import worked. Not sure if this applies in your case, but if the copyright is jsp:include'd you might try to c:import and see if you get different results. No matter what you did in the highest level JSP (the controller if you will) it didn't encode stuff brought in via the jsp:include. I thought that had been fixed at one point, but possibly not. I originally did NOT use jsp:include, just had the markup right there in the page. The only thing I did was include (using %@ page include) was a prefix file that included a few tag libraries, and set the content type of the page. (As I understand it, you have to set the content type of all the pages, even jsp:include ones.) In any case, I tried reverting to that same arrangement, and could no longer reproduce the problem. But I've experimented with so many ways of setting the encoding, I'm sure I didn't get back to exactly where I was (where an empty %@ page% directive would make the difference). Aaron -Original Message- From: resin-interest-boun...@caucho.com [mailto:resin-interest- boun...@caucho.com] On Behalf Of Rick Mann Sent: Tuesday, August 28, 2012 3:50 PM To: General Discussion for the Resin application server Subject: Re: [Resin-interest] JSP encoding issues Sorry, I should've been more clear. The problem I'm experiencing is not that the headers aren't being properly set. It's that UTF-8 in my source page is getting mangled. In this case, a copyright symbol (C), while still rendered in the page, is preceded by a capital A with an accent (not sure of the exact character) when finally rendered in Safari or FireFox. Somewhere in the long chain of processing, a conversion is happening. -- Rick On Aug 28, 2012, at 10:15 , Scott Ferguson f...@caucho.com wrote: On 08/27/2012 05:04 PM, Rick Mann wrote: Oh, I can also put that empty page directive at the end of my include file, and it also triggers the correct behavior. What, exactly isn't working? The parsing of the page? Or the content-type header? I just created a filter and JSP to reproduce this, and in all cases the res.setCharacterEncoding or res.setContentType is passed through to the output. -- Scott On Aug 27, 2012, at 16:39 , Rick Mann rm...@latencyzero.com wrote: I'm trying to serve everything UTF-8. To this end, I wrote a request filter that sets the input and output encodings to UTF-8, and I've used that successfully in the past. I've been able to avoid putting a page encoding directive in each page. With resin 4.0.30, I'm seeing something odd. I only get the right behavior if the JSP page as an extra %@ page % at the top somewhere. The actual directive inside doesn't seem to matter. I had an import directive, but tried it without one and still got the right behavior. I also have, before that, at %@ include directive, which must also be present. It includes the following: %@ page contentType=text/html; charset=UTF-8 % Without that, the resulting encoding isn't correct, either. What's odd is the empty page directive required to make it work. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
[Resin-interest] JSP encoding issues
I'm trying to serve everything UTF-8. To this end, I wrote a request filter that sets the input and output encodings to UTF-8, and I've used that successfully in the past. I've been able to avoid putting a page encoding directive in each page. With resin 4.0.30, I'm seeing something odd. I only get the right behavior if the JSP page as an extra %@ page % at the top somewhere. The actual directive inside doesn't seem to matter. I had an import directive, but tried it without one and still got the right behavior. I also have, before that, at %@ include directive, which must also be present. It includes the following: %@ page contentType=text/html; charset=UTF-8 % Without that, the resulting encoding isn't correct, either. What's odd is the empty page directive required to make it work. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] JSP encoding issues
Oh, I can also put that empty page directive at the end of my include file, and it also triggers the correct behavior. On Aug 27, 2012, at 16:39 , Rick Mann rm...@latencyzero.com wrote: I'm trying to serve everything UTF-8. To this end, I wrote a request filter that sets the input and output encodings to UTF-8, and I've used that successfully in the past. I've been able to avoid putting a page encoding directive in each page. With resin 4.0.30, I'm seeing something odd. I only get the right behavior if the JSP page as an extra %@ page % at the top somewhere. The actual directive inside doesn't seem to matter. I had an import directive, but tried it without one and still got the right behavior. I also have, before that, at %@ include directive, which must also be present. It includes the following: %@ page contentType=text/html; charset=UTF-8 % Without that, the resulting encoding isn't correct, either. What's odd is the empty page directive required to make it work. Any ideas? -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] app-default.xml?
On Aug 24, 2012, at 5:52 , Paul Cowan co...@caucho.com wrote: You'll also notice that we're importing app-default.xml from resin.jar with classpath:META-INF/caucho/app-default.xml by default, since it is not common or generally recommended to modify this file. However we still include app-default.xml in the conf directory and you can easily modify the import line to ${__DIR__}/admin-users.xml to use this file instead. Ah, okay. I always change the class loader to the tree-loader. I suppose I could just do that in my resin.xml. -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest
Re: [Resin-interest] Resin 4.0.30 is available
What's the state of PHP support in 4.0.30? On Aug 23, 2012, at 17:12 , Scott Ferguson f...@caucho.com wrote: Resin 4.0.30 is available for download at the usual: http://caucho.com/download Resin 4.0.30 is a release-candidate for 4.1.0. If no critical bugs are found after a few weeks, we'll promote it to 4.1.0. As a note, the most recent Resin 4.0.x releases beat nginx (a fast C-based web server) in stress tests using autobench. We've published the results at http://wiki4.caucho.com/NginX_1.2.0_versus_Resin_4.0.29_performance_tests -- Scott ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest -- Rick ___ resin-interest mailing list resin-interest@caucho.com http://maillist.caucho.com/mailman/listinfo/resin-interest