使用stompjs与后端建立websocket连接时报错:Whoops! Lost connection to http://localhost:8080/dll/endwisely 的解决方法

感谢大佬,参考:https://blog.csdn.net/pacosonswjtu/article/details/51916089


在后端Spring项目中添加相关的几个jar包,使用maven管理可在pom.xml中添加如下依赖:

<!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind -->
		<dependency>
			<groupId>com.fasterxml.jackson.core</groupId>
			<artifactId>jackson-databind</artifactId>
			<version>2.9.4</version>
		</dependency>

		<!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core -->
		<dependency>
			<groupId>com.fasterxml.jackson.core</groupId>
			<artifactId>jackson-core</artifactId>
			<version>2.9.4</version>
		</dependency>

		<!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-annotations -->
		<dependency>
			<groupId>com.fasterxml.jackson.core</groupId>
			<artifactId>jackson-annotations</artifactId>
			<version>2.9.4</version>
		</dependency>

猜你喜欢

转载自blog.csdn.net/AaronChen01/article/details/80019294