# SSE Server Debugging
## Issue: Server Started But Port Not Listening
**Symptoms**:
- Logs show: "Started ProjectNameApplication in 7.828 seconds"
- Logs show: "Registered tools: 6"
- But: No "Tomcat started on port(s): 8080" message
- Port 8080 is not listening
## Possible Causes
### 1. Web Server Not Starting
Even though `web-application-type: servlet` is set, the web server might not be starting. Check:
**Solution**: Look for errors in the full server logs. The web server startup might be failing silently.
### 2. Logging Level Too High
Tomcat startup messages might be at INFO level, but we have root logging at WARN.
**Solution**: Check if there are any startup errors by:
- Looking at the full console output
- Checking for any exceptions during startup
- Verifying the server process is still running
### 3. Port Binding Issue
The server might be trying to start but failing to bind to port 8080.
**Solution**: Check if port 8080 is already in use:
```powershell
netstat -ano | findstr :8080
```
### 4. Web Server Auto-Configuration Excluded
Something might be preventing the web server from auto-configuring.
**Solution**: Verify that `spring-boot-starter-web` is in dependencies (it is).
## Debugging Steps
### Step 1: Check Full Server Output
Look for:
- Any exceptions or errors
- "Tomcat started" message (might be at INFO level)
- Port binding errors
- Web server initialization messages
### Step 2: Verify Server is Running
```powershell
# Check if process is still running
Get-Process -Name java | Where-Object {$_.Id -eq 8376}
# Check what ports Java processes are listening on
netstat -ano | findstr java
```
### Step 3: Check Logging Configuration
The root logging level is WARN, which might hide INFO-level Tomcat startup messages.
**Temporary fix**: Change logging level to INFO to see Tomcat messages:
```yaml
logging:
level:
root: INFO # Temporarily change from WARN to INFO
```
### Step 4: Try Explicit Port Configuration
Add explicit server port configuration:
```yaml
server:
port: 8080
```
## Expected Logs for SSE
When SSE transport works correctly, you should see:
```
Tomcat started on port(s): 8080 (http)
Started ProjectNameApplication in X seconds
```
If you don't see "Tomcat started", the web server didn't start.
## Next Steps
1. Check the full server console output for any errors
2. Verify the server process is still running
3. Try increasing logging level to INFO to see Tomcat messages
4. Check if there are any port binding errors