Liferay 6.2 GA4 portal-log4j-ext.xml reload interval? - log4j

Does anybody know what Liferay's reload interval is for portal-log4j-ext.xml and if there is none how to configure one? My goal is to change the log level for certain packages from e.g. WARN to DEBUG without bouncing the server.

I'm not aware of a reload interval. But you can go to Control Panel / Server Administration. There's a tab containing Log levels and you can change the existing ones or introduce new ones. They'll be active immediately.
Caution: Upon restarting the server, the settings are lost (by design) and you'll start over with the file-based logging configuration. But as restarting is not an option for you, this should solve your problem. Of course you're still free to edit the file so that your settings will become active by default on restart.

Related

How long does IIS keep site logs by default?

Recently, I've noticed that the retention appears to be pretty long for most IIS servers I've worked with.
What is the default retention/how do I check it?
The log retention appears to be version specific, but at least for IIS 6.2+ it appears that the retention by default is indefinite.
You can check the log default settings for the entire server by going to:
inetmgr -> SERVERNAME -> Logging
Here you can set logging styles, but there doesn't appear to be an "archive/cleanup" option, so likely if you want to actually delete these logs on a regular basis, a task will need to be created

Conditional proxy settings in gradle.properties

I use Android Studio and gradle in my office using a authenticated corporate proxy. This unfortunately means that I have to enter my proxy config including user/pass in cleartext in gradle.properties (or have it automatically propagated from Android Studio's preferences).
However, sometimes I work outside of the office, and I then have to manually go in and comment out my proxy settings each time, which is tedious.
Is there a way to make properties in a gradle file conditional so that the proxy configuration can be automatically activated by detecting if I'm on my corporate network or not? The condition itself could in turn be retrieved either by querying the network adapter for the current network, or perhaps better, by making a simple curl to a known host on my corporate network.
I'm using both Windows and Ubuntu clients but this question mostly applies to Windows.
There might be other ways to solve this I guess, perhaps changing the global gradle settings rather than the project specific ones. To be honest, I have to do a similar git config --add http.proxy, and the same for npm, bower and what not, everytime I change working environments. Other suggestions are welcome even though this question specifically asks how to create a gradle.properties which tries to connect to a known intranet host, and depending on the outcome sets or unsets properties.
I have had the same problem for a while. There was an additional problem for me that gradle.properties are checked in to our VCS with a proxy setting; and I had to take extra steps before all my commits to ignore the changes I did in that file. Additionally, I had to comment/uncomment the same piece of code multiple times in a day.
I could not come up with a conditional update system, but the second problem was resolved by inbuilt shelving functionality in Android Studio and creating changelists to keep 2 copies of the file with different settings.
I don't think there is any way to solve this problem the way you are asking for. For a simple reason: .properties files are not meant to have logic. To quote the Java docs:
Properties are configuration values managed as key/value pairs.
The dynamic settings can be achieved either via Android Studio proxy settings or writing a Gradle task that runs on project load, checks network conditions and sets system properties. I haven't tested this approach, but I think this will also update the gradle.properties file (a side-effect that you may not want). But what is being done by Gradle can also be done via a shell script that you need to execute on project load.
The way I am currently handling proxy update is by entering/saving the proxy settings in Android Studio itself, and toggling when I move between locations. It just takes a couple of commands to bring up the proxy dialog and enable/disable the saved proxy.
Since this proxy file is saved in idea.config.path/options/proxy.settings.xml, you could also try writing a shell script that can toggle the contents based on network availability.
This may not be what you were looking for, but I hope it clears up why it can't be done the way you asked for.

ModX revo Missing System Settings after restoring on localhost

Basically took a backup from server and restored it on my machine. Everything seems to be displaying correctly. But when I go to my System Settings, there are missing settings. But when I check modx_system_settings, they're there. Also cleared cache multiple times, so that's not the issue it seems.
Any ideas?
Thanks!
there is a cache_system_settings and cache_context_settings... though if you have cleared cache multiple times. actually delete the files to verify. Is it possible that you have context settings that would be overriding system settings? It would be helpful to tell us what settings are "missing"
Are you sure that the you crosschecked the same database tables? Is the table modx_system_settings the same table that MODX installation has in use?
Another possibility could be a not writable cache file in core/cache/system_settings or core/cache/context_settings.
Found the answer for my case. Basically it was server related. Live server is using linux, so when I set it up on my local which is wondows based, I had to search systems settings in DB for "locale" and update the value to English. That fixed my system settings. Everything showing now.

Sitecore template items reset after IIS restart / application pool recycle

I have a uCommerce package installed for my sitecore. The problem exists when you start editing template items under sitecore/templates/User Defined/uCommerce definitions/. When you restart IIS or recycle application pool (apparently this happens after solution rebuild) the template items reset their values to the fixed one. What could be causing the problem? Is there any cache mechanism which could be causing this?
update: have checked the sitecore database, the field values are being saved and stored in database properly after iis reset/pool recycly, so there is pretty much confidence that it has to do something with caching
The UCommerce DataProvider (UCommerce.Sitecore.SitecoreDataProvider.DataProviderMasterDatabase) automatically adds the templates under sitecore/templates/User Defined/uCommerce definitions at start up so they will always be reset after each recycle.
First off, make sure that you are making your changes in the Master database and not the Web database. If that is not the issue, then try the following while logged into Sitecore as an administrator:
Go to http://yourdomain.com/sitecore/admin/cache.aspx
Clear the Sitecore cache
Go to the Master database's content editor and look at your templates
Make any changes necessary, save and publish
Do your IIS restart / application pool recycle (the latter occurs on every build)
Go back to http://yourdomain.com/sitecore/admin/cache.aspx
Clear the cache again (just a base-case)
Go back to the Master database's content editor and look at your templates again
If the issue occurs after trying those steps, then you should open a Sitecore support ticket and see what they say. You may also want to try making a clean install of Sitecore and trying to reproduce the issue there (Sitecore Support is likely to do this as well).
The problem was that the standard values template presentation layout I have been updating was the english version. However, there was another language version set and the layout for that version was different. When uCommerce is resetting the template on application pool recycle it doesn't take into the account the multilanguage support, so the last retrieved language version of that fieldvalue is used as reset template and that different language version with different layout was used. A partial workaround is to use the same layout for all the language versions.

Drupal doesn't save any changes in admin settings

I have a strange problem in drupal. When I'm trying to change _any_ setting in the drupal admin (caching under performance, temp-directory under file-system, default filter under filters, etc) I get the message that the changes were saved successful, but the values don't change.
I don't know where to start debugging since this is such a widespread problem. I've checked rights of all files/folder and the database connection. Seems fine.
Anyone experienced such a problem before?
edit: There isn't a single error entry in the drupal log file.
edit 2: I just deactivated every single contrib module. Still I can't make any changes to (for example) the caching mode.
Clear the cache in application and check again .. You can find it from
Drupal 7: Administration > Configuration > Development > Performance (admin/config/development/performance)
Drupal 6: Administer > Site configuration > Performance (admin/settings/performance)
Click “Clear cached data” button below

Resources