Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
e2156808
Commit
e2156808
authored
Dec 01, 2023
by
caotao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.增加异步注解处理消息处理过多问题处理。
parent
53498788
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
1 deletion
+3
-1
CarIotNewListener.java
...a/com/yeejoin/equipmanage/listener/CarIotNewListener.java
+2
-0
AmostEquipApplication.java
...quip/src/main/java/com/yeejoin/AmostEquipApplication.java
+1
-1
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/listener/CarIotNewListener.java
View file @
e2156808
...
@@ -20,6 +20,7 @@ import org.slf4j.Logger;
...
@@ -20,6 +20,7 @@ import org.slf4j.Logger;
import
org.slf4j.LoggerFactory
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.scheduling.annotation.Async
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
...
@@ -68,6 +69,7 @@ public class CarIotNewListener extends EmqxListener {
...
@@ -68,6 +69,7 @@ public class CarIotNewListener extends EmqxListener {
public
static
final
ConcurrentHashMap
<
String
,
String
>
deviceLastInfo
=
new
ConcurrentHashMap
();
public
static
final
ConcurrentHashMap
<
String
,
String
>
deviceLastInfo
=
new
ConcurrentHashMap
();
@Override
@Override
@Async
public
void
processMessage
(
String
topic
,
MqttMessage
message
)
throws
Exception
{
public
void
processMessage
(
String
topic
,
MqttMessage
message
)
throws
Exception
{
logger
.
info
(
"----收到物联消息::topic---------------"
+
topic
);
logger
.
info
(
"----收到物联消息::topic---------------"
+
topic
);
...
...
amos-boot-system-equip/src/main/java/com/yeejoin/AmostEquipApplication.java
View file @
e2156808
...
@@ -42,7 +42,7 @@ import java.net.UnknownHostException;
...
@@ -42,7 +42,7 @@ import java.net.UnknownHostException;
@ComponentScan
(
value
=
{
"org.typroject"
,
"com.yeejoin.amos"
,
"com.yeejoin.equipmanage"
},
excludeFilters
=
{
@ComponentScan
(
value
=
{
"org.typroject"
,
"com.yeejoin.amos"
,
"com.yeejoin.equipmanage"
},
excludeFilters
=
{
@ComponentScan
.
Filter
(
type
=
FilterType
.
ASSIGNABLE_TYPE
,
classes
=
{
org
.
typroject
.
tyboot
.
core
.
restful
.
exception
.
GlobalExceptionHandler
.
class
})})
@ComponentScan
.
Filter
(
type
=
FilterType
.
ASSIGNABLE_TYPE
,
classes
=
{
org
.
typroject
.
tyboot
.
core
.
restful
.
exception
.
GlobalExceptionHandler
.
class
})})
@EnableFeignClients
@EnableFeignClients
@EnableAsync
@EnableAsync
(
proxyTargetClass
=
true
)
public
class
AmostEquipApplication
{
public
class
AmostEquipApplication
{
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
AmostEquipApplication
.
class
);
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
AmostEquipApplication
.
class
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment