You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by tomjenkinson <gi...@git.apache.org> on 2016/01/19 13:13:50 UTC

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

GitHub user tomjenkinson opened a pull request:

    https://github.com/apache/activemq-artemis/pull/326

    ARTEMIS-351 throw an exception if we get an IOException

    https://issues.apache.org/jira/browse/ARTEMIS-351

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/tomjenkinson/activemq-artemis JBEAP-1987

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/activemq-artemis/pull/326.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 #326
    
----
commit 33128e1eb845c399b3735120a3b53233adfdc475
Author: Tom Jenkinson <to...@redhat.com>
Date:   2016-01-15T20:55:06Z

    ARTEMIS-351 throw an exception if we get an IOException

----


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by tomjenkinson <gi...@git.apache.org>.
Github user tomjenkinson commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172857600
  
    squished thanks


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/activemq-artemis/pull/326


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by tomjenkinson <gi...@git.apache.org>.
Github user tomjenkinson commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172856253
  
    any better? I am throwing the one that the IO handler gets too as that seems consistent?


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by andytaylor <gi...@git.apache.org>.
Github user andytaylor commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172852039
  
    not quite tom, 
    
    throw ActiveMQJournalBundle.BUNDLE.someException();


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by clebertsuconic <gi...@git.apache.org>.
Github user clebertsuconic commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172924570
  
    There's a checkstyle error, but I will be able to amend before commit.
    
    (Please make sure you rebase against master after I merge this).


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by andytaylor <gi...@git.apache.org>.
Github user andytaylor commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172856746
  
    perfect


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by tomjenkinson <gi...@git.apache.org>.
Github user tomjenkinson commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172835703
  
    I think I made the change you asked for - I will squash it if that is what you were asking for.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by andytaylor <gi...@git.apache.org>.
Github user andytaylor commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/326#discussion_r50105212
  
    --- Diff: artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/JournalFilesRepository.java ---
    @@ -431,13 +434,16 @@ public JournalFile openFile() throws InterruptedException {
              openFilesExecutor.execute(pushOpenRunnable);
           }
     
    -      JournalFile nextFile = null;
    +      JournalFile nextFile = openedFiles.poll(5, TimeUnit.SECONDS);
    +      if (nextFile == null) {
    +         fileFactory.onIOError(ActiveMQJournalBundle.BUNDLE.fileNotOpened(), "unable to open ",  null);
    +      }
     
    -      while (nextFile == null) {
    -         nextFile = openedFiles.poll(5, TimeUnit.SECONDS);
    -         if (nextFile == null) {
    -            fileFactory.onIOError(ActiveMQJournalBundle.BUNDLE.fileNotOpened(), "unable to open ",  null);
    -         }
    +      if (nextFile == null) {
    +          // We need to reconnect the current file with the timed buffer as we were not able to roll the file forward
    +          // If you don't do this you will get a NPE in TimedBuffer::checkSize where it uses the bufferobserver 
    +          fileFactory.activateBuffer(journal.getCurrentFile().getFile());
    --- End diff --
    
    can you use the BUNDLE here Tom, see ActiveMQJournalBundle.BUNDLE


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by clebertsuconic <gi...@git.apache.org>.
Github user clebertsuconic commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172891962
  
    will run tests and merge it


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] activemq-artemis pull request: ARTEMIS-351 throw an exception if w...

Posted by tomjenkinson <gi...@git.apache.org>.
Github user tomjenkinson commented on the pull request:

    https://github.com/apache/activemq-artemis/pull/326#issuecomment-172857404
  
    Great - I will squash it then thanks


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---