scottyaslan commented on code in PR #10347:
URL: https://github.com/apache/nifi/pull/10347#discussion_r2388248587


##########
nifi-frontend/src/main/frontend/apps/nifi-registry/src/app/service/about.service.ts:
##########
@@ -0,0 +1,43 @@
+/*
+ * 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.
+ */
+
+import { inject, Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { Observable } from 'rxjs';
+import { LoadAboutResponse } from '../state/about';
+
+@Injectable({ providedIn: 'root' })
+export class AboutService {
+    private httpClient = inject(HttpClient);
+
+    private static readonly API: string = '../nifi-registry-api';
+
+    getAbout(): Observable<LoadAboutResponse> {
+        // const mockError: HttpErrorResponse = new HttpErrorResponse({

Review Comment:
   I think we do want to keep these here. They are here to make it easy to test 
all the error handling scenarios. We don't want to leave the error scenario 
turned on for the dev server as we want the application to behave normally but 
we want to be able to quickly test error scenarios.



##########
nifi-frontend/src/main/frontend/apps/nifi-registry/src/app/service/about.service.ts:
##########
@@ -0,0 +1,43 @@
+/*
+ * 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.
+ */
+
+import { inject, Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { Observable } from 'rxjs';
+import { LoadAboutResponse } from '../state/about';
+
+@Injectable({ providedIn: 'root' })
+export class AboutService {
+    private httpClient = inject(HttpClient);
+
+    private static readonly API: string = '../nifi-registry-api';
+
+    getAbout(): Observable<LoadAboutResponse> {
+        // const mockError: HttpErrorResponse = new HttpErrorResponse({

Review Comment:
   I think we do want to keep these here. They are here to make it easy to test 
all the error handling scenarios. We don't want to leave the error scenario 
turned on for the dev server as we want the application to behave normally but 
we want to be able to quickly test error scenarios.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to