Users in hawt.io in an standalone java app - hawtio

I would like to know how can I have users for hawt.io when using it in an standalone java app. I believe that you need to define a realm like containers do, but is there any guide or easy way to do this? I just want to protect my hawt.io instance with user and password.

You can use Jetty or Tomcat as the embedded web server to run hawtio standalone. Then you can use their security out of the box. And its just like securing any other WAR web application, eg setup their realm, and setup web.xml stuff.
For example this is done in the Apache ActiveMQ distribution which has an embedded Jetty server for the web consoles and WebSocket support.

Related

Configure WebLogic application/Web Application to not use MOXy for JAXB

My company has a Web Application that uses the JAXB provider in the JDK
The application runs great in Tomcat.
We have a customer that want to to use WebLogic
The application fails when trying to create a JAXBContext.
This page https://docs.oracle.com/cd/E24329_01/web.1211/e24964/data_types.htm#WSGET347
documents how to configure a WebLogic application to not use MOXy for JAXB
When I use the "Global" solution, modifying the startup script to prepend modules/databinding.override.jar to the classpath, my Web App works fine
This is a rather large hammer as the customer has existing apps on an existing server and we are targeting that server.
When I try the Application level solution, no luck.
Any pointers as to where I going wrong?
Eclipse Workbench

How to monitor Wildfly with Nagios?

I've read that it's possible to monitor Wildfly with Nagios in links like this one and I also know that there are solutions that provide that service as well.
Does anybody knows how to do that, how to monitor Wildfly with Nagios, any recommendations on how to start? Any reference would be very appreciated.
You can consider using JSON based HTTP management API. Sample plugin (Python based) for JBossAS - standalone mode is available here https://github.com/aparnachaudhary/nagios-plugin-jbossas7. This should also work for WildFly.
Some details about WildFly HTTP Management API can be found here https://docs.jboss.org/author/display/WFLY9/The+HTTP+management+API

What web server do you recommend?

For work, I need a free web server system to host a few web apps that I will develop. The server will be installed on Windows. The apps will need to be able to access a bunch of files on the intranet, and massage them. Mostly 10 people at same time will be using the apps. I would prefer to write code in .NET as it contains many great APIs, but I am not sure if the latest IIS Express has any major restrictions (number of clients connected to web server or database, etc.).
The other web servers I looked at (which are not .NET) are:
glassfish - seems that many are switching from it since Oracle stopped supporting it
wamp servers - there are many, the other day I installed wampserver and wrote an app in PHP to see how good it is. I must say PHP was very slow accessing my intranet files and processing them.
oracle weblogic server - never used it and have no idea how good it is
tomee - seems to be new and I do not know how good it is for web application development
I am wondering what do you recommend?
Thank you
first of all I very invested in TomEE. That here here is my feedback:
weblo, TomEE and GlassFish are java servers where wamp is a php/httpd one. Depending what you target it can be enough to make a choice (investment for java is more important than php).
If you choose java then weblogic is not free AFAIK.
Then TomEE is very close to TomEE giving you just all the power you need for web development so it is a safe choice (you'll benefit from a lot of integration and tools for free).
GlassFish is not bad by itself and the best way to select one server is to test it with a small app in your environment IMO.

Accessing application on websphere through iPlanet web server

I have an application that is running when directed hit using websphere application server(using the default port of the app server). What I want is that the application should be accessed using the iPlanet web server available.
I need to know the changes to be made to config files of the web server or app server concerned. Also do I need to make changes in obj.conf config file of iPlanet Web Server.
If you look at
WAS Software Requirements page
it refers to Sun Java System Web Server and I'm not sure that it match iPlanet product.
If it is supported you could administer it as other web server see: Administering web servers from the administrative console
Otherwise, it could be quite quite difficult to use iPlanet as HTTP Server.
In fact, you can configure iPlanet to behave as a Reverse Proxy to route some HTTP requests (e.g. /yourapp/*) to WAS but you need to add a configuration for each app.
Moreover, if you have a WAS cluster, you will lose session affinity that is a capability of HTTP plugin provided by WAS: Configuring simple load balancing across multiple application server profiles.
I suggest you to use Web Server supported by WAS like IBM HTTP Server (the license is included in WAS)

Tomcat authentication configured inside the war

I have to deploy a war to a tomcat but I cannot modify anything outside the war itself.
Now I need to add authentication and authorization to the application.
The basic authentication would be enough but I cannot edit the tomcat-user.xml file, nor I can depend on absoulute paths as suggestend here: How do I provide basic http authentication for static tomcat webapps without changing tomcat-users.xml?
I just need to use a single user/password that can be configured in a file inside the war (it's a simple application with short lifetime and really low security requirements).
What is the simplest way to do this?
Thanks
Andrea
I seems that a solution is to use spring security with basic authentication.
See: Spring Security HTTP Basic Authentication
In my original case I didn't want to include spring security but I still don't know any other way to obtain this result.

Resources