All notable changes to this project will be documented in this file.
Nothing unreleased.
5.2.6 - 2024-01-02
- Optimized format method.
- Refactored optimize the character map.
- Replace
synchronizedkeyword withReentrantLock. - Fixed
ArrayIndexOutOfBoundsExceptionwith multiple bytes for a character. #31
5.2.5 - 2023-09-03
- Optimized base-n encode and decode methods.
- Refactored to use a
LongSupplierinstead of aClockfor getting the current time.
5.2.4 - 2023-05-04
Using the Tsid.encode method in the JDK 8 environment #28
5.2.3 - 2023-02-11
Fix sync #26
5.2.2 - 2023-02-04
Reduce synchronization scope when generating the TSID #25
5.2.1 - 2023-01-28
Fix incremental generation (by Francesco Illuminati) #24 Validate the node ID passed to the builder #23
5.2.0 - 2022-12-23
Add simple format methods #20
5.1.1 - 2022-12-18
Docs update
5.1.0 - 2022-12-17
- Added the system property and environment variable to configure the node count. #19
- Added a fast method to generate identifiers. #18
5.0.2 - 2022-09-17
Rewrite docs. #17
5.0.1 - 2022-08-21
Optimized comparison and hash. #16
5.0.0 - 2022-07-09
Add support for RandomGenerator in Java 17. #15
4.2.1 - 2022-04-21
Handle clock drift #14
4.2.0 - 2022-04-14
Handle clock drift #14
4.1.4 - 2021-11-28
Regular maintenance.
4.1.3 - 2021-11-20
Increment the counter when the random function returns null or empty. (undone in v5.0.0)
4.1.2 - 2021-11-19
Compare internal field as unsigned integers.
4.1.1 - 2021-10-03
Regular maintenance.
4.1.0 - 2021-09-04
Add OSGi entries to Manifest.MF #11
Module and bundle names are the same as the root package name.
The OSGi symbolic name is the same as the JPMS module name: com.github.f4b6a3.tsid.
4.0.0 - 2021-08-08
Now you call TsidFactory.newInstance1024() and it's variants to get a new TsidFactory.
- Added
TsidFactory.Builder - Added
TsidFactory.newInstance256() - Added
TsidFactory.newInstance256(int) - Added
TsidFactory.newInstance1024() - Added
TsidFactory.newInstance1024(int) - Added
TsidFactory.newInstance4096() - Added
TsidFactory.newInstance4096(int) - Added benchmark code to compare TSID with UUID
- Removed
TsidTime - Removed
Tsid.toUpperCase()
3.0.3 - 2021-07-18
Regular mantainence
3.0.2 - 2021-07-17
Module name for Java 9+ #7
-
Added
-
Added this line to MANIFEST.MF:
Automatic-Module-Name: com.github.f4b6a3.tsid
- Updated README.md
- Updated pom.xml
3.0.1 - 2021-01-31
Updates README.md and javadoc
3.0.0 - 2021-01-30
Simplifies the tsid-creator.
The version 3.0.0 breaks compatibility.
Teste coverage: 82,2%
- Added
Tsid - Added
TsidFactory - Added test cases
- Updated README.md
- Updated test cases
- Updated javadoc
- Removed
TimeIdCreator - Removed
InvalidTsidException - Removed
TimestampStrategy - Removed
DefaultTimestampStrategy - Removed
FixedTimestampStrategy - Removed
TsidConverter - Removed
TsidUtil - Remvoed
TsidValidator - Removed test cases
2.4.4 - 2020-11-16
- Added
TimeIdCreator00064Test// test with up to 64 nodes - Added
TimeIdCreator16384Test// test with up to 16k nodes
- Change
TsidUtil// remove unused code - Change
TsidUtilTest// remove unused code - Optimize
TimeIdCreator// small optimization - Optimize
TsidConverter// small optimization - Optimize
TsidValidator// add methods for char[] args - Update README.md
2.4.3 - 2020-11-09
Changed TsidValidator to check the maximum value.
Optimization of the TSID validation.
2.4.2 - 2020-11-08
Changed TsidValidator to check the maximum value.
2.4.1 - 2020-11-08
Changed validate() access to public.
2.4.0 - 2020-11-08
Optimized the generation of TSID in string format.
Now the generation of TSID in string format is 27% faster than before.
Coverage 94%
- Add test cases
- Rename
TsidSettingstoTsidCreatorSettings - Optimize
TimeIdCreator - Optimize
TsidConverter - Optimize
TsidValidator - Update README.md
2.3.0 - 2020-10-17
- Added
TsidCreator.toString()
- Change
TimeIdCreator// wait the next millisecond like Snowflake does - Update test cases
- Update README.md
- Update javadoc
- Remove
TsidCreatorException
2.2.4 - 2020-07-15
Change TsidSetting.
- Chenge
TsidSettings.getNodeIdentifier()// return null if not found - Chenge
TimeIdCreator.getNodeIdentifier()// check if return is null - Update javadoc
- Update test cases
2.2.3 - 2020-07-14
Add more test cases for 256, 1024 and 4096 generators
Coverage: 91.8%
- Add
TimeIdCreator0001Test - Add
TimeIdCreator0256Test - Add
TimeIdCreator1024Test - Add
TimeIdCreator4096Test
- Update TestSuite
- Update README.md
- Remove
TimeIdCreatorTest
2.2.2 - 2020-07-13
Make TsidSettings.getNodeIdentifier() to return -1 when property is not found, empty or invalid. ZERO is a valid node ID.
- Changed
TsidSettings.getNodeIdentifier()
2.2.1 - 2020-07-13
- Rename
TsidCreator.getTsid()togetTsid1024() - Rename
TsidCreator.getTsidString()togetTsidString1024() - Rename
TsidCreator.getTimeIdCreator()togetTimeIdCreator1024() - Rename
TsidCreator.getTimeIdCreator(node)togetTimeIdCreator1024(node)
2.2.0 - 2020-07-13
The TSID structure without node id was removed.
Now its possible to define the node id using a system property tsidcreator.node or an environment variable TSIDCREATOR_NODE.
- Added
TsidCreator.getTsid256()// up to 256 nodes - Added
TsidCreator.getTsid4096()// up to 4096 nodes - Added
TsidCreator.getTsidString256()// up to 256 nodes - Added
TsidCreator.getTsidString4096()// up to 4096 nodes - Added
TsidCreator.getTimeIdCreator256()// up to 256 nodes - Added
TsidCreator.getTimeIdCreator4096()// up to 4096 nodes - Added
TsidSetings// for node id definition via property or variable - Added
TimeIdCreator// unique generator for all types of TSID
- Renamed
TsidTimeUtiltoTsidTime - Update README.md
- Update test cases
- Update pom.xml
- Removed
TsidCreator.getTsid(int node)// use TimeIdCreator instead - Removed
TsidCreator.getTsidString(int node)// use TimeIdCreator instead - Removed
TimeIdCreator(interface) // there's generator hierarchy anymore - Removed
AbstractTimeIdCreator// there's generator hierarchy anymore - Removed
SimpleTimeIdCreator// there's generator hierarchy anymore - Removed
NodeTimeIdCreator// there's generator hierarchy anymore - Removed
AjustableTimeIdCreator// there's generator hierarchy anymore
2.1.1 - 2020-07-06
- Fixed
AbstractTimeIdCrator.increment()
2.1.0 - 2020-07-04
- Added
TsidCrator.fromString() - Add test cases
- Renamed
DefaultTimeIdCreatortoSimpleTimeIdCreator - Renamed
AdjustableNodeTimeIdCreatortoAdjustableTimeIdCreator - Optimized
AbstractTimeIdCreator - Optimize
SimpleTimeIdCreator - Optimized
AdjustableTimeIdCreator - Optimized
NodeTimeIdCreator - Optimized
TsidConverter.fromString() - Optimize
TsidConverter.toString() - Optimize
TsidValidator.isValid(String) - Update test cases
- Update README.md
- Removed
TsidConverter.fromBytes() - Remove
TsidConverter.toBytes() - Remove
TsidValidator.isValid(byte[])
2.0.0 - 2020-05-25
- Added
AbstractTimeIdCreator - Added
DefaultTimeIdCreator - Added
NodeTimeIdCreator - Added
AdjustableNodeTimeIdCreator
- Renamed
TimeSortableIdCreatortoTimeIdCreator - Updated
TsidCreator - Updated README.md
- Updated test cases
1.0.2 - 2020-04-19
- Updated pom.xml
1.0.1 - 2020-04-18
- Fixed package name in two test cases
1.0.0 - 2020-04-17
Project created as an alternative Java implementation for Twitter's Snowflake.
- Added
TsidCreator - Added
TimeSortableIdCreator - Added
TimestampStrategy - Added
DefaultTimestampStrategy - Added
FixedTimestampStrategy - Added
TsidUtil - Added
TsidConverter - Added
TsidTimeUtil - Added
TsidValidator - Added
TsidCreatorException - Added
InvalidTsidException - Added
README.md - Added
pom.xml - Added
LICENSE - Added test cases