You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@james.apache.org by GitBox <gi...@apache.org> on 2021/04/08 08:49:24 UTC

[GitHub] [james-project] quantranhong1999 opened a new pull request #371: JAMES-3429 Add StateMismatch error type

quantranhong1999 opened a new pull request #371:
URL: https://github.com/apache/james-project/pull/371


   


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] chibenwa merged pull request #371: JAMES-3429 Add StateMismatch error type and getLatestVersion FilteringManagement

Posted by GitBox <gi...@apache.org>.
chibenwa merged pull request #371:
URL: https://github.com/apache/james-project/pull/371


   


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] Arsnael commented on pull request #371: JAMES-3429 Add StateMismatch error type and getLatestVersion FilteringManagement

Posted by GitBox <gi...@apache.org>.
Arsnael commented on pull request #371:
URL: https://github.com/apache/james-project/pull/371#issuecomment-817436985


   Build restarted


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] chibenwa commented on a change in pull request #371: JAMES-3429 Add StateMismatch error type

Posted by GitBox <gi...@apache.org>.
chibenwa commented on a change in pull request #371:
URL: https://github.com/apache/james-project/pull/371#discussion_r609469607



##########
File path: server/data/data-jmap/src/main/java/org/apache/james/jmap/api/exception/StateMismatchException.java
##########
@@ -0,0 +1,32 @@
+/****************************************************************
+ * 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.james.jmap.api.exception;
+
+public class StateMismatchException extends RuntimeException {
+    public StateMismatchException(String msg) {
+        super(msg);
+    }
+
+    public static void checkState(boolean expression, String msg) {

Review comment:
       static methods come first




-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] chibenwa commented on a change in pull request #371: JAMES-3429 Add StateMismatch error type

Posted by GitBox <gi...@apache.org>.
chibenwa commented on a change in pull request #371:
URL: https://github.com/apache/james-project/pull/371#discussion_r609474786



##########
File path: server/data/data-jmap/src/main/java/org/apache/james/jmap/api/exception/StateMismatchException.java
##########
@@ -0,0 +1,32 @@
+/****************************************************************
+ * 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.james.jmap.api.exception;
+
+public class StateMismatchException extends RuntimeException {

Review comment:
       Maybe we can extend IllegalStateException ?




-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] chibenwa commented on pull request #371: JAMES-3429 Add StateMismatch error type

Posted by GitBox <gi...@apache.org>.
chibenwa commented on pull request #371:
URL: https://github.com/apache/james-project/pull/371#issuecomment-815580313


   Drop 124644c commit


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] quantranhong1999 commented on pull request #371: JAMES-3429 Add StateMismatch error type and getLatestVersion FilteringManagement

Posted by GitBox <gi...@apache.org>.
quantranhong1999 commented on pull request #371:
URL: https://github.com/apache/james-project/pull/371#issuecomment-820025425


   Don't know why this keep failing, just a rebase and make the ci run again.


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] quantranhong1999 commented on pull request #371: JAMES-3429 Add StateMismatch error type and getLatestVersion FilteringManagement

Posted by GitBox <gi...@apache.org>.
quantranhong1999 commented on pull request #371:
URL: https://github.com/apache/james-project/pull/371#issuecomment-816590627


   Tests faild on CI:
   ```
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.setRulesWithIfInStateIsOneWhenNonStateIsDefinedShouldFail{EventStore}
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.setRulesWithIfInStateIsInitialWhenAStateIsDefinedShouldFail{EventStore}
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.modifyExistingRulesWithWrongCurrentVersionShouldFail{EventStore}
   ```
   But green on local, please rerun the build


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org


[GitHub] [james-project] quantranhong1999 edited a comment on pull request #371: JAMES-3429 Add StateMismatch error type and getLatestVersion FilteringManagement

Posted by GitBox <gi...@apache.org>.
quantranhong1999 edited a comment on pull request #371:
URL: https://github.com/apache/james-project/pull/371#issuecomment-816590627


   Tests failed on CI:
   ```
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.setRulesWithIfInStateIsOneWhenNonStateIsDefinedShouldFail{EventStore}
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.setRulesWithIfInStateIsInitialWhenAStateIsDefinedShouldFail{EventStore}
   org.apache.james.jmap.cassandra.filtering.CassandraEventSourcingFilteringManagementTest.modifyExistingRulesWithWrongCurrentVersionShouldFail{EventStore}
   ```
   But green on local, please rerun the build


-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org