Re: Need information

2018-07-23 Thread M. Manna
This is not relevant to tomcat. you have to read how to configure spring
application environment variables and classpath.
Below are some examples, which you can read and configure yourself.

https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html
https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#boot-features-external-config-application-property-files
https://stackoverflow.com/questions/41461786/how-to-externalize-application-properties-in-tomcat-webserver-for-spring

Thanks,

On Mon, 23 Jul 2018, 21:58 Francesco Viscomi,  wrote:

> Because I need to add a folder (properties) under the tomcat installation
> in order to read the properties in a file with the following annotation
> (using spring)
> @PropertySource("classpath:properties/application.properties");
>
>
>
>
>
> 2018-07-23 22:21 GMT+02:00 M. Manna :
>
> > You should never modify them, unless you know precisely what you're doing
> > it, and why.
> >
> > What ia your reason to modify them? What would you like to do?
> >
> > On Mon, 23 Jul 2018, 20:30 Francesco Viscomi, 
> wrote:
> >
> > > Sir Manna you're right, but at the moment I cannot go through debug;
> > > So if there is an explanation and why i should modify them, it will be
> > very
> > > important to me.
> > >
> > > thanks
> > >
> > > 2018-07-23 18:06 GMT+02:00 M. Manna :
> > >
> > > > http://tomcat.apache.org/tomcat-8.5-doc/class-loader-
> > > > howto.html#Class_Loader_Definitions
> > > >
> > > > Also, you should try and pay attention to Bootstrap.java file and
> debug
> > > > through the execution to understand how it's working.
> > > >
> > > >
> > > > On 23 July 2018 at 17:03, Francesco Viscomi 
> > wrote:
> > > >
> > > > > hi all
> > > > > In catalina.properties i find :
> > > > > common.loaders
> > > > > serverr.loaders
> > > > > shared.loaders
> > > > >
> > > > > And i wasn t able to find out the meaning of that variables, some
> one
> > > can
> > > > > tell to me and if possibile also a link to the documentation in
> wich
> > > > these
> > > > > variable are treated
> > > > >
> > > > >
> > > > > Thanks
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Ing. Viscomi Francesco
> > >
> >
>
>
>
> --
> Ing. Viscomi Francesco
>


Re: Need information

2018-07-23 Thread Francesco Viscomi
Hi Christopher,
indeed i need to have that file externaly from the war; I will not forget
to modify catalina.properties, because this operation will be done only one
time. So i need to adding tha resource in the classpath of tomcat.

2018-07-23 23:33 GMT+02:00 Christopher Schultz :

> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> Francesco,
>
> On 7/23/18 4:58 PM, Francesco Viscomi wrote:
> > Because I need to add a folder (properties) under the tomcat
> > installation in order to read the properties in a file with the
> > following annotation (using spring)
> > @PropertySource("classpath:properties/application.properties");
>
> Why not put that file under your application's
> WEB-INF/classes/properties/application.properties?
>
> Or, even better, add a  element to your application's
> META-INF/context.xml
>
> Changing the classpath by using those properties is probably the worst
> way you could accomplish what you are trying to do.
>
> Why is it bad? Because it's not portable, even across two separate
> Tomcat installations. If you forget to modify catalina.properties in
> the target of a move, stuff stops working. But if you bundle that file
> with your application, it will work no matter where you deploy it.
>
> - -chris
> -BEGIN PGP SIGNATURE-
> Comment: GPGTools - http://gpgtools.org
> Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
>
> iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWSbkACgkQHPApP6U8
> pFgNaQ//Yy8qmKzuzSigPRREWDxbs8yA35SSy8z68wvtxltEj9dWOteq83khisI1
> np0rJIErx+5kt+h7LzvpHh17AnqFgOBzo8R5/2+tTR3hS4xo42jQ9DnW+jgAZ7KX
> 9Klx0E9e+Jgu1FMWdCMLb3PR3RXWh0LpFW+QyJZ9S7FvEYZXZrtVcF42cLVH0Hi7
> cBOd3MxxSsn/9Bmd3R58sszNzCN2fvPSpZN7YIgD0bSju2DsgG+hibDb1OVW6idl
> cUS7J1jurCmoot25h0m1Y0bIOgr383lIAhvtJYF32g9qsVi/ocQx7O4BOh6xiViC
> hzQycE4Nv9w7KUMOXkdh6Tbg6Ycz7kgpG9NaCe00ARDMAG0jm4S1xAbEN59FEK+o
> CVUP+Ry2dAczy3e0nAfHpZ415ohR2x1/tqtNMfQrvaXPFmQ5Hv2U11ZbEXfFBDbM
> nTHm4wVdKpq/Stea3cC3YvvO/fMhuKhQW53iovgvP8Dwr7NKGXxsz43CLJE14Svd
> ir8cJpSqUddFjAPYDiwbXwO4H+WER57m6+2vFD7vhXXTnCJ/F45bm6Zyeoo1OweH
> bAt4+OncGXr7GRyo78oWTRK7ee2oqFPenCSM4o5yTPuA4COXhb5rKnaNquuXcXMr
> J96NiVecTiF79ugUcZhtTl/iyLpX4j/OZW5RFe4pOyyBc8H/klQ=
> =OdyE
> -END PGP SIGNATURE-
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>


-- 
Ing. Viscomi Francesco


Re: Need information

2018-07-23 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Francesco,

On 7/23/18 4:58 PM, Francesco Viscomi wrote:
> Because I need to add a folder (properties) under the tomcat 
> installation in order to read the properties in a file with the 
> following annotation (using spring) 
> @PropertySource("classpath:properties/application.properties");

Why not put that file under your application's
WEB-INF/classes/properties/application.properties?

Or, even better, add a  element to your application's
META-INF/context.xml

Changing the classpath by using those properties is probably the worst
way you could accomplish what you are trying to do.

Why is it bad? Because it's not portable, even across two separate
Tomcat installations. If you forget to modify catalina.properties in
the target of a move, stuff stops working. But if you bundle that file
with your application, it will work no matter where you deploy it.

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWSbkACgkQHPApP6U8
pFgNaQ//Yy8qmKzuzSigPRREWDxbs8yA35SSy8z68wvtxltEj9dWOteq83khisI1
np0rJIErx+5kt+h7LzvpHh17AnqFgOBzo8R5/2+tTR3hS4xo42jQ9DnW+jgAZ7KX
9Klx0E9e+Jgu1FMWdCMLb3PR3RXWh0LpFW+QyJZ9S7FvEYZXZrtVcF42cLVH0Hi7
cBOd3MxxSsn/9Bmd3R58sszNzCN2fvPSpZN7YIgD0bSju2DsgG+hibDb1OVW6idl
cUS7J1jurCmoot25h0m1Y0bIOgr383lIAhvtJYF32g9qsVi/ocQx7O4BOh6xiViC
hzQycE4Nv9w7KUMOXkdh6Tbg6Ycz7kgpG9NaCe00ARDMAG0jm4S1xAbEN59FEK+o
CVUP+Ry2dAczy3e0nAfHpZ415ohR2x1/tqtNMfQrvaXPFmQ5Hv2U11ZbEXfFBDbM
nTHm4wVdKpq/Stea3cC3YvvO/fMhuKhQW53iovgvP8Dwr7NKGXxsz43CLJE14Svd
ir8cJpSqUddFjAPYDiwbXwO4H+WER57m6+2vFD7vhXXTnCJ/F45bm6Zyeoo1OweH
bAt4+OncGXr7GRyo78oWTRK7ee2oqFPenCSM4o5yTPuA4COXhb5rKnaNquuXcXMr
J96NiVecTiF79ugUcZhtTl/iyLpX4j/OZW5RFe4pOyyBc8H/klQ=
=OdyE
-END PGP SIGNATURE-

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



Re: Need information

2018-07-23 Thread Francesco Viscomi
Because I need to add a folder (properties) under the tomcat installation
in order to read the properties in a file with the following annotation
(using spring)
@PropertySource("classpath:properties/application.properties");





2018-07-23 22:21 GMT+02:00 M. Manna :

> You should never modify them, unless you know precisely what you're doing
> it, and why.
>
> What ia your reason to modify them? What would you like to do?
>
> On Mon, 23 Jul 2018, 20:30 Francesco Viscomi,  wrote:
>
> > Sir Manna you're right, but at the moment I cannot go through debug;
> > So if there is an explanation and why i should modify them, it will be
> very
> > important to me.
> >
> > thanks
> >
> > 2018-07-23 18:06 GMT+02:00 M. Manna :
> >
> > > http://tomcat.apache.org/tomcat-8.5-doc/class-loader-
> > > howto.html#Class_Loader_Definitions
> > >
> > > Also, you should try and pay attention to Bootstrap.java file and debug
> > > through the execution to understand how it's working.
> > >
> > >
> > > On 23 July 2018 at 17:03, Francesco Viscomi 
> wrote:
> > >
> > > > hi all
> > > > In catalina.properties i find :
> > > > common.loaders
> > > > serverr.loaders
> > > > shared.loaders
> > > >
> > > > And i wasn t able to find out the meaning of that variables, some one
> > can
> > > > tell to me and if possibile also a link to the documentation in wich
> > > these
> > > > variable are treated
> > > >
> > > >
> > > > Thanks
> > > >
> > >
> >
> >
> >
> > --
> > Ing. Viscomi Francesco
> >
>



-- 
Ing. Viscomi Francesco


Re: Need information

2018-07-23 Thread M. Manna
You should never modify them, unless you know precisely what you're doing
it, and why.

What ia your reason to modify them? What would you like to do?

On Mon, 23 Jul 2018, 20:30 Francesco Viscomi,  wrote:

> Sir Manna you're right, but at the moment I cannot go through debug;
> So if there is an explanation and why i should modify them, it will be very
> important to me.
>
> thanks
>
> 2018-07-23 18:06 GMT+02:00 M. Manna :
>
> > http://tomcat.apache.org/tomcat-8.5-doc/class-loader-
> > howto.html#Class_Loader_Definitions
> >
> > Also, you should try and pay attention to Bootstrap.java file and debug
> > through the execution to understand how it's working.
> >
> >
> > On 23 July 2018 at 17:03, Francesco Viscomi  wrote:
> >
> > > hi all
> > > In catalina.properties i find :
> > > common.loaders
> > > serverr.loaders
> > > shared.loaders
> > >
> > > And i wasn t able to find out the meaning of that variables, some one
> can
> > > tell to me and if possibile also a link to the documentation in wich
> > these
> > > variable are treated
> > >
> > >
> > > Thanks
> > >
> >
>
>
>
> --
> Ing. Viscomi Francesco
>


Re: Need information

2018-07-23 Thread Francesco Viscomi
Sir Manna you're right, but at the moment I cannot go through debug;
So if there is an explanation and why i should modify them, it will be very
important to me.

thanks

2018-07-23 18:06 GMT+02:00 M. Manna :

> http://tomcat.apache.org/tomcat-8.5-doc/class-loader-
> howto.html#Class_Loader_Definitions
>
> Also, you should try and pay attention to Bootstrap.java file and debug
> through the execution to understand how it's working.
>
>
> On 23 July 2018 at 17:03, Francesco Viscomi  wrote:
>
> > hi all
> > In catalina.properties i find :
> > common.loaders
> > serverr.loaders
> > shared.loaders
> >
> > And i wasn t able to find out the meaning of that variables, some one can
> > tell to me and if possibile also a link to the documentation in wich
> these
> > variable are treated
> >
> >
> > Thanks
> >
>



-- 
Ing. Viscomi Francesco


Re: Changing Sever.xml without restarting Tomcat 8.5

2018-07-23 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Laurie,

On 7/23/18 12:25 PM, Laurie Miller-Cook wrote:
> Hi there,
> 
> I have an issue where we have multiple virtual hosts in separate 
> base directory's on a single Tomcat installation.  If I need to 
> change something within server.xml I need to restart Tomcat which 
> means I need to do this within an outage window as it affects all
> of the Websites, is there a way of reloading the server.xml without
>  restarting Tomcat?
> 
> As a bit of background we have a wildcard domain, so 
> ..com so we have created multiple webapp 
> directories with their own Manage and have multiple entries in the
>  server.xml file for the different hosts.
> 
> What need to be able to do is, for example, is add another host to
>  the xml site and get that to take effect automatically without the
>  need to restarting Tomcat as this restarts all the other websites 
> and hence gives outages to our customers.
> 
> Any help would be greatly appreciated.

Tomcat won't reload server.xml. It's just too complicated to determine
what has changed and how to perform an in-place reinit that only does
what is "necessary".

On the other hand, JMX is very powerful and you can make runtime changes
to Tomcat using that. Maybe you can consider performing two operations
whenever you need to add a virtual host:

1. Modify the conf/server.xml
2. Issue a JMX command to provision the new virtual host in the running
Tomcat

You might also want to consider having separate Tomcat instances per
domain. That might be more manageable, though it will require more
memory on your server(s).

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWH1YACgkQHPApP6U8
pFif+xAAqBJLoPub6ZsICJGVp5N87IYUlhcsFXEULLkomOkDCHGROea91uhUOdu+
a9JRZbC6tQQmhopqGNb5HkZrkNvkPBT13/71TDB7faGzwLXOv1/V0dRPO7KscgTq
PikAuyXhSNyfOYorv7xKq2MwUdT86dAovukf8ClEDE1mX/7CgtE/MjW64eQcTc59
HNB8CilW8bAs3ApZso1EQEaUYoE7EkCtyWlnEFAtbbPsgzDD3CTpp4iqiVDGXkYD
LsXUvLM8DtVdslzLztX5rRRxDaPsYXd8g9IOfi4yLqOMeOeO0FogBc6VpuC1d7gD
TOeQARm0k2Xf/RbUKbAbD1gV/8xFPI4bKtSJINSD/A5o1Qpvv/rtVz0pQYJA8fgb
u8v485wpmEFSDN+tE9MXE6YQ6HBJRtGQJ8j2xhhqU+iTbXonYX+BbxW9sqhXvvua
5i6cMjuWBuu49HYreaVHdV9N2kfxEJ2wLzVKXE3BEsWnVGYJEFHYizqS3yNyj9qv
cDw1Pc5jfYdfzFkn8oXZe1t1fHXRcxTN6XpwBKzmHxEkwCh+cvwwkZ10zaEjphs1
22X6xsi88e0ng/xdoQPKb+CPNq/13VYS0l1jlAcMc8DPeocSonMv20Y9pySep80h
YioelFbIrdjH7teVKoR9GoR2f/vA22D7UV600GOi2nXiWVWkn2Y=
=hB5A
-END PGP SIGNATURE-

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



Re: Tomcat 5.5.17 migration to 6.0.53

2018-07-23 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

David,

On 7/23/18 12:51 PM, David Babooram wrote:
> Hello
> 
> I have begun a migration from 5.5 to 6. Yes I know 6 is EOL but
> the migration from 5.5 to 6 has some more documentation compared to
> 5.5 to the latest version.
> 
> I followed the standard migration of libs and classes from /common 
> /shared etc to the new /lin directory for 6..
> 
> The server engine runs and I can see the examples web pages come
> up.
> 
> When I migrated my production webapps to the 6.0 instance however
> I get the following error.
> 
> HTTP Status 500 - java.lang.LinkageError: loader constraint 
> violation: when resolving interface method 
> "javax.servlet.jsp.JspApplicationContext.getExpressionFactory()Ljavax/
el/ExpressionFactory;"
>
> 
the class loader (instance of org/apache/jasper/servlet/JasperLoader)
> of the current class, org/apache/jsp/index_jsp, and the class
> loader (instance of org/apache/catalina/loader/StandardClassLoader)
> for resolved class, javax/servlet/jsp/JspApplicationContext, have 
> different Class objects for the type javax/el/ExpressionFactory
> used in the signature
> 
> Any insight on this is welcomed.
> 
> I notice in that my app has its own lib directory, does this means 
> that there is a conflict with the lib files from the base
> directory ?

Possibly. What files do you have in your app's WEB-INF/lib directory?

- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWHmYACgkQHPApP6U8
pFi4ow//e1d8mPY8X7K2X1h2X9Maim12GIbKAv0OrvthWMWYMIt6POTrxRepJLg6
BxgQ2Duabf2wCmZhGRRcBotc7++Niyyh3bHPwy11UfsHXkLPQlE1bnfprgYsUI+5
JRUf4ZHLQ+HCXTn3R54U5Z+a6U4ucSotPt2FwpslIGH2lZFrjSjM+lELagNIJvvU
gysavLRPZIQSCvDfPw1MeDbmtPalbVlq0XvS4d4szvWJy0oNzF1mRG4u6KWniisz
t0ULSmp/2virBNPmQ9SdeoG23avPtfxVOY2BbP1O5IAjKSfhPV+UNhvu48ufq5gj
gVYGVf5edxZy241ApGZHZoSSfl5LEiN1vJpIsF1a8HcqffhBTJTwtDzhscQDVxw9
89iiwTGEp5VtugI8vqMNI1hO9b0ESJhAfsCuMwvEvL2sivWWROXRzExsFiSFe0x2
K9tpqXBonXZ+4y+xwQdBoaDcRRjKhUW9rP5CbkNvDOfpttsnyD6c7ff1t/9K3vr/
FnBFCqo0qDRdSLckbtmU5C6/yHUjQiFtMXbMtnEVXwnk3zo0ICJnvxvTINp346nq
EiYAMcZF+RemlO3+0whK+B7BKgF9L4baqvQmglJaIEVY2D6w4SmW/xCO55a4V2c4
gRD9xNP6u7M/dlFGs+VaJvdwkh4wNxj319vxYsZ2O2KsdmDdvUw=
=YuGP
-END PGP SIGNATURE-

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



Re: [mod_jk] No data for "LE" (last error timestamp) column in lb status

2018-07-23 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Rainer,

On 7/23/18 6:01 AM, Rainer Jung wrote:
> Hi Chris,
> 
> Am 20.07.2018 um 16:29 schrieb Christopher Schultz:
>> -BEGIN PGP SIGNED MESSAGE- Hash: SHA256
>> 
>> All,
>> 
>> I've got a lb worker with two balanced nodes. One of the nodes
>> has a non-zero value for the "Err" (errors) field, but there is a
>> blank entry for the "LE" (last error timestamp) field.
>> 
>> I'm using mod_jk 1.2.41 on x86-64 Linux.
>> 
>> The whole XML record (with some things redacted is here):
>> 
>> > port="7115" address="127.0.0.1:port" source="undefined" 
>> connection_pool_timeout="60" ping_timeout="1"
>> connect_timeout="0" prepost_timeout="0" reply_timeout="0"
>> connection_ping_interval="0" retries="2" recovery_options="0"
>> busy_limit="0" max_packet_size="8192" activation="ACT"
>> lbfactor="1" route="my-node" redirect="" domain="" distance="0"
>> state="OK" lbmult="1" lbvalue="192" elected="323181" 
>> sessions="13277" errors="21" client_errors="2"
>> reply_timeouts="0" transferred="322498984" read="1805149172"
>> busy="0" max_busy="222" connected="26" max_connected="222"
>> time_to_recover_min="0" time_to_recover_max="0"
>> last_reset_at="1531625678" last_reset_ago="470720"/>
>> 
>> I don't see any information about the "last error timestamp" in
>> the raw data. Does this field actually exist?
> 
> At least there is code in jk_status.c to handle it. And if it is
> empty in the HTML view, the same condition will drop it from the
> other views.
> 
> But it works different for a rway AJP worker and an lb member:
> 
> - raw AJP worker (not in an lb):
> 
> The underlying field is a "volatile time_t error_time" defined in 
> jk_shm.h as part of the struct jk_shm_ajp_worker.
> 
> It gets set in jk_ajp_common.c to time(NULL) whenever either an
> AJP worker goes into error state or its busy count is above the
> limit. The field never gets reset.
> 
> It is used in jk_status.c to print the LE column and also for XML
> and properties output.
> 
> 
> - AJP worker as a member in an lb:
> 
> The underlying field is a "volatile time_t first_error_time"
> defined in jk_shm.h as part of the struct jk_shm_lb_sub_worker.
> 
> It gets set in jk_ajp_common.c to time(NULL) whenever either an
> AJP worker goes into error state or its busy count is above the
> limit. The field gets reset when a worker leaves the error state
> (probably the case in your situation) and when you reset the worker
> statistics via the status worker. The fields can get set before the
> worker goes into error, namely if error_escalation_time allows to
> ignore errors for some time before setting an erred worker into
> error state.
> 
> All in all I would say the filed is less useful for lb members than
> for raw AJP workers.

Agreed.

I was expecting this field to be the "time the last error was
encountered" and instead it means the "time the worker last went into
an error state" which is a much bigger issue.

I was going to use this for a monitoring alarm but instead I'll use a
delta on the CE field value.

Thanks,
- -chris
-BEGIN PGP SIGNATURE-
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAltWHbcACgkQHPApP6U8
pFjHKw/+Ln4oLJZFlfqvk9rSyQDpDluMUg6r8mZOkCaJX5r4I79k2xHDajLhP5KD
cgn/toy6OwcKI/ykzj0fd20j5UHbDtA2+sDVLEWW2SyGjch23g35CfgsDurHNy/q
HmHyncmrKexi3SEwOH7VtEqsrQUHsAm7ziDqXTQWpWuxookreQak95yBycq3Sk6k
BGvorTSb8HjA9js+79/J+0pE2dRusTJxTRpUH4A07d1DAjJknVEUFQ0axDmn29nC
uoJm5Z3Uxg6lBllzMRXW/5/fvhSmN9gl3CKrraOSTRMmwkH7ge5Qj3uudF1DW8Fi
Q/hbd0DLR0QpSwNh4tlphhS56vIioy9A/03C7Lfp49DbaHcxakTWS+OlBLPUad8a
0G2fwQps63T/K8oJckSDdQ6DUMOmFZTHBbzmm8lNL4TNI/kV1cAhzx4H7fk126ck
DpJANm+N2nYIaz0f7YqWnQPlv/Rel9BUZGLCllSfRWxk/h/BUckO6JnBOAPvft5D
cvRPigD9x9KlyrOk+Am2Bd2zYXgGqJCy8m/cHY+QU8+8KHv6LLDrNGJp1PHZZZ2Z
kKqQ8yR0ZdsBdsvuJTs5oQzLagWLGPIAO0sZdFUQcxpl95rJmEPv27sem7KBb5n4
vInho6uivdV2GvO7tkOdCV22FPbEYIkkRF4zuRfxI0ohPrkYnh8=
=QgpC
-END PGP SIGNATURE-

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



Re: Changing Sever.xml without restarting Tomcat 8.5

2018-07-23 Thread Dave Fisher
Hi -

This is the way that Tomcat is. You should think about your configuration. In 
these days of cheap VMs why are you overloading so many web apps onto a single 
server? Are you able to create a farm of servers? In other words have two or 
more? If so then you have a frontend load balancer of some kind managing where 
requests go. If you do then you should carefully shutdown and restart each 
server one at a time.

(I started following this type of approach since Tomcat 3.3 on multiple top 
level domains.)

Regards,
Dave

> On Jul 23, 2018, at 9:57 AM, M. Manna  wrote:
> 
> I am not sure if it's possible, and probably for a valid reasons.
> Server.xml is the mother of server container config and messing things up
> there means your servlet context/listeners etc. may need to be
> reconfigured. Without a heavily customised/rewritten version of tomcat
> config change listener, you cannot do it.
> 
> Also check this - conf/server.xml file cannot be reloaded without
> restarting Tomcat.
> 
> 
> By all means, confirm this by your research.
> 
> On 23 July 2018 at 17:25, Laurie Miller-Cook <
> laurie.miller-c...@larmerbrown.com> wrote:
> 
>> Hi there,
>> 
>> I have an issue where we have multiple virtual hosts in separate base
>> directory's on a single Tomcat installation.  If I need to change something
>> within server.xml I need to restart Tomcat which means I need to do this
>> within an outage window as it affects all of the Websites, is there a way
>> of reloading the server.xml without restarting Tomcat?
>> 
>> As a bit of background we have a wildcard domain, so
>> ..com so we have created multiple webapp directories
>> with their own Manage and have multiple entries in the server.xml file for
>> the different hosts.
>> 
>> What need to be able to do is, for example, is add another host to the xml
>> site and get that to take effect automatically without the need to
>> restarting Tomcat as this restarts all the other websites and hence gives
>> outages to our customers.
>> 
>> Any help would be greatly appreciated.
>> 
>> All the best
>> 
>> Laurie
>> 



signature.asc
Description: Message signed with OpenPGP


Re: Changing Sever.xml without restarting Tomcat 8.5

2018-07-23 Thread M. Manna
I am not sure if it's possible, and probably for a valid reasons.
Server.xml is the mother of server container config and messing things up
there means your servlet context/listeners etc. may need to be
reconfigured. Without a heavily customised/rewritten version of tomcat
config change listener, you cannot do it.

Also check this - conf/server.xml file cannot be reloaded without
restarting Tomcat.


By all means, confirm this by your research.

On 23 July 2018 at 17:25, Laurie Miller-Cook <
laurie.miller-c...@larmerbrown.com> wrote:

> Hi there,
>
> I have an issue where we have multiple virtual hosts in separate base
> directory's on a single Tomcat installation.  If I need to change something
> within server.xml I need to restart Tomcat which means I need to do this
> within an outage window as it affects all of the Websites, is there a way
> of reloading the server.xml without restarting Tomcat?
>
> As a bit of background we have a wildcard domain, so
> ..com so we have created multiple webapp directories
> with their own Manage and have multiple entries in the server.xml file for
> the different hosts.
>
> What need to be able to do is, for example, is add another host to the xml
> site and get that to take effect automatically without the need to
> restarting Tomcat as this restarts all the other websites and hence gives
> outages to our customers.
>
> Any help would be greatly appreciated.
>
> All the best
>
> Laurie
>


Tomcat 5.5.17 migration to 6.0.53

2018-07-23 Thread David Babooram
Hello

I have begun a migration from 5.5 to 6. Yes I know 6 is EOL but the migration 
from 5.5 to 6 has some more documentation compared to 5.5 to the latest version.

I followed the standard migration of libs and classes from /common /shared etc 
to the new /lin directory for 6..

The server engine runs and I can see the examples web pages come up.

When I migrated my production webapps to the 6.0 instance however I get the 
following error.

HTTP Status 500 - java.lang.LinkageError: loader constraint violation: when 
resolving interface method 
"javax.servlet.jsp.JspApplicationContext.getExpressionFactory()Ljavax/el/ExpressionFactory;"
 the class loader (instance of org/apache/jasper/servlet/JasperLoader) of the 
current class, org/apache/jsp/index_jsp, and the class loader (instance of 
org/apache/catalina/loader/StandardClassLoader) for resolved class, 
javax/servlet/jsp/JspApplicationContext, have different Class objects for the 
type javax/el/ExpressionFactory used in the signature

Any insight on this is welcomed..

I notice in that my app has its own lib directory, does this means that there 
is a conflict with the lib files from the base directory ?






Notice of Confidentiality:

The information contained in this communication is intended solely for the use 
of the individual or entity to whom it is addressed and others authorized to 
receive it. It may contain confidential or legally privileged information. If 
you are not the intended recipient you are hereby notified that any disclosure, 
copying, distribution or taking any action in reliance on the contents of this 
information is strictly prohibited and may be unlawful. If you have received 
this communication in error, please notify us immediately by responding to this 
email and then delete it from your system.


Changing Sever.xml without restarting Tomcat 8.5

2018-07-23 Thread Laurie Miller-Cook
Hi there,

I have an issue where we have multiple virtual hosts in separate base 
directory's on a single Tomcat installation.  If I need to change something 
within server.xml I need to restart Tomcat which means I need to do this within 
an outage window as it affects all of the Websites, is there a way of reloading 
the server.xml without restarting Tomcat?

As a bit of background we have a wildcard domain, so ..com 
so we have created multiple webapp directories with their own Manage and have 
multiple entries in the server.xml file for the different hosts.

What need to be able to do is, for example, is add another host to the xml site 
and get that to take effect automatically without the need to restarting Tomcat 
as this restarts all the other websites and hence gives outages to our 
customers.

Any help would be greatly appreciated.

All the best

Laurie


Re: Need information

2018-07-23 Thread M. Manna
http://tomcat.apache.org/tomcat-8.5-doc/class-loader-howto.html#Class_Loader_Definitions

Also, you should try and pay attention to Bootstrap.java file and debug
through the execution to understand how it's working.


On 23 July 2018 at 17:03, Francesco Viscomi  wrote:

> hi all
> In catalina.properties i find :
> common.loaders
> serverr.loaders
> shared.loaders
>
> And i wasn t able to find out the meaning of that variables, some one can
> tell to me and if possibile also a link to the documentation in wich these
> variable are treated
>
>
> Thanks
>


Need information

2018-07-23 Thread Francesco Viscomi
hi all
In catalina.properties i find :
common.loaders
serverr.loaders
shared.loaders

And i wasn t able to find out the meaning of that variables, some one can
tell to me and if possibile also a link to the documentation in wich these
variable are treated


Thanks


Re: [mod_jk] No data for "LE" (last error timestamp) column in lb status

2018-07-23 Thread Rainer Jung

Hi Chris,

Am 20.07.2018 um 16:29 schrieb Christopher Schultz:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

All,

I've got a lb worker with two balanced nodes. One of the nodes has a
non-zero value for the "Err" (errors) field, but there is a blank
entry for the "LE" (last error timestamp) field.

I'm using mod_jk 1.2.41 on x86-64 Linux.

The whole XML record (with some things redacted is here):



I don't see any information about the "last error timestamp" in the
raw data. Does this field actually exist?


At least there is code in jk_status.c to handle it. And if it is empty 
in the HTML view, the same condition will drop it from the other views.


But it works different for a rway AJP worker and an lb member:

- raw AJP worker (not in an lb):

The underlying field is a "volatile time_t error_time" defined in 
jk_shm.h as part of the struct jk_shm_ajp_worker.


It gets set in jk_ajp_common.c to time(NULL) whenever either an AJP 
worker goes into error state or its busy count is above the limit. The 
field never gets reset.


It is used in jk_status.c to print the LE column and also for XML and 
properties output.



- AJP worker as a member in an lb:

The underlying field is a "volatile time_t first_error_time" defined in 
jk_shm.h as part of the struct jk_shm_lb_sub_worker.


It gets set in jk_ajp_common.c to time(NULL) whenever either an AJP 
worker goes into error state or its busy count is above the limit. The 
field gets reset when a worker leaves the error state (probably the case 
in your situation) and when you reset the worker statistics via the 
status worker. The fields can get set before the worker goes into error, 
namely if error_escalation_time allows to ignore errors for some time 
before setting an erred worker into error state.


All in all I would say the filed is less useful for lb members than for 
raw AJP workers.


Regards,

Rainer

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