[incubator-dubbo] branch 2.6.x updated: New ascii logo for 2.6.x (#2402)

2018-08-29 Thread jerrick
This is an automated email from the ASF dual-hosted git repository.

jerrick pushed a commit to branch 2.6.x
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git


The following commit(s) were added to refs/heads/2.6.x by this push:
 new ba51bab  New ascii logo for 2.6.x (#2402)
ba51bab is described below

commit ba51bab3955e7fc872042bac800771ffdf05c7f6
Author: 时无两丶 <442367...@qq.com>
AuthorDate: Wed Aug 29 18:13:03 2018 +0800

New ascii logo for 2.6.x (#2402)
---
 .../java/com/alibaba/dubbo/qos/server/DubboLogo.java | 16 +---
 1 file changed, 5 insertions(+), 11 deletions(-)

diff --git 
a/dubbo-plugin/dubbo-qos/src/main/java/com/alibaba/dubbo/qos/server/DubboLogo.java
 
b/dubbo-plugin/dubbo-qos/src/main/java/com/alibaba/dubbo/qos/server/DubboLogo.java
index c5bec0c..6dabdcf 100644
--- 
a/dubbo-plugin/dubbo-qos/src/main/java/com/alibaba/dubbo/qos/server/DubboLogo.java
+++ 
b/dubbo-plugin/dubbo-qos/src/main/java/com/alibaba/dubbo/qos/server/DubboLogo.java
@@ -17,15 +17,9 @@
 package com.alibaba.dubbo.qos.server;
 
 public class DubboLogo {
-public static String dubbo =
-"  ▄  ████▄  ▀█▄  ▀█▄   
▄██▄  \n" +
-"  ███   ▀███ ██████   ██████   ██████ ███
███ \n" +
-"  ██████ ██████   ██████   ██████ ███
███ \n" +
-"  ██████ ██████  ▄███▄▄▄██▀   ▄███▄▄▄██▀  ███
███ \n" +
-"  ██████ ██████ ▀▀███▀▀▀██▄  ▀▀███▀▀▀██▄  ███
███ \n" +
-"  ██████ ██████   █████▄   █████▄ ███
███ \n" +
-"  ███   ▄███ ██████   ██████   ██████ ███
███ \n" +
-"  ▀  ▀  ▄█▀  ▄█▀   
▀██▀  \n" +
-"  
   \n" +
-"\n";
+public static final String dubbo =
+"   ___   __  __ ___   ___    \n" +
+"  / _ \\ / / / // _ ) / _ ) / __ \\  \n" +
+" / // // /_/ // _  |/ _  |/ /_/ /\n" +
+"// \\///// \\/   \n";
 }



[incubator-dubbo-website] branch asf-site updated: Merge pull request #121, translate serialization.md.

2018-08-29 Thread liujun
This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo-website.git


The following commit(s) were added to refs/heads/asf-site by this push:
 new a5619a1  Merge pull request #121, translate serialization.md.
a5619a1 is described below

commit a5619a1147ce6966e94543bd9566164295d3a7d9
Author: HazzaCheng 
AuthorDate: Thu Aug 30 11:54:56 2018 +0800

Merge pull request #121, translate serialization.md.
---
 docs/en-us/user/demos/serialization.md | 77 ++
 1 file changed, 77 insertions(+)

diff --git a/docs/en-us/user/demos/serialization.md 
b/docs/en-us/user/demos/serialization.md
new file mode 100644
index 000..276fc38
--- /dev/null
+++ b/docs/en-us/user/demos/serialization.md
@@ -0,0 +1,77 @@
+## Using Efficient Java Serialization in Dubbo (Kryo and 
FST)
+## Start Kryo and FST
+
+It is easy to use Kryo and FST. You only need to add an attribute 
in the XML configuration of Dubbo RPC:
+
+```
+
+```
+
+```
+
+```
+
+## Register serialized class
+
+To make Kryo and FST have high-performance, it is better to 
register those classes that need serialization to the Dubbo system. For 
example, we can implement the following callback interface: 
+
+   public class SerializationOptimizerImpl implements 
SerializationOptimizer {
+
+   public Collection getSerializableClasses() {
+   List classes = new LinkedList();
+   classes.add(BidRequest.class);
+   classes.add(BidResponse.class);
+   classes.add(Device.class);
+   classes.add(Geo.class);
+   classes.add(Impression.class);
+   classes.add(SeatBid.class);
+   return classes;
+   }
+   }
+
+
+
+Then add in the XML configuration:
+
+```
+
+```
+
+After registering these classes, serialization performance can be 
greatly improved, especially for small numbers of nested objects.
+
+Of course, when serializing a class, you might also cascade references to many 
classes, such as Java collection classes. In this case, we've automatically 
registered common classes in the JDK, so you don't need to register them 
repeatedly (and of course, it doesn't matter if you register them again), 
including:
+
+
+   GregorianCalendar
+   InvocationHandler
+   BigDecimal
+   BigInteger
+   Pattern
+   BitSet
+   URI
+   UUID
+   HashMap
+   ArrayList
+   LinkedList
+   HashSet
+   TreeSet
+   Hashtable
+   Date
+   Calendar
+   ConcurrentHashMap
+   SimpleDateFormat
+   Vector
+   BitSet
+   StringBuffer
+   StringBuilder
+   Object
+   Object[]
+   String[]
+   byte[]
+   char[]
+   int[]
+   float[]
+   double[]
+
+
+Since registering serialized classes is only for performance 
optimization purposes, it doesn't matter if you forget to register some 
classes. In fact, Kryo and FST generally perform better than Hessian and Dubbo 
serializations even if no classes are registered.
\ No newline at end of file



[incubator-dubbo-website] branch asf-site updated: Merge pull request #115, english version for blog dubbo-k8s.

2018-08-29 Thread liujun
This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo-website.git


The following commit(s) were added to refs/heads/asf-site by this push:
 new 70b2e06  Merge pull request #115, english version for blog dubbo-k8s.
70b2e06 is described below

commit 70b2e06f6dd5c69b8adb58a039b1a0ce861e0a56
Author: IaMJamesHuang <38498283+iamjameshu...@users.noreply.github.com>
AuthorDate: Thu Aug 30 12:08:14 2018 +0800

Merge pull request #115, english version for blog dubbo-k8s.
---
 blog/en-us/dubbo-k8s.md | 67 +++--
 blog/zh-cn/dubbo-k8s.md | 39 ++--
 2 files changed, 84 insertions(+), 22 deletions(-)

diff --git a/blog/en-us/dubbo-k8s.md b/blog/en-us/dubbo-k8s.md
index 7da6bdc..ecd151a 100644
--- a/blog/en-us/dubbo-k8s.md
+++ b/blog/en-us/dubbo-k8s.md
@@ -1,2 +1,65 @@
-Part 1
-Part 2
+At first sight, the service of kubernetes has its own IP, while under the 
original fixed mindset: Dubbo/HSF service is aggregated by the IP of the entire 
service cluster, that means, kubernetes and Dubbo/HSF look like something 
different in natural, but when carefully thinking, the difference becomes 
insignificant. Because the only IP under kubernetes is just a Virtural IP--VIP, 
behind the vip are multiple endpoints, which is the factual processing node.
+
+Here we only discuss the situation that the Dubbo service in the cluster is 
accessed in the same kubernetes cluster, As for the provider outside kubernetes 
to access the provider in kubernetes, since it involves the problem of network 
address space, and it usually requires GateWay/loadbalance for mapping 
conversion, which there not detail discussion for this case. Besides, there are 
two options available for kubernetes:
+
+1. DNS: The default kubernetes service is based on the DNS plugin (The latest 
version of the recommendation is coreDNS), one proposal on Dubbo is about this. 
 since HSF/Dubbo has always highlighted its soft-load address discovery 
capability, it ignores Static's strategy insteadily, my understanding is that 
as a service discovery mechanism, the static resolution mechanism is one of the 
simplest and most needed to support mechanism, you can also refer to Envoy's 
point of views. While at th [...]
+
+   ![img](https://img.alicdn.com/tfs/TB1Kj1ktpkoBKNjSZFEXXbrEVXa-985-213.png)
+
+2. API:DNS relies on the DNS plugin, which will generate additional operation, 
so consider directly obtaining the endpoint through the client of kubernetes. 
In fact, by accessing the API server interface of kubernetes, you can directly 
obtain the list of endpoints behind a certain servie, and can also monitor the 
changes in its address list. Thereby implementing the soft load discovery 
strategy recommended by Dubbo/HSF. Refer to the code for details:
+
+The above two thoughts need to consider the following two points:
+
+1. Kubernetes and Dubbo are consistent with the mapping name of service. 
Dubbo's service is determined by serviename, group, version to determine its 
uniqueness, and servicename generally has a longer package name for its service 
interface. Need to map the servie name of kubernetes and the service name of 
dubbo. Either add a property like SOFA to define it. This is a big change, but 
it is most reasonable. Or it is a fixed rule to reference the deployed 
environment variables, which can be [...]
+2. Port problem:The default Pod and Pod network interoperability is solved, 
need to be validated.
+
+## Demo Verification
+
+The following is a demo deployment through kubernetes service in Alibaba 
Cloud's Container Registry and   EDAS. Visit Alibaba Cloud -》Container Registry.
+
+1. Create repo and bind the github codebase. As shown below.
+
+![img](https://img.alicdn.com/tfs/TB1m.tEtrorBKNjSZFjXXc_SpXa-1892-870.png)
+
+
+
+
+2. Click Manage enter the repository details page. Click Build in images 
service panel,  construct the demo into image and publish it to the specified 
repository. As shown below.
+
+   ![img](https://img.alicdn.com/tfs/TB1oYqvtcIrBKNjSZK9XXagoVXa-1872-888.png)
+
+
+
+3. Switch to Enterprise Distributed Application Services (EDAS) products 
panel, visit Resource Management -》Clusters. Create kubernetes cluster and bind 
ECS. As shown below.
+
+   ![img](https://img.alicdn.com/tfs/TB1b1p2trZnBKNjSZFKXXcGOVXa-1858-833.png)
+
+
+
+4. Application Management - 》Create  application, type kubernetes application 
and specify the image in the container registry . As shown below.
+
+   ![img](https://img.alicdn.com/tfs/TB1_YywtDCWBKNjSZFtXXaC3FXa-1737-588.png)
+
+
+
+   ![](https://img.alicdn.com/tfs/TB18uzTtdcnBKNjSZR0XXcFqFXa-1820-861.png)
+
+
+
+5.  After creation , then deploy applications. As shown below.
+
+   ![](https://img.alicdn.com/tfs/TB1fEpEtrorBKNjSZFjXXc_SpXa-1846-783.png)
+
+- The supplementary application name cannot have uppercase le