Skip to content

Commit

Permalink
v3.13.0 release (^.^)YYa!!
Browse files Browse the repository at this point in the history
  • Loading branch information
yangfuhai committed Dec 26, 2021
1 parent f03bc0c commit a5173f4
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,22 +79,26 @@ public void init(JbootConfigManager configManager) {
*/
public void onReceiveConfigInfo(JbootConfigManager configManager, String configInfo) {
Properties properties = str2Properties(configInfo);
if (contentProperties == null && properties != null) {
contentProperties = properties;
configManager.setRemoteProperties(properties);
} else if (contentProperties != null && properties != null) {
for (Object key : properties.keySet()) {
String newValue = properties.getProperty(key.toString());
String oldValue = contentProperties.getProperty(key.toString());

if (!Objects.equals(newValue, oldValue)) {
contentProperties.put(key, newValue);
configManager.setRemoteProperty(key.toString(), newValue);

configManager.notifyChangeListeners(key.toString(), newValue, oldValue);
if (properties != null) {
if (contentProperties == null) {
contentProperties = properties;
configManager.setRemoteProperties(properties);
} else {
for (Object key : properties.keySet()) {
String newValue = properties.getProperty(key.toString());
String oldValue = contentProperties.getProperty(key.toString());

if (!Objects.equals(newValue, oldValue)) {
contentProperties.put(key, newValue);
configManager.setRemoteProperty(key.toString(), newValue);

configManager.notifyChangeListeners(key.toString(), newValue, oldValue);
}
}
}
}


}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class JbootRabbitmqConfig {
private String broadcastChannelPrefix = "broadcast-";
private String broadcastChannelRoutingKey = "";

//若配置为 false,则需要在 OnMessage 里,调用 RabbitmqMessageInfo.getChannel().baseAck(或者baseNack)进行消费(或者标识消费失败)
//若配置为 false,则需要在 OnMessage 里,调用 MessageContext.getChannel().baseAck(或者baseNack)进行消费(或者标识消费失败)
private boolean autoAck = true;


Expand Down

0 comments on commit a5173f4

Please sign in to comment.