Skip to main content

3.Slardar

trydoforOriginalSlardarHomeAbout 1 min

3.Slardar

slardar

The big fish, a sailor, will starlight your way.

SpringMvc (not WebFlux) wrappers and extensions, such as multi-language, multi-timezone, security, caching, sessions, etc.

3.1.Module Project

  • slardar - basic features eg. caching, event, serializing
  • slardar-hazel-caching - distributed cache on hazelcast
  • slardar-hazel-session - distributed session on hazelcast
  • slardar-webmvc - webmvc, session, security-web
  • slardar-sprint - hazelcast, security-conf, admin, actuator
  • slardar-test - testing utility including login

3.2.Solution and Configuration

Slardar is configured by default according to the following architecture and performance,

  • Nginx(reverse proxy), mainly post+json service
  • Undertow as the default Servlet container
  • Hazelcast as Cache and Session
  • 80% service can 30ms end, blocking factor 0.9
  • 8-core 3GHz cloud hosting, simulating 10k*50 requests, single application
  • 95th, response=2s, tps=2k-5k

3.3.SpringMvc Enhancement

Base on springmvc, Salrdar provides potential capabilities and out-of-the-box features,

  • concurrency control, multi-level caching, event publish/subscribe
  • spring-boot-admin and actuator management and monitoring capability
  • sentry log collection capability
  • Terminal and Security's Context
  • login, permission, session, token and other control capabilities

3.4.Preconfigured ThreadPool

SlardarAsyncConfiguration provides 4 pre-config Ttl threadpools, prefix and purpose are,

  • win-async- - spring.task.execution. properties for @Async
  • win-task- - spring.task.scheduling. properties for @Scheduled
  • win-event- - wings.slardar.async.event. properties for Spring's Event
  • win-heavy- - wings.slardar.async.heavy. properties for Wings heavy task

3.5.More Sections