Skip to content

server: start the standalone server and add the embeddable OpenSharing builder - #91

Merged
littlegrasscao merged 18 commits into
mainfrom
server/split2/04-storage-paths
Oct 19, 2026
Merged

littlegrasscao merged 18 commits into
mainfrom
server/split2/04-storage-paths

Conversation

@littlegrasscao

@littlegrasscao littlegrasscao commented Sep 11, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • replace the Spring Boot application with a standalone server on Armeria: OpenSharingServer loads the configured catalog, builds OpenSharing, and listens on server.port; main serves until the JVM shuts down and rejects program arguments
  • ServerProperties reads server.properties from the classpath. A JVM system property overrides a key, then an environment variable with the same name or its upper snake case form, such as SERVER_PORT. A blank value anywhere keeps the default
    • server.port (default 8080), catalog.type (only local so far), and catalog.local.file (default classpath:local-catalog.yml)
  • LocalCatalogLoader.load(location) reads the local catalog from a classpath: resource or a file path, with or without file:
  • add OpenSharing.builder() in core, which builds OpenSharing from the parts its host supplies; it requires a CatalogConnector
  • package a runnable opensharing-server-*-exec.jar with the shade plugin, and log through Logback
  • pin Netty to 4.1.126.Final through netty-bom, over the 4.1.108 Armeria brings, for its HTTP/2 fixes; the AWS SDK already in core expects it too
  • drop the Spring Boot dependencies and application.yml. Nothing read its keys yet; each comes back where it is used:

Testing

  • mvn clean install: 41 tests passed
  • OpenSharingServerTest: loads the configured local catalog, rejects a missing catalog file and an unknown catalog type, builds OpenSharing with the configured catalog, and rejects program arguments
  • ServerPropertiesTest: reads server.properties from the classpath, keeps the default of blank keys and blank overrides, lets system properties override the file, reads environment variables by key or upper snake case name, and rejects a port that is not a number

@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 7a9dd7f to 2fa5381 Compare September 11, 2026 22:28
@littlegrasscao littlegrasscao changed the title server: add storage path containment helpers server: wire the local catalog into the runnable server Sep 11, 2026
@littlegrasscao
littlegrasscao deleted the server/split2/04-storage-paths branch September 11, 2026 22:28
@littlegrasscao
littlegrasscao restored the server/split2/04-storage-paths branch September 11, 2026 22:28
@littlegrasscao littlegrasscao changed the title server: wire the local catalog into the runnable server server: start the standalone server with the local catalog Sep 11, 2026
@littlegrasscao
littlegrasscao marked this pull request as ready for review September 14, 2026 18:05
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch 2 times, most recently from 28116de to fe78020 Compare September 22, 2026 16:42
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from fe78020 to d24ffa5 Compare September 25, 2026 22:26
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from d24ffa5 to 9fdcdb4 Compare September 25, 2026 22:31
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 9fdcdb4 to 514a93f Compare September 25, 2026 22:36
@littlegrasscao
littlegrasscao requested a review from zhu-tom October 1, 2026 00:16
@zhu-tom
zhu-tom added this pull request to stack #111 October 1, 2026 18:55
@littlegrasscao
littlegrasscao removed this pull request from stack #111 October 1, 2026 20:19
@littlegrasscao
littlegrasscao added this pull request to stack #112 October 1, 2026 20:20
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 514a93f to 63be999 Compare October 2, 2026 16:08
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 63be999 to 74c5068 Compare October 2, 2026 16:40
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 74c5068 to b85dd76 Compare October 5, 2026 23:57
@littlegrasscao littlegrasscao changed the title server: start the standalone server with the local catalog server: start the standalone server and add the embeddable OpenSharing builder Oct 6, 2026
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch 2 times, most recently from 3623544 to 4a35255 Compare October 8, 2026 00:44
Base automatically changed from server/split2/03-local-catalog to main October 13, 2026 21:07
@littlegrasscao
littlegrasscao force-pushed the server/split2/04-storage-paths branch from 4a35255 to de1f264 Compare October 13, 2026 21:07
@chakankardb

Copy link
Copy Markdown
Collaborator

Is the description correct (Spring Boot application)?

@chakankardb chakankardb left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From claude: Following on from the description question above: the config keys in the deleted application.yml aren't carried over to server.properties: protocol-prefix, asset-credentials.ttl, pagination limits, storage.gcs-service-account-key-file, delta.*, and the Jackson settings (non_null, ISO dates, case-insensitive enums). Nothing reads them yet, but the Jackson settings change what protocol responses look like, so is dropping them intended? If so, could the updated description list them?

Comment thread server/pom.xml
Comment thread server/opensharing-server/src/main/java/io/opensharing/OpenSharingServer.java Outdated
…snake case environment variables, and reject program arguments.
@littlegrasscao

Copy link
Copy Markdown
Collaborator Author

@chakankardb On the description: it was stale (it still described the Spring Boot application). It's rewritten to match the current diff.

On the dropped application.yml keys: yes, that's intended. Nothing read them in this PR, and each comes back in the PR that uses it. The updated description lists where:

@littlegrasscao
littlegrasscao merged commit 1009f45 into main Oct 19, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants