Not really, 150 chars String is relatively trivial to calculate an hashCode
for.
That being said, in circumstances like this I would advise you to test it!
Create a routine that populates an HashMap with, say, insert a size here that is representative of your use scenario random values with 5 character strings as keys. Measure how long it takes. Then do the same for 15 character keys, and see how it scales.
Also, Strings in Java are immutable, which means that hashCode
can be cached for each String that is stored in the String Constant Pool, and doesn't need to be recalculated when you call hashCode on the same String object.
This means that although you're calculating larger hash codes when creating your map, on access many of those will already be pre-calculated and cached, making the size of the original String even less relevant.