You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by al...@apache.org on 2022/08/15 03:16:57 UTC

[dubbo] branch 3.1 updated (e069a7af9e -> 551f820a7e)

This is an automated email from the ASF dual-hosted git repository.

albumenj pushed a change to branch 3.1
in repository https://gitbox.apache.org/repos/asf/dubbo.git


    from e069a7af9e Support dubbo reactive stream with project reactor (#10290)
     add 438519cb71 fixed ServiceBeanNameBuilder same version/group conflict (#10454) (#10455)
     add 6b095f1c68 Fix npe (#10457)
     add 9b6c463598 Up dev issue#10388 (#10414)
     add af041d321f add default interval for retries of saving properties (#10412)
     add 6822b2301c Try to get it from the cache before generating the referenceKey (#10173)
     add c84b745bb1 DisableCircularReferenceDetect for fastjson impl (#10447)
     new 551f820a7e Merge branch 'apache-3.0' into apache-3.1

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../dubbo/common/concurrent/AbortPolicy.java       | 14 +++--
 .../common/concurrent/DiscardOldestPolicy.java}    | 21 ++++---
 .../dubbo/common/concurrent/DiscardPolicy.java     | 13 +++--
 .../dubbo/common/concurrent/RejectException.java   | 64 ++++++++++++++++++++++
 .../Lifecycle.java => concurrent/Rejector.java}    | 37 +++++--------
 .../dubbo/common/json/impl/FastJsonImpl.java       |  4 +-
 .../threadpool/MemorySafeLinkedBlockingQueue.java  | 31 ++++++++++-
 .../MemorySafeLinkedBlockingQueueTest.java         | 11 ++++
 .../factory/annotation/ServiceBeanNameBuilder.java |  3 +-
 .../spring/reference/ReferenceBeanManager.java     | 23 +++++++-
 .../ServiceAnnotationPostProcessorTest.java        |  2 +-
 .../annotation/ServiceBeanNameBuilderTest.java     | 10 ++++
 .../zookeeper/ZookeeperDynamicConfiguration.java   |  2 +-
 .../dubbo/registry/support/AbstractRegistry.java   | 13 +++--
 ...bboEndpointAnnotationAutoConfigurationTest.java |  2 +-
 .../DubboEndpointAutoConfigurationTest.java        |  2 +-
 16 files changed, 193 insertions(+), 59 deletions(-)
 copy dubbo-test/dubbo-test-common/src/main/java/org/apache/dubbo/test/common/impl/GreetingServiceImpl.java => dubbo-common/src/main/java/org/apache/dubbo/common/concurrent/AbortPolicy.java (72%)
 copy dubbo-common/src/{test/java/org/apache/dubbo/metadata/definition/service/annotation/MockTypeAnnotation.java => main/java/org/apache/dubbo/common/concurrent/DiscardOldestPolicy.java} (73%)
 copy dubbo-test/dubbo-test-common/src/main/java/org/apache/dubbo/test/common/impl/GreetingServiceImpl.java => dubbo-common/src/main/java/org/apache/dubbo/common/concurrent/DiscardPolicy.java (76%)
 create mode 100644 dubbo-common/src/main/java/org/apache/dubbo/common/concurrent/RejectException.java
 copy dubbo-common/src/main/java/org/apache/dubbo/common/{context/Lifecycle.java => concurrent/Rejector.java} (52%)


[dubbo] 01/01: Merge branch 'apache-3.0' into apache-3.1

Posted by al...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

albumenj pushed a commit to branch 3.1
in repository https://gitbox.apache.org/repos/asf/dubbo.git

commit 551f820a7edf386645b5e7cb820599202cab4b01
Merge: e069a7af9e c84b745bb1
Author: Albumen Kevin <jh...@gmail.com>
AuthorDate: Mon Aug 15 11:16:43 2022 +0800

    Merge branch 'apache-3.0' into apache-3.1
    
    # Conflicts:
    #       dubbo-registry/dubbo-registry-api/src/main/java/org/apache/dubbo/registry/support/AbstractRegistry.java

 .../dubbo/common/concurrent/AbortPolicy.java       | 32 +++++++++++
 .../common/concurrent/DiscardOldestPolicy.java     | 31 +++++++++++
 .../dubbo/common/concurrent/DiscardPolicy.java     | 31 +++++++++++
 .../dubbo/common/concurrent/RejectException.java   | 64 ++++++++++++++++++++++
 .../apache/dubbo/common/concurrent/Rejector.java   | 43 +++++++++++++++
 .../dubbo/common/json/impl/FastJsonImpl.java       |  4 +-
 .../threadpool/MemorySafeLinkedBlockingQueue.java  | 31 ++++++++++-
 .../MemorySafeLinkedBlockingQueueTest.java         | 11 ++++
 .../factory/annotation/ServiceBeanNameBuilder.java |  3 +-
 .../spring/reference/ReferenceBeanManager.java     | 23 +++++++-
 .../ServiceAnnotationPostProcessorTest.java        |  2 +-
 .../annotation/ServiceBeanNameBuilderTest.java     | 10 ++++
 .../zookeeper/ZookeeperDynamicConfiguration.java   |  2 +-
 .../dubbo/registry/support/AbstractRegistry.java   | 13 +++--
 ...bboEndpointAnnotationAutoConfigurationTest.java |  2 +-
 .../DubboEndpointAutoConfigurationTest.java        |  2 +-
 16 files changed, 288 insertions(+), 16 deletions(-)

diff --cc dubbo-registry/dubbo-registry-api/src/main/java/org/apache/dubbo/registry/support/AbstractRegistry.java
index b9e83baf79,516a974945..c65e519720
--- a/dubbo-registry/dubbo-registry-api/src/main/java/org/apache/dubbo/registry/support/AbstractRegistry.java
+++ b/dubbo-registry/dubbo-registry-api/src/main/java/org/apache/dubbo/registry/support/AbstractRegistry.java
@@@ -82,10 -80,11 +83,12 @@@ public abstract class AbstractRegistry 
      private static final String URL_SPLIT = "\\s+";
      // Max times to retry to save properties to local cache file
      private static final int MAX_RETRY_TIMES_SAVE_PROPERTIES = 3;
+     // Default interval in millisecond for saving properties to local cache file
+     private static final long DEFAULT_INTERVAL_SAVE_PROPERTIES = 500L;
  
      // Log output
 -    protected final Logger logger = LoggerFactory.getLogger(getClass());
 +    protected final ErrorTypeAwareLogger logger = LoggerFactory.getErrorTypeAwareLogger(getClass());
 +
      // Local disk cache, where the special key value.registries records the list of registry centers, and the others are the list of notified service providers
      private final Properties properties = new Properties();
      // File cache timing writing
@@@ -276,13 -242,10 +279,13 @@@
                  savePropertiesRetryTimes.set(0);
                  return;
              } else {
-                 registryCacheExecutor.execute(() -> doSaveProperties(lastCacheChanged.incrementAndGet()));
+                 registryCacheExecutor.schedule(() -> doSaveProperties(lastCacheChanged.incrementAndGet()), DEFAULT_INTERVAL_SAVE_PROPERTIES, TimeUnit.MILLISECONDS);
              }
 +
              if (!(e instanceof OverlappingFileLockException)) {
 -                logger.warn("Failed to save registry cache file, will retry, cause: " + e.getMessage(), e);
 +                logger.warn("1-9", CAUSE_MULTI_DUBBO_USING_SAME_FILE,
 +                    "However, the retrying count limit is not exceeded. Dubbo will still try.",
 +                    "Failed to save registry cache file, will retry, cause: " + e.getMessage(), e);
              }
          } finally {
              if (lockfile != null) {