[OpenSIPS-Devel] [ opensips-Bugs-3604060 ] b2b_logic: $du and $ru

2013-02-18 Thread SourceForge . net
Bugs item #3604060, was opened at 2013-02-10 21:57
Message generated for change (Comment added) made by bogdan_iancu
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detailatid=1086410aid=3604060group_id=232389

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: trunk
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nick Altmann (nikbyte)
Assigned to: Bogdan-Andrei Iancu (bogdan_iancu)
Summary: b2b_logic: $du and $ru

Initial Comment:
b2b_logic should respect $du and $ru in scripting mode like it respects $du and 
$ru in topology hiding mode.


--

Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2013-02-18 02:00

Message:
Hi Nick,

Well, it is NOT the same as topo hiding - in topo hiding scenario, the call
is sent out to the destination received in RURI - and in this case, it
should follow the RURI + DURI.

When using a B2BUA scenario script, it is not a simple pass through, but
what is the destination is controlled via script  - and in the XML script,
you say where the call is to be sent. In this case, what was the received
RURI is completely irrelevant, IMHO.

Regards,
Bogdan

--

Comment By: Nick Altmann (nikbyte)
Date: 2013-02-18 01:43

Message:
My opinion is script should get $ru and $du for init, like topo hiding.
You may just change topo hiding to script and everything should works.
But it's no problem because script can use params. So, if you don't agree,
this case may be closed. Thanks.


--

Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2013-02-16 01:37

Message:
Nick, I agree that topo hiding has to read the $ru to know where to send
the call (as topp hiding has no scenario).

But if this case, you have a scenario and the destination is controlled by
the xml scenario (client nodes have the destination node to tell the new
RURI on the outbound part) and not by the received RURI.

Regards,
Bogdan

--

Comment By: Nick Altmann (nikbyte)
Date: 2013-02-15 04:44

Message:
$ru may be changed before b2b_init_request. topology hiding takes it like
this way.
For example, I use drouting before b2b_init_request. Without this patch
topology hiding works, but scenarios don't.
$du is only for init.


--

Comment By: Bogdan-Andrei Iancu (bogdan_iancu)
Date: 2013-02-15 04:41

Message:
Hi Nick,

First I do not agree in preserving the $ru - this must be taken from the
scenario, IMO.

Now, about the $du, according to you patch, this should be followed only
for the init clients; it should not be used for further client nodes,
right ?

Regards,
Bogdan

--

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detailatid=1086410aid=3604060group_id=232389

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [RFC] migration to GIT

2013-02-18 Thread Bogdan-Andrei Iancu

Hi all,

I would like to get some suggestions and help on the matter of migrating 
the code repository from SVN to GIT - the fact that such migration will 
bring value is for sure :)


What things need to be sorted out when moving to GIT:


1) for backward compatibility, I would suggest having a Read-Only SVN, 
so people will be able to update their current SVN checkouts.

Does any of you have experience in mirroring (GIT to SVN only) data ?


2) about the hooks in GIT - we have now the scripts for sending email on 
each SVN commits - some help in this matter will be highly appreciated.



3) we are heavily using the SVN keywords (%id%, etc) - is there a way to 
keep something similar in GIT ?



I will appreciate any help from any GIT expert around here, just to be 
sure we get the things in the right way from the beginning :).



Best regards,

--
Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com


___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Peter Lemenkov
2013/2/18 Bogdan-Andrei Iancu bog...@opensips.org:
 Hi all,

 I would like to get some suggestions and help on the matter of migrating the
 code repository from SVN to GIT - the fact that such migration will bring
 value is for sure :)

YES! YES! YES!


-- 
With best regards, Peter Lemenkov.

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Saúl Ibarra Corretgé
Hi Bogdan,

On Feb 18, 2013, at 5:05 PM, Bogdan-Andrei Iancu wrote:

 Hi all,
 
 I would like to get some suggestions and help on the matter of migrating the 
 code repository from SVN to GIT - the fact that such migration will bring 
 value is for sure :)
 

I'm glad to see this happening. Count me in for helping as much as I can.

 What things need to be sorted out when moving to GIT:
 

First question: would it be a self-hosted Git repository or the GitHub service?

 
 1) for backward compatibility, I would suggest having a Read-Only SVN, so 
 people will be able to update their current SVN checkouts.
 Does any of you have experience in mirroring (GIT to SVN only) data ?
 

If GitHub is chosen it already provides this, so there is nothing to be done: 
https://github.com/blog/1178-collaborating-on-github-with-subversion

 
 2) about the hooks in GIT - we have now the scripts for sending email on each 
 SVN commits - some help in this matter will be highly appreciated.
 

I don't know myself, but shouldn't be too hard to do.

 
 3) we are heavily using the SVN keywords (%id%, etc) - is there a way to keep 
 something similar in GIT ?
 

Ditto. Also, we should keep the svn authors mapped to git authors where 
possible.

 
 I will appreciate any help from any GIT expert around here, just to be sure 
 we get the things in the right way from the beginning :).
 

Not a git super expert, but I have maintained a unofficial OpenSIPS repo for a 
while: https://github.com/saghul/OpenSIPS

Since I'm here, let me elaborate on why I think moving to GitHub is a good idea:

- Pull requests.

That's it. Pull requests are the perfect way to collaborate with the project. 
Only people who actively contribute need commit rights, the rest can send a 
pull request with their changes just fine. Inline commenting is awesome, it's a 
very good way to iterate on a bugfix without sending diffs left and right, 
making code reviews very simple.

GitHub also has an issue tracker, so existing issues can be migrated there. 
This would also help remove all sorts of old issues that have piled up over 
time ;-)


Regards,

--
Saúl Ibarra Corretgé
AG Projects




___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Peter Lemenkov
2013/2/18 Saúl Ibarra Corretgé s...@ag-projects.com:

 What things need to be sorted out when moving to GIT:


 First question: would it be a self-hosted Git repository or the GitHub 
 service?

Why can't we have both?

I personally don't see any issues here - It's possible to setup a
primary repo at SF and secondary at GitHub. To be honest I'd
prefer GitHub.

Also I'd like to propose a switch to a new issue tracker at SF.net.
Just compare that one we have to use now with the newest one:

* http://sourceforge.net/p/sipp/bugs/
* http://sourceforge.net/p/curl/bugs/

-- 
With best regards, Peter Lemenkov.

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Saúl Ibarra Corretgé

On Feb 18, 2013, at 6:14 PM, Peter Lemenkov wrote:

 2013/2/18 Saúl Ibarra Corretgé s...@ag-projects.com:
 Also I'd like to propose a switch to a new issue tracker at SF.net.
 Just compare that one we have to use now with the newest one:
 
 * http://sourceforge.net/p/sipp/bugs/
 * http://sourceforge.net/p/curl/bugs/
 
 
 Does the new tracker have anything like the pull requests mechanism?
 
 No, it doesn't. But it's still much better than the current one.
 

Right. Personally, the main reason for going with GitHub and having the issue 
tracker there is how simple it is for people to contribute thanks to the 
powerful pull-requests feature. Not to mention that it encourages code reviews, 
which should in turn increase code quality.

--
Saúl Ibarra Corretgé
AG Projects




___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Bogdan-Andrei Iancu

Hi Saul,

Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com


On 02/18/2013 06:20 PM, Saúl Ibarra Corretgé wrote:


What things need to be sorted out when moving to GIT:


First question: would it be a self-hosted Git repository or the GitHub service?


1) for backward compatibility, I would suggest having a Read-Only SVN, so 
people will be able to update their current SVN checkouts.
Does any of you have experience in mirroring (GIT to SVN only) data ?


If GitHub is chosen it already provides this, so there is nothing to be done: 
https://github.com/blog/1178-collaborating-on-github-with-subversion


2) about the hooks in GIT - we have now the scripts for sending email on each 
SVN commits - some help in this matter will be highly appreciated.


I don't know myself, but shouldn't be too hard to do.


3) we are heavily using the SVN keywords (%id%, etc) - is there a way to keep 
something similar in GIT ?


Ditto. Also, we should keep the svn authors mapped to git authors where 
possible.


I will appreciate any help from any GIT expert around here, just to be sure 
we get the things in the right way from the beginning :).


Not a git super expert, but I have maintained a unofficial OpenSIPS repo for a 
while: https://github.com/saghul/OpenSIPS

Since I'm here, let me elaborate on why I think moving to GitHub is a good idea:

- Pull requests.

That's it. Pull requests are the perfect way to collaborate with the project. 
Only people who actively contribute need commit rights, the rest can send a 
pull request with their changes just fine. Inline commenting is awesome, it's a 
very good way to iterate on a bugfix without sending diffs left and right, 
making code reviews very simple.

GitHub also has an issue tracker, so existing issues can be migrated there. 
This would also help remove all sorts of old issues that have piled up over 
time ;-)


When comes to SF versus GITHUB - the main problem from my perspective is 
that SF overs a unified (one account) for tracker, forums, downloads, 
code repo.If we move code repo to GITHUB, we will force the 
developer to use 2 accounts (on SF for tracker, forum , etc, and one on 
GITHUB for GIT only)..


For manageability reasons I would prefer to have a place hosting everything.

What options I see:

1) move everything (tracker + GIT and the rest ?) on GITHUB

2) keep SF as primary GIT repo and GITHUB can be a secondary. Developers 
can use the SF accounts for everything and use GITHUB as an interface to 
the community (changes, pull requests, etc)..


If I'm talking BS, please correct me :D.

Regards,
Bogdan

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [OpenSIPS-Users] [RFC] migration to GIT

2013-02-18 Thread Bogdan-Andrei Iancu

Hi Peter,

On 02/18/2013 06:52 PM, Peter Lemenkov wrote:

2013/2/18 Saúl Ibarra Corretgés...@ag-projects.com:


What things need to be sorted out when moving to GIT:


First question: would it be a self-hosted Git repository or the GitHub service?

Why can't we have both?

I personally don't see any issues here - It's possible to setup a
primary repo at SF and secondary at GitHub. To be honest I'd
prefer GitHub.

Also I'd like to propose a switch to a new issue tracker at SF.net.
Just compare that one we have to use now with the newest one:

* http://sourceforge.net/p/sipp/bugs/
* http://sourceforge.net/p/curl/bugs/


SF anyhow forces us to do an upgrade (for the platform they are using) - 
see https://sourceforge.net/p/upgrade?search=opensips -, so we could 
check how the new tracker looks like and what other new options they 
have for it.


Regards,
Bogdan

___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [ opensips-Bugs-3603732 ] rl_dec_count increases counter

2013-02-18 Thread SourceForge . net
Bugs item #3603732, was opened at 2013-02-07 10:15
Message generated for change (Comment added) made by hmmhesays
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detailatid=1086410aid=3603732group_id=232389

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Matt Williams (hmmhesays)
Assigned to: Razvan Crainea (razvancrainea)
Summary: rl_dec_count increases counter

Initial Comment:
Calling rl_dec_count_increases the counter. Test calls rl_check 3 times to 
increment the counter. 

 #We're only checking our gateway rate limits here;
if(!rl_check($avp(778)_$avp(271), $(avp(780){s.int}), TAILDROP)) {
rl_check($avp(778)_$avp(271), $(avp(780){s.int}), 
TAILDROP);
rl_check($avp(778)_$avp(271), $(avp(780){s.int}), 
TAILDROP);
rl_dec_count($avp(778)_$avp(271));
rl_dec_count($avp(778)_$avp(271));
rl_dec_count($avp(778)_$avp(271));
#make sure counter doesn't go negative;
rl_dec_count($avp(778)_$avp(271));
route(route_failover);
exit;
}


Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test doens't exist, 
but was created 0x2b4307eb2428
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test counter:1 load:0 
limit:0 should be blocked (0x2b4307eb2428)
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test found: 
0x2b4307eb2428 - last used 1360260142
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test counter:2 load:0 
limit:0 should be blocked (0x2b4307eb2428)
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test found: 
0x2b4307eb2428 - last used 1360260142
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_check_3: Pipe test counter:3 load:0 
limit:0 should be blocked (0x2b4307eb2428)
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_set_count: new counter for key test 
is 4
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_set_count: new counter for key test 
is 5
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_set_count: new counter for key test 
is 6
Feb  7 13:02:22 [15173] DBG:ratelimit:w_rl_set_count: new counter for key test 
is 7


attached patch fixes my issues. Needs review to see if it breaks anything else. 

--

Comment By: Matt Williams (hmmhesays)
Date: 2013-02-18 13:53

Message:
Looks like this patch works well. Thank you!

--

Comment By: Matt Williams (hmmhesays)
Date: 2013-02-15 12:27

Message:
My apologies I haven't had a chance to test. I will do so later today. 

--

Comment By: Razvan Crainea (razvancrainea)
Date: 2013-02-15 09:05

Message:
Hi, Matt!

Any updates? Please let me know if everything is ok before I commit the
fix.

Best regards,
Răzvan

--

Comment By: Razvan Crainea (razvancrainea)
Date: 2013-02-09 23:18

Message:
Hi, Matt!

I have attached a new patch. Can you please give me a try and let me know
how it works?

Best regards,
Răzvan

--

Comment By: Matt Williams (hmmhesays)
Date: 2013-02-08 09:46

Message:
Looks like this allows it to go negative for one count. 

Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test doens't
exist, but was created 0x2b0d5fa7eee8
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test counter:1
load:0 limit:0 should be blocked (0x2b0d5fa7eee8)
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test found:
0x2b0d5fa7eee8 - last used 1360345517
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test counter:2
load:0 limit:0 should be blocked (0x2b0d5fa7eee8)
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test found:
0x2b0d5fa7eee8 - last used 1360345517
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_check_3: Pipe test counter:3
load:0 limit:0 should be blocked (0x2b0d5fa7eee8)
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_set_count: new counter for key
test is 2
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_set_count: new counter for key
test is 1
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_set_count: new counter for key
test is 0
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_set_count: new counter for key
test is -1
Feb  8 12:45:17 [12405] DBG:ratelimit:w_rl_set_count: new counter for key
test is 0

--

Comment By: Matt Williams (hmmhesays)
Date: 2013-02-08 09:40

Message:
Thank You, I will test it out. 

--

Comment By: Razvan Crainea (razvancrainea)
Date: