java版gRPC实战之一:用proto生成代码,伟易达java工程师面试

// 如果有私服就在此配置,如果没有请注释掉

maven {

url ‘http://192.168.50.43:8081/repository/aliyun-proxy/’

}

// 阿里云

maven {

url ‘http://maven.aliyun.com/nexus/content/groups/public/’

}

mavenCentral()

}

ext {

// 项目版本

projectVersion = ‘1.0-SNAPSHOT’

// 依赖库的版本

grpcSpringBootStarterVersion = ‘2.11.0.RELEASE’

// grpc版本 https://github.com/grpc/grpc-java/releases

grpcVersion = ‘1.35.0’

// protobuf版本 https://github.com/protocolbuffers/protobuf/releases

protobufVersion = ‘3.14.0’

// protobuf的gradle插件版本

protobufGradlePluginVersion = ‘0.8.12’

// sprignboot版本 https://github.com/spring-projects/spring-boot/releases

springBootVersion = ‘2.3.8.RELEASE’

// springcloud版本 https://github.com/spring-cloud/spring-cloud-release/releases

springCloudVersion = ‘Hoxton.SR9’

// nacos版本 https://github.com/alibaba/spring-cloud-alibaba/releases

springCloudAlibabaNacosVersion = ‘2.2.3.RELEASE’

// security版本 https://github.com/spring-projects/spring-security-oauth/releases

springSecurityOAuthVersion = ‘2.5.0.RELEASE’

}

}

plugins {

id ‘java’

id ‘java-library’

id ‘org.springframework.boot’ version “${springBootVersion}” apply false

id ‘io.spring.dependency-management’ version ‘1.0.11.RELEASE’

id ‘net.nemerosa.versioning’ version ‘2.14.0’

id ‘com.google.protobuf’ version ‘0.8.14’

id ‘io.franzbecker.gradle-lombok’ version ‘4.0.0’ apply false

id ‘com.github.ben-manes.versions’ version ‘0.36.0’ // gradle dependencyUpdates

}

// If you attempt to build without the --scan parameter in gradle 6.0+ it will cause a build error that it can’t find

// a buildScan property to change. This avoids that problem.

if (hasProperty(‘buildScan’)) {

buildScan {

termsOfServiceUrl = ‘https://gradle.com/terms-of-service’

termsOfServiceAgree = ‘yes’

}

}

wrapper {

gradleVersion = ‘6.7.1’

}

def buildTimeAndDate = OffsetDateTime.now()

ext {

// 构建时取得当前日期和时间

buildDate = DateTimeFormatter.ISO_LOCAL_DATE.format(buildTimeAndDate)

buildTime = DateTimeFormatter.ofPattern(‘HH:mm:ss.SSSZ’).format(buildTimeAndDate)

buildRevision = versioning.inf

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值