Log files defined in logging profiles cannot be accessed by management interface in WildFly - wildfly

I have a WildFly 15.0.1 running in domain mode in a Docker container. It has two logging profiles configured - one for each application deployed on it. When I log in to the HAL Management Console via browser I can see all the logs and their file sizes, but I can only view and download the server.log one.
Trying to download one of the others results in:
"WFLYCTL0216: Management resource '[
(\"subsystem\" => \"logging\"),
(\"log-file\" => \"custom-log-file.log\")
]' not found"
which makes sense as in JBoss CLI those log files are not available directly under logging subsystem, but rather in logging profile details. Is there any way to make them available in the HAL Management Console?

AS #James R. Perkins suggested this behavior is a bug that was solved in HAL 3.0.17.Final. Since WildFly 15.0.1.Final contains HAL 3.0.6.Final and WildFly 16.0.0.Final contains HAL 3.1.2.Final, upgrading to WildFly 16 is one possible solution. The other is to upgrade just the HAL module in WildFly as described here.

Related

Does Keycloak stopped configuration with Wildfly after Keyclaok 17?

What is meaning of (https://www.keycloak.org/archive/downloads-17.0.1.html)
Keycloak: Distribution powered by Quarkus
Keycloak WildFly (deprecated): Distribution powered by WildFly
When i see documentation it says:
The default distribution of Keycloak is now powered by Quarkus, which brings a number
of breaking changes to you configure Keycloak and deploy custom providers.
For more information check out the Quarkus Migration Guide.
The WildFly distribution of Keycloak is now deprecated, with support ending June 2022.
We recommend migrating to the Quarkus distribution as soon as possible.
However, if you need to remain on the legacy WildFly distribution for some time,
there are some changes to consider
I am using Wildfly as application Server where projects are deployed.
Shall this means i use Wildfly distribution of Keycloak only whose support is ending June 2022.
or
Does this mean that Keycloak use Wildfly underneath and not use that anymore and quarkus is used? (now here can quarkus distribution work fine with wildfly settings we currently have)
Unfortunately, it has nothing to do with WildFly anymore. Until recent versions, the Keycloak was being packaged as a Java EE archive file (or as WildFly module) that you could deploy into WildFly application server.
Quarkus on the other hand is a framework to develop cloud native Java applications. It's runtime relies on many open source projects for underlying services (e.g. Vertx, SmallRye projects, etc.) and has a completely different architecture. As part of such a migration, Keycloak is now being packaged as an standalone java application (that is a typical output for an app developed using Quarkus) and contains all its dependencies. So there is no deployment/installation on WildFly anymore.
Quarkus applications are being designed by default to be run on cloud environments like Kubernetes. So you may also require to consider if you can benefit from this if you have such an infrastructure in your organization (however it's not mandatory and you can just run it as a normal java app on your server). But you can definitely not use your WildFly specific configurations (e.g. the Keycloak subsystem or OpenID subsystem) anymore.
You can find more details here.
Quarkus is a variation of Wildfly that is packaged in such a way as to make containerization (i.e. Docker, Kubernetes, etc.) much easier. Applications written for Wildfly (and JEE in general) can be made to run in Quarkus quickly.
Wildfy 25 and above include OIDC functionality internally. Therefore, you don't need to install the Keycloak extensions like you used to. And Keycloak, as of version 15, is based on Quarkus too. Because of this there is a build phase of the installation that lets you set many of the options before the run phase. For example, I used to setup a data source in the standalone.xml for my database. Now, I use the resources.properties to setup my database for Keycloak. The concepts are similar.
If you're using a version of Wildfly less than 25 then you'll still want the Keycloak adapter.

Wildfly and OIDC

We are a Java shop and use maven. Our app is on wildfly 18. Does anyone have any experiences on migrating a wildfly app to OIDC? We were given a security library that we can use to make OIDC calls to, but it requires a config file co-located with this library. Do we need to use a module for this? If so, do we need a particular section filled out in our standalone.xml?
You asked about Wildfly 18. This one for sure needs add-on modules, such as those provided by the keycloak project (https://www.keycloak.org/downloads).
Since Wildfly 25 the OpenID Connect functionality was added to the Wildfly releases, and since then the addon modules are no longer required. In fact, they should no longer get installed as they seem to break Wildfly.
See also
Secure WebApp in Wildfly 25 using OpenID Connect (OIDC) without installing a Keycloak client adapter
https://docs.wildfly.org/25/WildFly_Elytron_Security.html#validating-jwt-tokens
https://www.youtube.com/watch?v=2gQO4_7Z5CI

Can't Access ActiveMQ Web Console

I am having trouble accessing ActiveMQ's web console.
On their website it says you can access the console through the URL : localhost:8161/admin
But all I get when I try this is "This webpage is not available"
I found another site saying I can access it through port '61616', which gives me a response in the form of the following :
I have done some extensive searching on this issue, and have found others with the same problem, but have not come across a solution.
I am fairly new to using ActiveMQ so please excuse me if I have left out any relevant information.
Any help is greatly appreciated.
The admin console is a web application (WAR-file) deployed in an embedded Jetty server that starts up along with ActiveMQ standalone distribution.
Since you intend to run ActiveMQ inside a web application inside Tomcat, it would not make sense to fire up a jetty server.
Simply deploy the web console WAR to your Tomcat. You need to point out the JMS/OpenWire connection URI as well as JMX connection URI to ActiveMQ Web Console to get it going. Typically in Tomcat setenv.sh (or similar file):
JAVA_OPTS="$JAVA_OPTS -Dwebconsole.type=properties -Dwebconsole.jms.url=tcp://localhost:61616- Dwebconsole.jmx.url=service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi -Dwebconsole.jmx.user=admin -Dwebconsole.jmx.password=mypassw0rd"
This requires you to have JMX setup on your Tomcat instance. If not, check this Tomcat doc page out.
This will deploy the console just like any app in your Tomcat (not port 8161).
Off-topic, but a nice feature with decoupling the web console from the actual broker is that you can access a the activem broker of a master/slave pair using failover protocol and comma separated jmx settings.

Difference between jboss 6 and jboss 7 standalone server?

I was using Jboss 6 . I am wondering to see jboss 7 which does not have many folders that jboss 6 had. It will be helpful if someone explains the difference between the jboss 7 stand alone server and the previous versions.
AS7 is different in a lot of respects to its predecessors AS6,5. So it wont be possible to list down all the differences here.
to list supported technology related differences, refer to below table.
Some Major Differences: (Thanks for #Jyore for additions)
Modular (on-demand) class-loading
Addition of domain managed nodes (multiple JVM management)
All configuration is done in Standalone.xml for standalone mode and domain.xml for domain mode.
About the new DIRECTORY Structure
configuration : Configuration files for the standalone server that runs off of this installation. All configuration information for the running server is located here and is the single place for configuration modifications for the standalone server.
data :Persistent information written by the server to survive a restart of the server
deployments: End user deployment content can be placed in this directory for automatic detection and deployment of that content into the server's runtime.
NOTE: The server's management API is recommended for installing deployment content. File system based deployment scanning capabilities remain for developer convenience.
lib/ext : Location for installed library jars referenced by applications using the Extension-List mechanism
log : standalone server log files
tmp : location for temporary files written by the server
Apart from that I really dont want to duplicate information on web
There is a migration guide from AS5,AS6 to AS7. This can help you understand what are the config changes that are generally required to switch to AS7. it also points out what has significantly changed, highly recommend going through it.
Also You can read Getting Started with AS7, to know AS7 better

Can a deployed JBoss web application simply disappear?

A strange problem occurred yesterday on a production system which has been running fine for weeks on a JBoss 4.2.3 application server: the JAR file containing the web application was no longer in the deployment folder (so the clients could no longer access the application). The server is running on a Windows box.
There was no indication of undeployment in the server logs. Normally JBoss detects if somebody deletes (or moves) a deployed web application file and executes the standard undeployment procedure, so there would be a log entry in this case.
Other web applications on the same system continued to run fine, so it was only this JAR file which simply disappeared.
Has somebody seen a similar problem with web applications on JBoss?
I'd bet my shoes that's not possible to happen spontaneously.
Check your security settings - didn't you leave JMX console accessible? Etc.