[jira] [Commented] (TS-1827) minor improvement of combo_handler plugin

2013-05-05 Thread Conan Wang (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-1827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13649334#comment-13649334
 ] 

Conan Wang commented on TS-1827:


feature 1,2,3,5: 
https://github.com/wkl/trafficserver/compare/114f171...347478d686

encounter a problem for feature 4(when configure @plugin=combo_handler in 
remap.config):
{code}
ERROR: unable to load 
'/Users/conan/box/ts-trunk/libexec/trafficserver/combo_handler.so': 
dlopen(/Users/conan/box/ts-trunk/libexec/trafficserver/combo_handler.so, 2): 
Symbol not found: _threadKey
  Referenced from: /Users/conan/box/ts-trunk/lib/libesi.0.dylib
  Expected in: flat namespace
 in /Users/conan/box/ts-trunk/lib/libesi.0.dylib
{code}
any way to load esi.so for remap plugin?

feature 4's code 
https://github.com/wkl/trafficserver/commit/69a9135c4c65d8dd6308ee8557b016aba3bfd59c

> minor improvement of combo_handler plugin
> -
>
> Key: TS-1827
> URL: https://issues.apache.org/jira/browse/TS-1827
> Project: Traffic Server
>  Issue Type: Improvement
>  Components: Plugins
>Reporter: Conan Wang
>Assignee: Leif Hedstrom
> Fix For: 3.3.3
>
>
> Based on TS-1053, I've made some minor improvements. Community can select the 
> general ones to review.
> Changes: (separately pasted on pastebin temporally; may provide with commits 
> later after TS-1053 is solved on git master):
> # use HOST header as default bucket http://pastebin.com/pGHfLaHR
> Original code use the first segment of Host as the default bucket and it's 
> not that expandable (two different combo domain may have same leading 
> segment). Moreover, the initial default bucket("l") will not be used, because 
> all requests should have a HOST. 
> # sub-file's path need to contain querystring, i.e. question mark("?") is 
> part of the file path, not the delimiter http://pastebin.com/HvMJBQw0
> We use querystring to version each single sub-file in the combined url. If we 
> want to update/purge one of them, it can be simply accomplished by changing 
> the version of sub-file. (If not, you have to purge both the combined url and 
> sub-file url which is relatively hard to know the latter one when you are not 
> very familiar with ATS. Of course you can alter the filename if possible in 
> your site.)
> Then the combo url could be like 
> http://example.com/combo?file1?v=2012&file2?v=2013
> # request hangs when combo url has no querystring http://pastebin.com/d34ZJDzQ
> # make plugin per-remap enabled/disabled http://pastebin.com/YTaDYvh2
> It's implemented by adding some remap code and make global part "intercepted" 
> in TS_EVENT_HTTP_OS_DNS instead of TS_EVENT_HTTP_READ_REQUEST_HDR in order to 
> read the flag set in TSRemapDoRemap.
> So remap.config will be: {code}
> maphttp://example.com   http://os.example.com @plugin=combo_handler.so
> maphttp://localhost/example.com   http://os.example.com
> maphttp://other.com  http://os.other.com  # combo for this channel is 
> disabled
> {code}
> # limit sub-file max count and querystring length for potential problems 
> http://pastebin.com/cmBCuCNB
> # log failed url http://pastebin.com/bNezeaz0
> They were tested on 3.0.x.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (TS-1827) minor improvement of combo_handler plugin

2013-05-07 Thread Conan Wang (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-1827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13651205#comment-13651205
 ] 

Conan Wang commented on TS-1827:


feature 1-5's patch is sent via github pull request : 
https://github.com/apache/trafficserver/pull/9

feature 6 is abandoned because failed urls have already been logged into 
error.log.

> minor improvement of combo_handler plugin
> -
>
> Key: TS-1827
> URL: https://issues.apache.org/jira/browse/TS-1827
> Project: Traffic Server
>  Issue Type: Improvement
>  Components: Plugins
>Reporter: Conan Wang
>Assignee: Leif Hedstrom
> Fix For: 3.3.3
>
>
> Based on TS-1053, I've made some minor improvements. Community can select the 
> general ones to review.
> Changes: (separately pasted on pastebin temporally; may provide with commits 
> later after TS-1053 is solved on git master):
> # use HOST header as default bucket http://pastebin.com/pGHfLaHR
> Original code use the first segment of Host as the default bucket and it's 
> not that expandable (two different combo domain may have same leading 
> segment). Moreover, the initial default bucket("l") will not be used, because 
> all requests should have a HOST. 
> # sub-file's path need to contain querystring, i.e. question mark("?") is 
> part of the file path, not the delimiter http://pastebin.com/HvMJBQw0
> We use querystring to version each single sub-file in the combined url. If we 
> want to update/purge one of them, it can be simply accomplished by changing 
> the version of sub-file. (If not, you have to purge both the combined url and 
> sub-file url which is relatively hard to know the latter one when you are not 
> very familiar with ATS. Of course you can alter the filename if possible in 
> your site.)
> Then the combo url could be like 
> http://example.com/combo?file1?v=2012&file2?v=2013
> # request hangs when combo url has no querystring http://pastebin.com/d34ZJDzQ
> # make plugin per-remap enabled/disabled http://pastebin.com/YTaDYvh2
> It's implemented by adding some remap code and make global part "intercepted" 
> in TS_EVENT_HTTP_OS_DNS instead of TS_EVENT_HTTP_READ_REQUEST_HDR in order to 
> read the flag set in TSRemapDoRemap.
> So remap.config will be: {code}
> maphttp://example.com   http://os.example.com @plugin=combo_handler.so
> maphttp://localhost/example.com   http://os.example.com
> maphttp://other.com  http://os.other.com  # combo for this channel is 
> disabled
> {code}
> # limit sub-file max count and querystring length for potential problems 
> http://pastebin.com/cmBCuCNB
> # log failed url http://pastebin.com/bNezeaz0
> They were tested on 3.0.x.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (TS-1827) minor improvement of combo_handler plugin

2013-05-29 Thread Leif Hedstrom (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-1827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13669452#comment-13669452
 ] 

Leif Hedstrom commented on TS-1827:
---

Two comments on the patch:

1) There's no need to allocate the "int" for plugin_enabled, just set the void* 
(with appropriate casting) to 1.

2) With this patch, there is no longer possible to enable the combo_handler as 
a "global", right? Is that as intended? Meaning, the only way this will work is 
by also invoking the plugin in a remap rule, right?

I'm attaching an updated patch for issue #1 above, please review that.


> minor improvement of combo_handler plugin
> -
>
> Key: TS-1827
> URL: https://issues.apache.org/jira/browse/TS-1827
> Project: Traffic Server
>  Issue Type: Improvement
>  Components: Plugins
>Reporter: Conan Wang
>Assignee: Leif Hedstrom
> Fix For: 3.3.3
>
> Attachments: TS-1827.diff
>
>
> Based on TS-1053, I've made some minor improvements. Community can select the 
> general ones to review.
> Changes: (separately pasted on pastebin temporally; may provide with commits 
> later after TS-1053 is solved on git master):
> # use HOST header as default bucket http://pastebin.com/pGHfLaHR
> Original code use the first segment of Host as the default bucket and it's 
> not that expandable (two different combo domain may have same leading 
> segment). Moreover, the initial default bucket("l") will not be used, because 
> all requests should have a HOST. 
> # sub-file's path need to contain querystring, i.e. question mark("?") is 
> part of the file path, not the delimiter http://pastebin.com/HvMJBQw0
> We use querystring to version each single sub-file in the combined url. If we 
> want to update/purge one of them, it can be simply accomplished by changing 
> the version of sub-file. (If not, you have to purge both the combined url and 
> sub-file url which is relatively hard to know the latter one when you are not 
> very familiar with ATS. Of course you can alter the filename if possible in 
> your site.)
> Then the combo url could be like 
> http://example.com/combo?file1?v=2012&file2?v=2013
> # request hangs when combo url has no querystring http://pastebin.com/d34ZJDzQ
> # make plugin per-remap enabled/disabled http://pastebin.com/YTaDYvh2
> It's implemented by adding some remap code and make global part "intercepted" 
> in TS_EVENT_HTTP_OS_DNS instead of TS_EVENT_HTTP_READ_REQUEST_HDR in order to 
> read the flag set in TSRemapDoRemap.
> So remap.config will be: {code}
> maphttp://example.com   http://os.example.com @plugin=combo_handler.so
> maphttp://localhost/example.com   http://os.example.com
> maphttp://other.com  http://os.other.com  # combo for this channel is 
> disabled
> {code}
> # limit sub-file max count and querystring length for potential problems 
> http://pastebin.com/cmBCuCNB
> # log failed url http://pastebin.com/bNezeaz0
> They were tested on 3.0.x.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (TS-1827) minor improvement of combo_handler plugin

2013-05-29 Thread Conan Wang (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-1827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13669607#comment-13669607
 ] 

Conan Wang commented on TS-1827:


I'll test the issue 1 later.

For issue 2, right, it's as intended, at least for CDN (usually only a few 
customers among all will enable combo feature). And it looks safer for ATS 
users to adopt this plugin. 

Should we support the old manner(if not existing combo remap rule, make it 
enabled globally for all channels which is a little confusing)?

> minor improvement of combo_handler plugin
> -
>
> Key: TS-1827
> URL: https://issues.apache.org/jira/browse/TS-1827
> Project: Traffic Server
>  Issue Type: Improvement
>  Components: Plugins
>Reporter: Conan Wang
>Assignee: Leif Hedstrom
> Fix For: 3.3.3
>
> Attachments: TS-1827.diff
>
>
> Based on TS-1053, I've made some minor improvements. Community can select the 
> general ones to review.
> Changes: (separately pasted on pastebin temporally; may provide with commits 
> later after TS-1053 is solved on git master):
> # use HOST header as default bucket http://pastebin.com/pGHfLaHR
> Original code use the first segment of Host as the default bucket and it's 
> not that expandable (two different combo domain may have same leading 
> segment). Moreover, the initial default bucket("l") will not be used, because 
> all requests should have a HOST. 
> # sub-file's path need to contain querystring, i.e. question mark("?") is 
> part of the file path, not the delimiter http://pastebin.com/HvMJBQw0
> We use querystring to version each single sub-file in the combined url. If we 
> want to update/purge one of them, it can be simply accomplished by changing 
> the version of sub-file. (If not, you have to purge both the combined url and 
> sub-file url which is relatively hard to know the latter one when you are not 
> very familiar with ATS. Of course you can alter the filename if possible in 
> your site.)
> Then the combo url could be like 
> http://example.com/combo?file1?v=2012&file2?v=2013
> # request hangs when combo url has no querystring http://pastebin.com/d34ZJDzQ
> # make plugin per-remap enabled/disabled http://pastebin.com/YTaDYvh2
> It's implemented by adding some remap code and make global part "intercepted" 
> in TS_EVENT_HTTP_OS_DNS instead of TS_EVENT_HTTP_READ_REQUEST_HDR in order to 
> read the flag set in TSRemapDoRemap.
> So remap.config will be: {code}
> maphttp://example.com   http://os.example.com @plugin=combo_handler.so
> maphttp://localhost/example.com   http://os.example.com
> maphttp://other.com  http://os.other.com  # combo for this channel is 
> disabled
> {code}
> # limit sub-file max count and querystring length for potential problems 
> http://pastebin.com/cmBCuCNB
> # log failed url http://pastebin.com/bNezeaz0
> They were tested on 3.0.x.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (TS-1827) minor improvement of combo_handler plugin

2013-06-03 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-1827?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13673305#comment-13673305
 ] 

ASF subversion and git services commented on TS-1827:
-

Commit 3d33a7ee689fb260930756c2466d780285588455 in branch refs/heads/master 
from Leif Hedstrom 
[ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=3d33a7e ]

TS-1827 Further cleanup of combo_handler. Particularly, it is now
controlled via remap.config.

Review: Leif, I also changed the txn parameter passing to avoid
the malloc.


> minor improvement of combo_handler plugin
> -
>
> Key: TS-1827
> URL: https://issues.apache.org/jira/browse/TS-1827
> Project: Traffic Server
>  Issue Type: Improvement
>  Components: Plugins
>Reporter: Conan Wang
>Assignee: Leif Hedstrom
> Fix For: 3.3.3
>
> Attachments: TS-1827.diff
>
>
> Based on TS-1053, I've made some minor improvements. Community can select the 
> general ones to review.
> Changes: (separately pasted on pastebin temporally; may provide with commits 
> later after TS-1053 is solved on git master):
> # use HOST header as default bucket http://pastebin.com/pGHfLaHR
> Original code use the first segment of Host as the default bucket and it's 
> not that expandable (two different combo domain may have same leading 
> segment). Moreover, the initial default bucket("l") will not be used, because 
> all requests should have a HOST. 
> # sub-file's path need to contain querystring, i.e. question mark("?") is 
> part of the file path, not the delimiter http://pastebin.com/HvMJBQw0
> We use querystring to version each single sub-file in the combined url. If we 
> want to update/purge one of them, it can be simply accomplished by changing 
> the version of sub-file. (If not, you have to purge both the combined url and 
> sub-file url which is relatively hard to know the latter one when you are not 
> very familiar with ATS. Of course you can alter the filename if possible in 
> your site.)
> Then the combo url could be like 
> http://example.com/combo?file1?v=2012&file2?v=2013
> # request hangs when combo url has no querystring http://pastebin.com/d34ZJDzQ
> # make plugin per-remap enabled/disabled http://pastebin.com/YTaDYvh2
> It's implemented by adding some remap code and make global part "intercepted" 
> in TS_EVENT_HTTP_OS_DNS instead of TS_EVENT_HTTP_READ_REQUEST_HDR in order to 
> read the flag set in TSRemapDoRemap.
> So remap.config will be: {code}
> maphttp://example.com   http://os.example.com @plugin=combo_handler.so
> maphttp://localhost/example.com   http://os.example.com
> maphttp://other.com  http://os.other.com  # combo for this channel is 
> disabled
> {code}
> # limit sub-file max count and querystring length for potential problems 
> http://pastebin.com/cmBCuCNB
> # log failed url http://pastebin.com/bNezeaz0
> They were tested on 3.0.x.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira