Skip to content

Commit

Permalink
fix: pr comments
Browse files Browse the repository at this point in the history
  • Loading branch information
sattvikc committed May 7, 2024
1 parent 046a244 commit 7f2a091
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 7 deletions.
7 changes: 1 addition & 6 deletions src/main/java/io/supertokens/config/CoreConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,9 @@
import com.google.gson.JsonObject;
import io.supertokens.Main;
import io.supertokens.cliOptions.CLIOptions;
import io.supertokens.config.annotations.ConfigYamlOnly;
import io.supertokens.config.annotations.EnumProperty;
import io.supertokens.config.annotations.IgnoreForAnnotationCheck;
import io.supertokens.config.annotations.NotConflictingInApp;
import io.supertokens.multitenancy.Multitenancy;
import io.supertokens.config.annotations.*;
import io.supertokens.pluginInterface.ConfigFieldInfo;
import io.supertokens.pluginInterface.LOG_LEVEL;
import io.supertokens.pluginInterface.annotations.ConfigDescription;
import io.supertokens.pluginInterface.exceptions.InvalidConfigException;
import io.supertokens.pluginInterface.multitenancy.TenantIdentifier;
import io.supertokens.pluginInterface.multitenancy.exceptions.TenantOrAppNotFoundException;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/*
* Copyright (c) 2024, VRAI Labs and/or its affiliates. All rights reserved.
*
* This software is licensed under the Apache License, Version 2.0 (the
* "License") as published by the Apache Software Foundation.
*
* You may not use this file except in compliance with the License. You may
* obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*/

package io.supertokens.config.annotations;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* Annotation to provide a description for a configuration fields. To be used on the fields of `CoreConfig` and config
* class in the plugin like `PostgreSQLConfig`, `MysqlConfig`, etc.
*/
@Retention(RetentionPolicy.RUNTIME) // Make annotation accessible at runtime so that config descriptions can be read from API
@Target(ElementType.FIELD) // Annotation can only be applied to fields
public @interface ConfigDescription {
String value(); // String value that provides a description for the configuration field
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
import com.google.gson.JsonObject;
import io.supertokens.ProcessState;
import io.supertokens.config.CoreConfig;
import io.supertokens.config.annotations.ConfigDescription;
import io.supertokens.httpRequest.HttpRequest;
import io.supertokens.pluginInterface.annotations.ConfigDescription;
import io.supertokens.test.TestingProcessManager;
import io.supertokens.test.Utils;

Expand Down

0 comments on commit 7f2a091

Please sign in to comment.