Skip to content
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

replace some interceptor for events #247

Closed
Turini opened this issue Nov 2, 2013 · 10 comments · Fixed by #281
Closed

replace some interceptor for events #247

Turini opened this issue Nov 2, 2013 · 10 comments · Fixed by #281
Assignees
Milestone

Comments

@Turini
Copy link
Member

Turini commented Nov 2, 2013

There are a few interceptors that can be easily replaced by CDI events. If events
get a higher performance, we could migrate these cases (need to be well tested)

@ghost ghost assigned Turini Nov 2, 2013
@Turini
Copy link
Member Author

Turini commented Nov 2, 2013

I'm starting some performance tests here.

@asouza
Copy link
Contributor

asouza commented Nov 2, 2013

To make this change, you have to create objects that represent each point
point of the request flow... It would be nice see some examples.
Em 02/11/2013 14:26, "Rodrigo Turini" notifications@github.com escreveu:

I'm starting some performance tests here.


Reply to this email directly or view it on GitHubhttps://github.com//issues/247#issuecomment-27625385
.

@Turini
Copy link
Member Author

Turini commented Nov 2, 2013

It would be nice see some examples.

wait a second and you'll see an example :)

@Turini
Copy link
Member Author

Turini commented Nov 2, 2013

related PR #248 opened, as a simple example.

@garcia-jj
Copy link
Member

Performance results?

@Turini
Copy link
Member Author

Turini commented Nov 5, 2013

Performance results?

I'll share it soon @garcia-jj, promise! Time is not being my friend :)

@garcia-jj
Copy link
Member

Ok, just to feed my curiosity. If performance still good or better, we can implement this change to all interceptors like serialization, download and so on.

@Turini
Copy link
Member Author

Turini commented Nov 5, 2013

we can implement this change to all interceptors like serialization, download and so on.

Yes! We can use events for this specific cases. I'm changing all this possible interceptors, just for
tests. If it works fine with a good or better performance (and a good design too) I'll send some PRs =)

@Turini
Copy link
Member Author

Turini commented Nov 26, 2013

With these last two PRs, we have now: OutjectResult, Download, Upload (plus NullUpload), Deserializing, ParameterIncluder, Instantiate and ControllerLookup observing CDI events.
There is any other case that do you think it is worth to migrate? If there is not, we can close this issue :)

@lucascs
Copy link
Member

lucascs commented Nov 26, 2013

I'd change all infrastructure interceptors to Observers... ControllerLookup => ParametersInstantiator => Instantiate => MethodExecutor (with the interceptor stack inside it)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants