0

While studying about spring-boot, I stumbled upon shell support (CRsh (boot v1.x) Spring-Shell (boot v2.x)).

What I am not able to understand is we already have a rich support for JMX which has been since ages, what value-add does these shells introduce?

I did try to find it online but could not get a concrete comparison.

Himanshu Bhardwaj
  • 4,038
  • 3
  • 17
  • 36
  • How is the explanation on https://projects.spring.io/spring-shell/ making you think it's anything like JMX? – kryger Aug 08 '18 at 08:33
  • Spring Shell and the CraSh support in Spring Boot 1 are totally different things. The latter was to allow shell access to your Spring Boot application and get, for instance metrics, while the first is for writing Shell based applications. – M. Deinum Aug 08 '18 at 08:37
  • @M.Deinum right! I thought it to be a replacement, reading again, I got my answer. So effectively there is no replacement for CraSh in spring-boot-2. – Himanshu Bhardwaj Aug 08 '18 at 08:42
  • Talking only about SpringBoot-1 now, @kryger If I see it from application support perspective, its still effectively the same. What I expose as MBean would be exposed as commands. But yes, shell based applications is a different paradigm altogether. – Himanshu Bhardwaj Aug 08 '18 at 08:43
  • No. [CrAsH](https://github.com/crashub/crash) has been a dormant project for years, which was the reason for dropping the support and as there isn't a replacement there is no shell support anymore. – M. Deinum Aug 08 '18 at 08:44
  • Cool that answers, thanks Guys!. – Himanshu Bhardwaj Aug 08 '18 at 08:49

1 Answers1

0

Spring Boot dropped support for CRaSH as it has been dormant for quite some time. This was for exposing metrics and controlling a live application from a CLI.

Spring Shell however is a framework to write CLI based applications, so basically a different beast and not comparable to the CRaSH support in Spring Boot 1.

As there is no replacement for CRaSH support in Spring Boot ended with the deprecation and removal. Although it was a nice feature the lack of support in the CRaSH project lead to the decision to drop the support.

Now you can probably shoehorn Spring Shell into a Spring Boot application and add features like CRaSH but that is not what Spring Shell was designed for.

M. Deinum
  • 115,695
  • 22
  • 220
  • 224