Tomcat also Blakeyrat reminding himself of old topics



  • Continuing the discussion from serving static content through Tomcat 7:

    @Jarry said:

    I have a spring application served through Tomcat 7. this application has a desktop counterpart.
    i didn't want to include the desktop binaries inside the war, so i asked google how to serve static content.

    google said: add this to your server.xml :

    <Host appBase="webapps">
        ...
        <Context docBase="/home/static/web" path="/static" />
      </Host>
    

    with a matching user and sftp access to update the binaries alone.

    well, that setup worked well until today. tomcat is giving me 404 errors on files i know the server has.
    and i have no fracking idea where to start looking.
    i've checked the logs, and they don't show anything...

    so, to resume.
    how do you troubleshoot tomcat?
    creating a new context is the way to go?

    Last time I had to work with Tomcat, I was especially impressed with how it seemed to have a completely non-deterministic deployment process.



  • Yeah, java had a good run, but php is still the king of web. Nothing comparable on the horizon.



  • @fbmac said:

    Yeah, java had a good run, but php is still the king of web.

    Java is firmly entrenched in enterprise's ass.


  • Grade A Premium Asshole

    @boomzilla said:

    Java is firmly entrenched in enterprise's ass.

    I would make a meme, but I don't think I could handle having a big hairy ass loaded up in Photoshop for the length of time it would take to make it.



  • Parp!


  • Grade A Premium Asshole

    @boomzilla said:

    Parp!

    Relevant (sort of):smile:



  • glad to see tomcat hasn't changed a bit since that...


  • Discourse touched me in a no-no place

    Would you want it to change much? It's not really end-user software; it's a service framework that people build things on.



  • well, I'm pretty sure i'm not using it 100% right.
    but i would like deploying a .war without fearing the whole server is going to crash.
    (seriously, if we don't bounce it between deploys, it breaks itself bad, really bad)

    if you want to tell me were to look how to use it, i'll gladly try to learn about (really, no sarcasm here).


  • Discourse touched me in a no-no place

    @Jarry said:

    but i would like deploying a .war without fearing the whole server is going to crash.

    I quite often used to bounce Tomcat after deploying a replacement WAR. This was because there was a reference leak in one of the libraries I was using (possibly related to using thread-local storage?) which was resulting in the classloaders for the old WAR not being GCed. I never quite figured out WTF was exactly going wrong, as the application in question was difficult to deploy in a debug config, and the memory dumps from a full deployment were intimidatingly large.

    I ought to try again sometime I guess. When I have a week free. (So, next decade?)


  • mod

    @dkf said:

    I quite often used to bounce Tomcat after deploying a replacement WAR.

    Did something change? When I was trying to learn tomcat, you had to reboot every time you changed any files on disk.



  • How do Java people cope with this? Their web server just plain don't work.


  • mod

    I use Java for desktop software only. Tomcat is awful.



  • Java is the answer to "how can we run arbitrary code from the internet on our computer without worrying about stack corruption".

    My answer to that question is "what the fuck are you doing where you need to run arbitrary code from the internet and stack corruption is the only thing you're worried about?"



  • @dkf said:

    This was because there was a reference leak in one of the libraries I was using (possibly related to using thread-local storage?) which was resulting in the classloaders for the old WAR not being GCed.

    Permgen leaks in JBoss hot deploys used to drive me nuts.



  • Is weblogic any better? The company I work use weblogic for their java things



  • I've never used it. JBoss4lyfe!

    That was back in 4.x days. We're on 7.x now. Also, permgen went away in Java 8, which I've been running personally to look for gotchas, but we're still technically on 7, so....



  • @fbmac said:

    Is weblogic any better? The company I work use weblogic for their java things

    We use Weblogic for one app... although we use a version so old it was made by BEA and only works with Java 1.4. It's hardly a fair comparison with Tomcat 8 which we run another app with Java 1.8 as they're years apart.
    Neither really cause problems mind.



  • @Yamikuronue said:

    I use Java for desktop software only.

    You are doing it wrong.

    Java's only fucking good for web software, where the fact that it's VM can't fucking draw a decent GUI to save its life isn't as much a handicap.


  • Discourse touched me in a no-no place

    @blakeyrat said:

    Java's only fucking good for web software, where the fact that it's VM can't fucking draw a decent GUI to save its life isn't as much a handicap.

    Java can do a decent GUI — I've seen it done — but it takes a lot of effort. It's nearly as bad as GTK, which I utterly despise for the sheer quantity of work it takes to make something not look like ass…

    @loopback0 said:

    only works with Java 1.4

    :doing_it_wrong: :wtf: That's sufficiently special to require those two together.



  • It's a 12 year old version supporting an app that's almost as old. It won't even boot Weblogic on a newer version of Java, let alone the app as well.

    We do have other apps running on current versions of Weblogic, just not that one.


  • Discourse touched me in a no-no place

    @loopback0 said:

    We do have other apps running on current versions of Weblogic, just not that one.

    So you've got code that's marooned in time?



  • @dkf said:

    Java can do a decent GUI — I've seen it done

    Lies. You were probably drugged.


  • Discourse touched me in a no-no place

    @blakeyrat said:

    Lies. You were probably drugged.

    Ignorance. You probably just don't know what you're talking about. (And no, I wouldn't ever choose to do a GUI in Java. I'm not that sort of crazy.)



  • I've had Java morons many times point out a Java app that had a "good GUI", it turned out in every case they were just completely incapable of judging what "good GUI" means.

    If you have a Java GUI which is good, put up or shut up.


  • Discourse touched me in a no-no place

    @blakeyrat said:

    If you have a Java GUI which is good, put up or shut up.

    I'm going to wait for you to come up with a fixed definition of what it means for an app to have a good GUI. I really don't want to spend time shooting for a moving target.



  • @blakeyrat said:

    I've had Java morons many times point out a Java app that had a "good GUI", it turned out in every case they were just completely incapable of judging what "good GUI" means.

    If you have a Java GUI which is good, put up or shut up.



  • he can't argue you didn't have an "idea"



  • Every single thing out there is better than PHP, except when you actually try to use it.



  • any language I google I found lovers and haters
    but when I test anything that has few people using I find serious problems with it

    the only good predictor of quality of a tool before testing in a project was the number of users, always


  • Discourse touched me in a no-no place

    @fbmac said:

    any language I google I found lovers and haters

    That'll be true until you get into the really obscure stuff, where nobody cares enough to bother with loving and hating. Number of successful projects is a reasonable indicator of whether the language is usable.


Log in to reply
 

Looks like your connection to What the Daily WTF? was lost, please wait while we try to reconnect.