refactor: remove unused imports from GuidConfig and JacksonConfig classes
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package com.onixbyte.helix.config;
|
||||
|
||||
import com.onixbyte.identitygenerator.IdentityGenerator;
|
||||
import com.onixbyte.identitygenerator.impl.SequentialUuidGenerator;
|
||||
import com.onixbyte.identitygenerator.impl.SnowflakeIdentityGenerator;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
@@ -28,24 +27,6 @@ import org.springframework.context.annotation.Configuration;
|
||||
@Configuration
|
||||
public class GuidConfig {
|
||||
|
||||
/**
|
||||
* Creates a Snowflake-based identity generator for user IDs.
|
||||
* <p>
|
||||
* This method configures a {@link SnowflakeIdentityGenerator} with machine ID and data centre
|
||||
* ID both set to 0. The generator produces unique 64-bit Long identifiers suitable for user
|
||||
* entity primary keys in distributed environments.
|
||||
* <p>
|
||||
* The generated IDs are:
|
||||
* <ul>
|
||||
* <li>Globally unique across all instances</li>
|
||||
* <li>Time-ordered (newer IDs have higher values)</li>
|
||||
* <li>Highly performant with minimal coordination overhead</li>
|
||||
* </ul>
|
||||
*
|
||||
* @return a configured {@link SnowflakeIdentityGenerator} instance for generating user IDs
|
||||
* @see SnowflakeIdentityGenerator
|
||||
* @see IdentityGenerator
|
||||
*/
|
||||
@Bean
|
||||
public IdentityGenerator<Long> userIdentityGenerator() {
|
||||
return new SnowflakeIdentityGenerator(0x0, 0x0);
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package com.onixbyte.helix.config;
|
||||
|
||||
import com.fasterxml.jackson.databind.SerializationFeature;
|
||||
import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule;
|
||||
import com.onixbyte.helix.common.jackson.JacksonModules;
|
||||
import org.springframework.boot.autoconfigure.jackson.Jackson2ObjectMapperBuilderCustomizer;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
|
||||
Reference in New Issue
Block a user