celix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Broekhuis <a.broekh...@gmail.com>
Subject Re: celix log levels
Date Thu, 12 Dec 2013 19:50:54 GMT
Hi,

I do agree this is a good proposal, but before making a patch.. I think it
is needed to check other enums/constants. But even more important, how to
prefix them.

Even though this might seem trivial, the log levels come directly from the
OSGi specification. So there is a change that they will be changed again if
Native OSGi progresses a bit more. Considering this, it might be worthwhile
to think of a generic solution for such cases (within OSGi this is solved
with the namespace of java packages..).

So I am not in favour of simply using CELIX_ as prefix. Likewise OSGI_
probably isn't a good idea. So far I can only come up with LOG_SERVICE_,
reasoning for this is that the enum is part of the LogService specification.

Any other ideas?



2013/12/12 Gerrit Binnenmars <gerritbinnenmars@gmail.com>

> Hello Bjorn,
>
> It is a good proposal, so just do it and make a patch for Celix.
> I can imagine that there are a lot more "prefixes"missing?
>
> Greetings Gerrit
>
>
>>
>> Hi all,
>>
>> While coupling a log_writer to syslog, I recognized that celix has some
>> log levels (as enum in log_service.h) which are already defined within
>> syslog. As I want to prevent strange #undefine's in my code and changing
>> syslog is obviously not a solution, I would propose to add a "CELIX_"
>> prefix to the log levels.
>>
>> As this implies a change to several source-files, I would like to ask
>> whether there are any objections or other proposals?
>>
>> Regards,
>>   Bjoern
>>
>
>


-- 
Met vriendelijke groet,

Alexander Broekhuis

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message