Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
Openfire
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
Openfire
Commits
ff7b99cf
Commit
ff7b99cf
authored
Nov 25, 2015
by
Dave Cridland
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #410 from tevans/pubsub
Simplify and shorten pubsub message id
parents
7018ba41
0535aa41
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
7 deletions
+4
-7
PEPService.java
src/java/org/jivesoftware/openfire/pep/PEPService.java
+2
-3
PubSubModule.java
src/java/org/jivesoftware/openfire/pubsub/PubSubModule.java
+2
-4
No files found.
src/java/org/jivesoftware/openfire/pep/PEPService.java
View file @
ff7b99cf
...
@@ -37,7 +37,6 @@ import org.jivesoftware.openfire.entitycaps.EntityCapabilities;
...
@@ -37,7 +37,6 @@ import org.jivesoftware.openfire.entitycaps.EntityCapabilities;
import
org.jivesoftware.openfire.entitycaps.EntityCapabilitiesManager
;
import
org.jivesoftware.openfire.entitycaps.EntityCapabilitiesManager
;
import
org.jivesoftware.openfire.pubsub.CollectionNode
;
import
org.jivesoftware.openfire.pubsub.CollectionNode
;
import
org.jivesoftware.openfire.pubsub.DefaultNodeConfiguration
;
import
org.jivesoftware.openfire.pubsub.DefaultNodeConfiguration
;
import
org.jivesoftware.openfire.pubsub.LeafNode
;
import
org.jivesoftware.openfire.pubsub.Node
;
import
org.jivesoftware.openfire.pubsub.Node
;
import
org.jivesoftware.openfire.pubsub.NodeSubscription
;
import
org.jivesoftware.openfire.pubsub.NodeSubscription
;
import
org.jivesoftware.openfire.pubsub.PendingSubscriptionsCommand
;
import
org.jivesoftware.openfire.pubsub.PendingSubscriptionsCommand
;
...
@@ -331,7 +330,7 @@ public class PEPService implements PubSubService, Cacheable {
...
@@ -331,7 +330,7 @@ public class PEPService implements PubSubService, Cacheable {
message
.
setFrom
(
getAddress
());
message
.
setFrom
(
getAddress
());
for
(
JID
jid
:
jids
)
{
for
(
JID
jid
:
jids
)
{
message
.
setTo
(
jid
);
message
.
setTo
(
jid
);
message
.
setID
(
node
.
getNodeID
()
+
"__"
+
jid
.
toBareJID
()
+
"__"
+
StringUtils
.
randomString
(
5
));
message
.
setID
(
StringUtils
.
randomString
(
8
));
router
.
route
(
message
);
router
.
route
(
message
);
}
}
}
}
...
@@ -340,7 +339,7 @@ public class PEPService implements PubSubService, Cacheable {
...
@@ -340,7 +339,7 @@ public class PEPService implements PubSubService, Cacheable {
public
void
sendNotification
(
Node
node
,
Message
message
,
JID
recipientJID
)
{
public
void
sendNotification
(
Node
node
,
Message
message
,
JID
recipientJID
)
{
message
.
setTo
(
recipientJID
);
message
.
setTo
(
recipientJID
);
message
.
setFrom
(
getAddress
());
message
.
setFrom
(
getAddress
());
message
.
setID
(
node
.
getNodeID
()
+
"__"
+
recipientJID
.
toBareJID
()
+
"__"
+
StringUtils
.
randomString
(
5
));
message
.
setID
(
StringUtils
.
randomString
(
8
));
// If the recipient subscribed with a bare JID and this PEPService can retrieve
// If the recipient subscribed with a bare JID and this PEPService can retrieve
// presence information for the recipient, collect all of their full JIDs and
// presence information for the recipient, collect all of their full JIDs and
...
...
src/java/org/jivesoftware/openfire/pubsub/PubSubModule.java
View file @
ff7b99cf
...
@@ -723,8 +723,7 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di
...
@@ -723,8 +723,7 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di
message
.
setFrom
(
getAddress
());
message
.
setFrom
(
getAddress
());
for
(
JID
jid
:
jids
)
{
for
(
JID
jid
:
jids
)
{
message
.
setTo
(
jid
);
message
.
setTo
(
jid
);
message
.
setID
(
message
.
setID
(
StringUtils
.
randomString
(
8
));
node
.
getNodeID
()
+
"__"
+
jid
.
toBareJID
()
+
"__"
+
StringUtils
.
randomString
(
5
));
router
.
route
(
message
);
router
.
route
(
message
);
}
}
}
}
...
@@ -738,8 +737,7 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di
...
@@ -738,8 +737,7 @@ public class PubSubModule extends BasicModule implements ServerItemsProvider, Di
public
void
sendNotification
(
Node
node
,
Message
message
,
JID
jid
)
{
public
void
sendNotification
(
Node
node
,
Message
message
,
JID
jid
)
{
message
.
setFrom
(
getAddress
());
message
.
setFrom
(
getAddress
());
message
.
setTo
(
jid
);
message
.
setTo
(
jid
);
message
.
setID
(
message
.
setID
(
StringUtils
.
randomString
(
8
));
node
.
getNodeID
()
+
"__"
+
jid
.
toBareJID
()
+
"__"
+
StringUtils
.
randomString
(
5
));
router
.
route
(
message
);
router
.
route
(
message
);
}
}
...
...
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