This project showcases a video streaming application built with Spring Boot. It enables users to stream video content from a server directly to their web browser, providing a simple yet effective way to deliver video streams over the internet.
- Video Streaming: Stream video content to clients with support for range requests.
- Spring Boot Integration: Utilizes Spring Boot for easy setup and configuration.
- Resource Handling: Serves static resources and video files efficiently.
- Java 17
- Maven
-
Clone the repository:
git clone https://github.com/yourusername/videostream.git
-
Navigate to the project directory:
cd videostream
-
Build the project:
./mvnw clean install
-
Run the application:
./mvnw spring-boot:run
-
Open your browser and navigate to http://localhost:8080 to access the video streaming application.
The application can be configured using the application.properties
file located in /resources
directory.
# Spring Boot Application Configuration
spring.application.name=videostream
video.file-path=src/main/resources/video/sample.mp4
server.port=8080
# Async Task Executor thread config
spring.task.execution.pool.core-size=10
spring.task.execution.pool.max-size=20
spring.task.execution.pool.queue-capacity=50
spring.task.execution.thread-name-prefix=AsyncThreadPool-
# Web server thread pool (Tomcat)
#default: 200
# server.tomcat.max-threads=200
#default: 100
# server.tomcat.accept-count=150
#default: 60000
# server.tomcat.connection-timeout=30000
GET /
: Returns the home page.GET /video
: Streams the video contentGET /video/info
: Provides information about the video file