Thanks for the suggestions @demobox, PR was already merged but i added those
improvements here https://github.com/jclouds/jclouds/pull/1215
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
demobox commented on this pull request.
> + */
+@Singleton
+public class AzureNameValidator extends Validator {
+ private final int min = 2;
+ private final int max = 63;
+
+ public void validate(String name) {
+
+ if (name == null || name.length() < min || name.length() > max)
+
demobox commented on this pull request.
> +/**
+ * Validates name for azure entities
+ *
https://docs.microsoft.com/en-us/azure/architecture/best-practices/naming-conventions
+ *
+ * @see org.jclouds.predicates.Validator
+ */
+@Singleton
+public class AzureNameValidator extends Validator {
+
demobox commented on this pull request.
> +
+import org.jclouds.predicates.Validator;
+
+import com.google.common.base.CharMatcher;
+import com.google.inject.Singleton;
+
+/**
+ * Validates name for azure entities
+ *
Pushed to master and 2.1.x. Thanks!
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/1213#issuecomment-391969708
Closed #1213.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/1213#event-1646000469
nacx approved this pull request.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/1213#pullrequestreview-123270045
Added a test! (and fixed an error message by the way) with all the main cases i
could think of @nacx
Also, i added this class under _org.jclouds.azurecompute.arm.config.*_ not sure
if it's the best place so feel free to suggest any other one
--
You are receiving this because you are
Please add unit tests that verify the validator and test the corner cases.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/1213#issuecomment-391515264
You can view, comment on, or merge this pull request online at:
https://github.com/jclouds/jclouds/pull/1213
-- Commit Summary --
* Adds new more relaxed validator for Azure entities
-- File Changes --
A
10 matches
Mail list logo