提交registry工程
This commit is contained in:
parent
9bbb126917
commit
c887abeb8c
|
|
@ -0,0 +1,22 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<artifactId>skywalking</artifactId>
|
||||
<groupId>com.a.eye</groupId>
|
||||
<version>2.0-2016</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>skywalking-registry</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>skywalking-registry</name>
|
||||
<url>http://maven.apache.org</url>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
package com.a.eye.skywalking.registry.api;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface NotifyListener {
|
||||
void notify(List<RegistryData> data);
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
package com.a.eye.skywalking.registry.api;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/11/9.
|
||||
*/
|
||||
public interface Register {
|
||||
|
||||
void subscribe(NotifyListener listener);
|
||||
|
||||
void unSubscribe();
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
package com.a.eye.skywalking.registry.api;
|
||||
|
||||
public interface RegisterFactory {
|
||||
Register getRegister(String key);
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package com.a.eye.skywalking.registry.api;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/11/9.
|
||||
*/
|
||||
public class RegistryData {
|
||||
|
||||
public String key() {
|
||||
return null;
|
||||
}
|
||||
|
||||
public String data() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
package com.a.eye.skywalking.registry.impl;
|
||||
|
||||
import com.a.eye.skywalking.registry.api.NotifyListener;
|
||||
import com.a.eye.skywalking.registry.api.Register;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/11/9.
|
||||
*/
|
||||
public class DefaultRegistry implements Register {
|
||||
@Override
|
||||
public void subscribe(NotifyListener listener) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void unSubscribe() {
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
package com.a.eye.skywalking.registry.impl;
|
||||
|
||||
import com.a.eye.skywalking.registry.api.Register;
|
||||
import com.a.eye.skywalking.registry.api.RegisterFactory;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/11/9.
|
||||
*/
|
||||
public class DefaultRegistryFactory implements RegisterFactory {
|
||||
@Override
|
||||
public Register getRegister(String key) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue