Giter Club home page Giter Club logo

spring-boot-eureka-server's Introduction

spring-boot-eureka-server

Eureka Server for Getting Started with Spring Boot presentation.

1 - Spring Intializr Creation

I used the following at http://start.spring.io to create the Eureka Server application.

  • Build tool - Gradle
  • Language - Java
  • Spring Boot Version - 1.5.10.RELEASE
  • Group = com.scmc
  • Artifact = boot-demo-eureka-server
  • Name = boot-demo-eureka-server
  • Package Name = com.scmc.bootdemo.eureka
  • Packaging = JAR
  • Java Version = 1.8
  • Dependencies = Eureka Server, Actuator

2 - Eureka Server Updates

2.1 - Update Application Class

Next in the class BootDemoEurekaServerApplication, I needed to add the following annotation to the class:

@EnableEurekaServer

This enables a registry that other applications can talk to.

2.2 - Update Application Properties

Next, I added the following to the application.properties file found in the main resources directory:

server.port=8761

eureka.client.register-with-eureka=false eureka.client.fetch-registry=false

logging.level.com.netflix.eureka=OFF logging.level.com.netflix.discovery=OFF

  • This changes the server port so that we don't have conflicts with the 8000's range planned for our microservices.
  • This also prevents the registry from attempting to register itself.
  • Finally, I've turned off stacktrace as it will complain about not having replica nodes for the registry to connect to. Replication is recommended for production, but we aren't building that type of environment in the example.

3 - Running the Application

Simply run the following command to start the Eureka server:

.\gradlew bootRun

This will start the server on port 8761.

4 - More Details

spring-boot-eureka-server's People

Contributors

michaelhoffmantech avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.