☰
-
Php 95
-
Java 94
-
Javascript 37
-
Regex 18
-
Git 17
-
Security 16
-
Docker 07
-
Python 58
-
Machine Learning 14
-
Book Highlights
Java
/
Spring Boot
- 1 Basics 9
-
Classes S
-
Objects S
-
Arrays S
-
Variables S
-
Loops S
-
Numbers S
-
Strings S
-
Exceptions S
-
Regexp S
- 2 OOP 9
-
Inheritance
-
Polymorphism
-
Static S
-
Abstract
-
Interfaces
-
Constructors S
-
Packages
-
Nested Classes
-
Final
- 3 Compiler 2
-
Sublime Text S
-
Apache Ant
- 4 Collections 8
-
Lists
-
Comparable S
-
Sets
-
Maps
-
Generics
-
Properties
-
Streams
-
Json
- 5 Threads 4
-
Create Thread S
-
Sleep
-
Lock
-
Scheduler
- 6 Design Patterns 4
-
Singleton
-
Observer
-
Strategy
-
Mediator
- 7 Swing 12
-
Frame
-
Panel
-
Listener
-
Combo Box
-
Label
-
Image
-
Menu
-
Table
-
Layout
-
Drawing
-
Timer
-
Designer
- 8 I/O 7
-
Streams IO
-
Socket
-
Watching Files
-
Mail
-
Logger
-
Clipboard
-
Encrypt S
- 9 Effective 7
-
Constructors S
-
Dependency Injection
-
Composition
-
Interfaces Default
-
Import Static S
-
Enums
-
Lambdas
- 10 Junit 5
-
About Junit S
-
Test Case
-
Suite Test
-
Annotations
-
Exceptions
- 11 Lambdas 7
-
Expressions S
-
Functional Interfaces
-
Streams
-
Common Operations
-
Default Methods
-
Static Methods S
-
Single Responsibility
- 12 JavaFX 6
-
Openjfx
-
Scene Builder
-
First App
-
Jar Archive
-
On Action
-
Change Listener
- 13 Maven 4
-
Demo
-
Spring Boot
-
Junit
-
Guava
- 14 Spring Boot 8
-
Quick start S
-
Rest service
-
Consuming Rest
-
Templates
-
Security
-
Command Line
-
Scheduling Tasks
-
Ajax
R
Q
SPRING CLI
Spring Boot CLI is a command line tool used to quickly develop a Spring application.
sudo mkdir /opt/spring-boot
sudo tar xzf spring-boot-cli-2.5.4-bin.tar.gz -C /opt/spring-boot/
sudo gedit /etc/profile
# export SPRING_HOME=/opt/spring-boot/spring-2.5.4
# export PATH=$SPRING_HOME/bin:$PATH
source /etc/profile
spring --version
# Spring CLI v2.5.4
Generate bcrypt passwords with encodepassword command.
spring encodepassword mypass
# {bcrypt}$2a$10$G7VG4tP1wgOfTtCnjVPYWO2V7/RXAkkMp9b4i7ZgEyRaEuMmPcodK
Compile and run Groovy source code with spring.
/**
* Standard Groovy includes a Grab annotation ...
* to declare dependencies.
*
* With RestController annotation ...
* Spring Boot grabs Tomcat and Spring Mvc.
*/
// ~java/SpringBoot/groovy/hello/App.groovy
@RestController
class App {
@RequestMapping("/")
String home() {
"Hello World"
}
}
spring run App.groovy # -- --server.port=9000
http://localhost:8080
# Hello World
Use jar coomand to package the application.
spring jar hello.jar *.groovy
java -jar hello.jar
Initialize a new project with init command.
spring init --dependencies=web,security myproject
cd myproject
./mvnw spring-boot:ron
http://localhost:8080
# Please sign in
➥ Questions
Last update: 508 days ago