-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding message page, for better content sharing #381
Conversation
@Particular/servicepulse-maintainers please review. The PR for SC was merged, but now I need to learn when it will be released. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! A couple of suggestions around how we handle the promises for the serviceControlService
service, but other than that 👍
}; | ||
|
||
vm.archiveMessage = function () { | ||
serviceControlService.archiveFailedMessages([vm.message.message_id]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change the archiveFailedMessages
method to return the promise so that it's the same as the restoreMessageFromArchive
method?
It also means we can chain the vm.message.archived = true;
line onto only the success portion of the POST. In case the network is down or something goes wrong with the actual HTTP comms, then we won't set the archived flag to true incorrectly.
}; | ||
|
||
vm.retryMessage = function () { | ||
serviceControlService.retryFailedMessages([vm.message.message_id]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change the retryFailedMessages
method to return the promise so that it's the same as the restoreMessageFromArchive
method?
It also means we can chain the vm.message.retried = true;
line onto only the success portion of the POST. In case the network is down or something goes wrong with the actual HTTP comms, then we won't set the retried flag to true incorrectly.
👍 |
0df559f
to
e28f171
Compare
@WojcikMike this is not released as part of v1.24. To use it call |
@johnsimons ok will revisit this PR |
f751648
to
55d4c6c
Compare
6a0c066
to
7606813
Compare
@sergioc I did the changes, you can navigate to the message page by going to failed messages screen and clicking on a message name |
- restored row hover state in All Failed Messages / Group detail views - updated message detail page
1347501
to
c4e583f
Compare
@Particular/servicepulse-maintainers can you please review? We believe it is ready to be shipped |
…king for failed message groups
@@ -51,7 +51,7 @@ | |||
</div> | |||
|
|||
<div class="col-xs-11 failed-message-data" ng-mouseenter="message.hover2 = true" ng-mouseleave="message.hover2 = false"> | |||
<a href="#/failedMessages/{{message.id}}"> | |||
<a href="#/message/{{message.id}}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@WojcikMike isn't an invidual message a child of all /failedMessages?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is and it isn't :)
Previously our URL's looked as follows:
/failedMessages - failed mesasges screen
/failedMessages/{{id}} - one message screen
Becasue @WilliamBZA made a pr to provide deep linking groups he used "our" url path, so currently it looks like this:
/failedMessages - failed mesasges screen
/failedMessages/{{id}} - failed messages screen with a group of given id selected
Which means that we lacked url for this feature. Now becasue on our page we show a bit more than only failed message (as it can also be archived message, or succesfful processed message) I decided to go with path:
/message/{{id}}
What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From a nav perspective, /failedMessages
is parent of both groups and individual messages, so I'd nest both children under the parent. I'd also avoid two words in oneWord to improve legibility of the URL, as well as caps. So I'd use this structure in the end:
/failed-messages
/failed-messages/group/{{group.id}}
/failed-messages/message/{{message.id}}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Even that it looks nice, I don't like it :D.
With regards to groups, It should be more of:
/group/{{group.id}}/failed-messages
As the group is the parent entity that we care about, and group contains failed messages. So for me ^^ look more natural.
With regards to message path, as we are showing also archived messages I think we should not keep it under failed-message umbrela. Either way, I would tackle this as a separate issue, simply becasue group id path is already out there. And we can do the change of the URL's as a separate initiative with redirects from old paths to new etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Either way, I would tackle this as a separate issue, simply becasue group id path is already out there.
Yeah, thought about that as soon as I started seeing you disagree :-)
Let's leave URL formatting out of the picture for now and release the rest.
@@ -65,7 +65,7 @@ <h3 class="active group-title group-message-count">{{vm.selectedExceptionGroup.c | |||
</div> | |||
|
|||
<div class="col-xs-11 failed-message-data" ng-mouseenter="message.hover2 = true" ng-mouseleave="message.hover2 = false"> | |||
<a href="#/failedMessages/{{message.id}}"> | |||
<a href="#/message/{{message.id}}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@WojcikMike isn't an invidual message a child of all /failedMessages?
@@ -390,7 +391,7 @@ h3 { | |||
border-radius: 4px; | |||
color: #777f7f; | |||
display: block; | |||
height: 130px; | |||
// height: 130px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Commented out?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@WojcikMike I'll fix this once you're done with your changes. Or you can just remove the commented out line yourself.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I already removed it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
$controller = _$controller_; | ||
})); | ||
|
||
describe('retrying message', function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we improve the names of these tests? It's a bit hard to see what is being tested at a glance.
Perhaps: when retrying a message
I mean, we can be quite verbose with qUnit.
}); | ||
})); | ||
|
||
it('message marked as resolved', function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps: and the retry succeeds, the message is marked as resolved
expect(serviceControlService.retryFailedMessages).toHaveBeenCalled(); | ||
}); | ||
|
||
it('failed, message not marked as resolved', function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps and the retry fails, the message is not marked as resolved
}); | ||
}); | ||
|
||
describe('archiving message', function () { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps when archiving a message
vm.retryMessage = function () { | ||
serviceControlService.retryFailedMessages([vm.message.id]) | ||
.then(function() { | ||
toastService.showInfo("Retrying the message " + vm.message.message_id + " ..."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably be shown before the promise completes
vm.archiveMessage = function () { | ||
serviceControlService.archiveFailedMessages([vm.message.id]) | ||
.then(function() { | ||
toastService.showInfo("Archiving the message " + vm.message.message_id + " ..."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should probably be shown before the promise completes
}; | ||
|
||
//to be deleted | ||
vm.resolveButtonClicked = function() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to be deleted?
}); | ||
}; | ||
|
||
function calculateDeleteDate(message, errorRetentionPeriod) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
calculate
to me means a single result (an answer) will be provided, but this method mutates the incoming object.
Maybe the name should be updateMessageDeleteDate
?
|
||
\pard\widctlpar\sb240\sa240\b0 YOU EXPRESSLY ACKNOWLEDGE THAT YOU HAVE READ THESE TERMS AND UNDERSTAND THE RIGHTS, OBLIGATIONS, TERMS AND CONDITIONS SET FORTH HEREIN. BY CLICKING ON THE AGREE BUTTON AND/OR CONTINUING TO INSTALL OR USE THE SOFTWARE, YOU EXPRESSLY CONSENT TO BE BOUND BY THESE TERMS.\par | ||
} | ||
{\rtf1\ansi\ansicpg1252\deff0\nouicompat\deflang3081\deflangfe3081{\fonttbl{\f0\fswiss\fprq2\fcharset0 Calibri;}{\f1\froman\fprq2\fcharset0 Times New Roman;}{\f2\fswiss\fprq2 Calibri;}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What are these changes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
THe file before and after is identical, I think that this checkin sneaked upon me ;)
I suspect this was not a small and should not have been done under maintainer budget. Do you both still think the small label was appropriate? If not, how can we better our triage process so we don't make a similar mistake again? |
With regards to it being bigger than small. Yes overall I think it was. At first it seemed like small anough but after I brough @sergioc in he wanted to work on the experience between the screens to make them better and consistent. And that brough additional work. I would risk a statement that we can't make anything small when it includes UI changes. |
I wouldn't generalize it like that. That would make UI changes difficult to do because it would suffer on prioritization. This is especially dangerous since the main component of SP is the UI. There's also the question of what's the definition of small. Is it the no. of work hours? Lines of code? Time the issue sits in progress? I can only correctly assess size if the criteria for sizing is clear. |
@WilliamBZA I believe that all your suggestions were addressed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. I neatened up some promises that weren't changed by you guys too. LGTM.
Are we going to hold on shipping this until we've done #402?
I've also added #404 to the same milestone |
Also, I think this should be a squash merge |
@WilliamBZA the maintainers agreed #402 is indispensable, so I added it to the same milestone. |
Fixes #331
This PR requires corresponding change in SC to happen