Skip to content

Commit

Permalink
java 项目 commit
Browse files Browse the repository at this point in the history
  • Loading branch information
huangjun0124 committed Oct 17, 2021
0 parents commit 38502bf
Show file tree
Hide file tree
Showing 16 changed files with 866 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
HELP.md
target/
!.mvn/wrapper/maven-wrapper.jar
!**/src/main/**/target/
!**/src/test/**/target/

### STS ###
.apt_generated
.classpath
.factorypath
.project
.settings
.springBeans
.sts4-cache

### IntelliJ IDEA ###
.idea
*.iws
*.iml
*.ipr

### NetBeans ###
/nbproject/private/
/nbbuild/
/dist/
/nbdist/
/.nb-gradle/
build/
!**/src/main/**/build/
!**/src/test/**/build/

### VS Code ###
.vscode/
17 changes: 17 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
version: '3'
services:
zookeeper:
image: zookeeper
ports:
- 2181:2181
admin:
image: apache/dubbo-admin:latest
depends_on:
- zookeeper
ports:
- 8081:8080
environment:
- admin.registry.address=zookeeper://zookeeper:2181
- admin.config-center=zookeeper://zookeeper:2181
- admin.metadata-report.address=zookeeper://zookeeper:2181
# docker-compose -f /home/jun/docker/zookeeper/docker-compose.yaml up -d
12 changes: 12 additions & 0 deletions dubbo-client/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.example</groupId>
<artifactId>demo</artifactId>
<version>0.0.1-SNAPSHOT</version>
</parent>

<artifactId>dubbo-client</artifactId>
</project>
11 changes: 11 additions & 0 deletions dubbo-client/src/main/java/com/demo/exp/dto/QueryUserParam.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package com.demo.exp.dto;

import lombok.Data;

import java.io.Serializable;

@Data
public class QueryUserParam implements Serializable {
private String userName;
private String userId;
}
14 changes: 14 additions & 0 deletions dubbo-client/src/main/java/com/demo/exp/dto/QueryUserResponse.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package com.demo.exp.dto;

import lombok.Data;

import java.io.Serializable;

@Data
public class QueryUserResponse implements Serializable {
private String userId;
private String userName;
private String birthDate;
private long age;
private boolean isDead;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package com.demo.exp.service;

import com.demo.exp.dto.QueryUserParam;
import com.demo.exp.dto.QueryUserResponse;

public interface UserService {
QueryUserResponse QueryUser(QueryUserParam req);
}
Loading

0 comments on commit 38502bf

Please sign in to comment.