> On March 17, 2014, 6:43 p.m., rmudgett wrote:
> > /branches/12/main/sorcery.c, lines 750-752
> > <https://reviewboard.asterisk.org/r/3326/diff/4/?file=56105#file56105line750>
> >
> >     Should not fail if the sorcery.conf file doesn't exist.  The Bucket 
> > core module will fail asterisk start if so.  Other modules will fail to 
> > load as well.
> >     
> >     if !config return success
> >     if config==file-invalid return fail

I felt a bit wrong calling no configuration file a "success" so I added another 
value to the enum: AST_SORCERY_APPLY_NO_CONFIGURATION.


- Mark


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/3326/#review11258
-----------------------------------------------------------


On March 15, 2014, 5:29 p.m., Mark Michelson wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/3326/
> -----------------------------------------------------------
> 
> (Updated March 15, 2014, 5:29 p.m.)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Repository: Asterisk
> 
> 
> Description
> -------
> 
> When performing some realtime tests, I noticed that the AMI command 
> PJSIPShowEndpoints was listing all of my endpoints twice. This is because 
> ast_sorcery_apply_config() was being called twice from res_pjsip code, once 
> when initializing system configuration, and once again when initializing the 
> rest of the configuration data. This patch aims to fix the problem on two 
> fronts:
> 
> 1) Remove the ast_sorcery_apply_config() calls from the PJSIP code entirely 
> in favor of having sorcery automatically apply configuration for the module 
> when sorcery is opened. This reduces the chance of accidentally attempting to 
> apply the same configuration twice. I also removed the call to 
> ast_sorcery_apply_config from res_mwi_external since it is no longer 
> necessary either.
> 
> 2) Adjust sorcery_apply_wizard_mapping() not to apply the same wizard to an 
> object type more than once, just in case someone does make the error of 
> calling ast_sorcery_apply_config() multiple times for the same object type.
> 
> 
> Diffs
> -----
> 
>   /branches/12/tests/test_sorcery_realtime.c 410625 
>   /branches/12/tests/test_sorcery_astdb.c 410606 
>   /branches/12/tests/test_sorcery.c 410606 
>   /branches/12/res/res_pjsip/pjsip_configuration.c 410606 
>   /branches/12/res/res_pjsip/config_system.c 410606 
>   /branches/12/res/res_mwi_external.c 410606 
>   /branches/12/main/sorcery.c 410606 
>   /branches/12/include/asterisk/sorcery.h 410606 
>   /branches/12/configs/sorcery.conf.sample 410606 
> 
> Diff: https://reviewboard.asterisk.org/r/3326/diff/
> 
> 
> Testing
> -------
> 
> My tests of retrieving data from realtime now get the expected objects. I 
> don't have any automated tests to post yet because the realtime testsuite is 
> a work in progress.
> 
> 
> Thanks,
> 
> Mark Michelson
> 
>

-- 
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-dev mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-dev

Reply via email to