[GitHub] nifi pull request #1718: NIFI-391 - Introduce the ability to deprecate a com...
Github user asfgit closed the pull request at: https://github.com/apache/nifi/pull/1718 --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] nifi pull request #1718: NIFI-391 - Introduce the ability to deprecate a com...
Github user trixpan commented on a diff in the pull request: https://github.com/apache/nifi/pull/1718#discussion_r116357827 --- Diff: nifi-api/src/main/java/org/apache/nifi/annotation/documentation/DeprecationNotice.java --- @@ -0,0 +1,51 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); 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 org.apache.nifi.annotation.documentation; + +import org.apache.nifi.components.ConfigurableComponent; + +import java.lang.annotation.Documented; +import java.lang.annotation.ElementType; +import java.lang.annotation.Inherited; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +/** + * Annotation that can be applied to a {@link org.apache.nifi.processor.Processor Processor}, + * {@link org.apache.nifi.controller.ControllerService ControllerService}, or + * {@link org.apache.nifi.reporting.ReportingTask ReportingTask} in order to + * warn about the deprecation of the component. The deprecation warning is informational only + * and doesn't affect the processor run time behavior in any way + */ +@Documented +@Target({ElementType.TYPE}) +@Retention(RetentionPolicy.RUNTIME) +@Inherited +public @interface DeprecationNotice { +Class[] value() default {}; + +String[] classNames() default {}; + +String reason() default ""; + + +// The following are still not utilised but implemented +// for future use. +String deprecationTargetVersion() default ""; --- End diff -- @mcgilman yeah. happy for you to remove --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] nifi pull request #1718: NIFI-391 - Introduce the ability to deprecate a com...
Github user mcgilman commented on a diff in the pull request: https://github.com/apache/nifi/pull/1718#discussion_r116357519 --- Diff: nifi-api/src/main/java/org/apache/nifi/annotation/documentation/DeprecationNotice.java --- @@ -0,0 +1,51 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); 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 org.apache.nifi.annotation.documentation; + +import org.apache.nifi.components.ConfigurableComponent; + +import java.lang.annotation.Documented; +import java.lang.annotation.ElementType; +import java.lang.annotation.Inherited; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +/** + * Annotation that can be applied to a {@link org.apache.nifi.processor.Processor Processor}, + * {@link org.apache.nifi.controller.ControllerService ControllerService}, or + * {@link org.apache.nifi.reporting.ReportingTask ReportingTask} in order to + * warn about the deprecation of the component. The deprecation warning is informational only + * and doesn't affect the processor run time behavior in any way + */ +@Documented +@Target({ElementType.TYPE}) +@Retention(RetentionPolicy.RUNTIME) +@Inherited +public @interface DeprecationNotice { +Class[] value() default {}; + +String[] classNames() default {}; + +String reason() default ""; + + +// The following are still not utilised but implemented +// for future use. +String deprecationTargetVersion() default ""; --- End diff -- Ah ok. I would probably lean towards the 'remove it' side for now. I think there are lots of options for showing what's deprecated, what has newer versions available (but may not be deprecated), what components the user should use instead, etc. If you're ok with removing it, I can handle deleting those three lines during the merge. The rest looks good. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] nifi pull request #1718: NIFI-391 - Introduce the ability to deprecate a com...
Github user trixpan commented on a diff in the pull request: https://github.com/apache/nifi/pull/1718#discussion_r116357266 --- Diff: nifi-api/src/main/java/org/apache/nifi/annotation/documentation/DeprecationNotice.java --- @@ -0,0 +1,51 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); 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 org.apache.nifi.annotation.documentation; + +import org.apache.nifi.components.ConfigurableComponent; + +import java.lang.annotation.Documented; +import java.lang.annotation.ElementType; +import java.lang.annotation.Inherited; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +/** + * Annotation that can be applied to a {@link org.apache.nifi.processor.Processor Processor}, + * {@link org.apache.nifi.controller.ControllerService ControllerService}, or + * {@link org.apache.nifi.reporting.ReportingTask ReportingTask} in order to + * warn about the deprecation of the component. The deprecation warning is informational only + * and doesn't affect the processor run time behavior in any way + */ +@Documented +@Target({ElementType.TYPE}) +@Retention(RetentionPolicy.RUNTIME) +@Inherited +public @interface DeprecationNotice { +Class[] value() default {}; + +String[] classNames() default {}; + +String reason() default ""; + + +// The following are still not utilised but implemented +// for future use. +String deprecationTargetVersion() default ""; --- End diff -- @mcgilman - I placed it in there to address a commend from the list (I think it was Andy's suggestion to have it) but given I think it will take a while before we can truly agree on deprecating something by version X, it may be reasonable to remove it for now. From the other hand, unless you foresee this going into the UI we may well adjust the documentation generation logic to take this field in consideration. Happy with whatever you prefer. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] nifi pull request #1718: NIFI-391 - Introduce the ability to deprecate a com...
GitHub user trixpan opened a pull request: https://github.com/apache/nifi/pull/1718 NIFI-391 - Introduce the ability to deprecate a component Thank you for submitting a contribution to Apache NiFi. In order to streamline the review of the contribution we ask you to ensure the following steps have been taken: ### For all changes: - [X] Is there a JIRA ticket associated with this PR? Is it referenced in the commit message? - [X] Does your PR title start with NIFI- where is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character. - [X] Has your PR been rebased against the latest commit within the target branch (typically master)? - [ ] Is your initial contribution a single, squashed commit? ### For code changes: - [X] Have you ensured that the full suite of tests is executed via mvn -Pcontrib-check clean install at the root nifi folder? - [X] Have you written or updated unit tests to verify your changes? - [X] ~~~If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under [ASF 2.0](http://www.apache.org/legal/resolved.html#category-a)?~~~ - [X] ~~~If applicable, have you updated the LICENSE file, including the main LICENSE file under nifi-assembly?~~~ - [X] ~~~If applicable, have you updated the NOTICE file, including the main NOTICE file found under nifi-assembly?~~~ - [X] ~~~If adding new Properties, have you added .displayName in addition to .name (programmatic access) for each of the new properties?~~~ ### For documentation related changes: - [X] Have you ensured that format looks appropriate for the output in which it is rendered? ### Note: Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible. You can merge this pull request into a Git repository by running: $ git pull https://github.com/trixpan/nifi NIFI-391 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/nifi/pull/1718.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1718 commit f4caef7b396701cda601749bb0e54cf5f5ba84d3 Author: Andre F de MirandaDate: 2017-04-29T03:09:22Z NIFI-3761 - adjust testFullyDocumentedProcessor to correctly eval to false when needed commit eca1e2a465bedab060f26b2804e7e6d8c55b7e22 Author: Andre F de Miranda Date: 2017-04-29T06:06:15Z NIFI-391 - Introduce the ability to deprecate a component NIFI-439 - Allow documentation to inform user about deprecation of a component --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---