Skip to content
View sharanggupta's full-sized avatar

Block or report sharanggupta

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Content in all repositories owned by your account will be closed.
Maximum 250 characters. Please don’t include any personal information such as legal names or email addresses. Markdown is supported. This note will only be visible to you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse
sharanggupta/README.md
Java, Spring, TDD. Java and Spring, built test-first.

Software engineer at THG in Bournemouth, England. MSc Computer Science (Distinction), University of Southampton.

I work mostly in Java and Spring, test-first. Lately I've been sending fixes upstream to open-source libraries I use, and writing up what I learn with small apps that each demonstrate exactly one thing.

Website · Writing · LinkedIn


Merged upstream

Fixes and features that landed in projects I use. The eight below are the ones I would show first; all of them, with what each problem was and how it was fixed, are on my website.

Project Change
Spring Framework ProtobufDecoder releases the buffer of a partly read message when the subscriber cancels, so pooled buffers no longer leak.
OpenFeign A Request built with a null body behaves like one with an empty body instead of throwing on first access.
Micronaut Core An Accept-Charset header no longer decides how a String request body is decoded.
Eclipse Jetty A web application in a directory such as foo.com deploys as one app, together with its properties file (#14127).
SpotBugs An ignored Arrays.copyOf result is reported; the root cause, Class.desiredAssertionStatus() taken for a side effect, hid every pure method of a class that uses assert.
ArchUnit New haveOnlyFinalNonSyntheticFields() condition that checks final fields but skips compiler-generated ones.
Apache Log4j 2 Timestamps before 1970 format correctly; found by differential fuzzing against java.time, with no prior report.
Apache Commons Lang TypeUtils.containsTypeVariables and unrollVariables honour the owner type of a ParameterizedType, so Outer<T>.Inner resolves (LANG-1836).

Also landed in Spring Integration, Apache Tomcat, Apache Dubbo, Mockito, Apache Camel, Apache Maven, Spring AMQP, Spring Cloud Config, Spring Cloud Stream, Apache Felix, Apache Commons CSV, Apache WSS4J, Eclipse Yasson, Eclipse Angus Mail and Eclipse Mojarra: 37 pull requests in 23 projects so far, nearly all with a test that fails without the change.

More are in review: open pull requests.

Selected projects

  • orderly (work in progress): a Java 21 walk from controller-service-repository to hexagonal architecture, one failing test at a time. Module boundaries are enforced by the build.
  • flight-search: a Spring Boot REST API built test-first with a hexagon that never depends on the outside at compile time.
  • eazybank: Spring Boot microservices with an API gateway, deployed on Kubernetes, with metrics, logs and distributed tracing (Prometheus, Grafana, Loki, Tempo).
  • oauth2product: OAuth2 resource server and client with Spring Boot, built test-first. The article series below follows this code.

Writing

A four-part series on OAuth2 with Spring Boot, each part with a working app:

  1. Demystifying OAuth2
  2. Building an OAuth2 Resource Server
  3. Building an OAuth2 Client
  4. Running the System End-to-End

Day-to-day work at THG lives in private repositories; my work account is @sharang-gupta-thg.

Pinned Loading

  1. eazybank eazybank Public

    A microservices-based banking application built with Spring Boot.

    Java

  2. oauth2product oauth2product Public

    OAuth2 resource server and client with Spring Boot, built test-first (the code behind my Medium series)

    Java 1

  3. batch-data-migration batch-data-migration Public

    Data migration from NoSQL (MongoDB) to SQL using Spring Batch

    Java 1

  4. thiasil thiasil Public

    Website for Thia Glass Works

    TypeScript

  5. flight-search flight-search Public

    A Spring Boot REST API for searching flights, built using Test-Driven Development (TDD) and Hexagonal Architecture principles.

    Java

  6. orderly orderly Public

    Incremental Java 21 hexagonal architecture learning project, developed with TDD

    Java