On Wed, 10 Feb 2010 23:03:33 +0530, Dhaval Varia <dhavalkvaria_at_gmail.com>
wrote:
> Dear Sir,
>
> I am very enthu to work on this problem.but i am new in this.
>
> can you please help me initially.so i can understand flow of SQUID.
>
> and also understand code which is related to this problem.
>
> Please Answer me few question.
>
> 1. Where do i found source (ln which file??),which is responsible for
> creating log when instance of SQUID created??
>
> Thanx and Regards.
> Dhaval Varia
Wonderful. Okay... the details:
To start with you need to the right tools to work with squid code:
http://wiki.squid-cache.org/DeveloperResources#Contributing_.28Code_developer.29
For Squid-3 the best way is with Bazaar (bzr), that lets you stay up and
test easily with the latest changes and generates patches/merge files
easily as well.
The branch to work with is 3.HEAD (source repository URI
http://bzr.squid-cache.org/bzr/squid3/trunk )
The daemon code goes under helpers/log_daemon/.
* you will be adding a "tcp" sub-folder there, with all related files for
building.
* the existing "file" daemon can be used as an example for things like
the build files, code syntax, daemon log line on-wire format, etc.
* helpers may link to the compat layer and use the "config.h" include.
But should otherwise be self-contained code.
* built with ./configure --enable-log-daemon-auth-helpers=tcp
The logging code internal to Squid is under src/log/.
* you would be adding ModTcp.h and ModTcp.cc to that directory.
The Squid internal logging API is defined by src/log/File.h.
* the particular sub-calls used by that API can be seen in the various
Mod*.h files.
The flow within Squid goes:
* parser fills Logs::TheConfig (nothing new needed there)
* on startup/reconfigure parser then calls logfileOpen() (in log/File.cc)
to initialize the relevant modules.
You will need to add a "tcp:" handling case there.
That will call your module *_open() function to setup the TCP links and
logging starts immediately when it returns.
* during operation it calls the *_write(), *_writeline() to add data to
the log
* *_flush(), and *_rotate() functions also called at various times.
* *_linestart() and *_lineend() are used by Squid to delimit the
beginning and end of lines. May not be applicable. If not they can be left
empty like the UDP ones.
* on shutdown the *_close() function gets called and logging stops
immediately.
If you get stuck on anything, a mail to the squid-dev list should get a
reply from someone.
When you have anything ready to go in the merging procedure is documented
at http://wiki.squid-cache.org/MergeProcedure
Amos
>
> On 2/10/10, Amos Jeffries <squid3_at_treenet.co.nz> wrote:
>> Dhaval Varia wrote:
>>> Dear Sir,
>>>
>>> I am Doing my *research In SQUID proxy* as a part of my post
graduation*
>>> (Master of Engineering)
>>> *Just started.but dont have a specific direction so i can move ahed.
>>>
>>> *I need your help in following confusions :-
>>> *
>>> 1. What topic / Module (In Squid) i choose to start my research work
?
>>> 2. Where do I understand the module.
>>> 3. what initially i have to do? to start my work?
>>>
>>> *Please sir,I will be greatful for your help.*
>>>
>>> Thanks & Best Regards.
>>>
----------------------------------------------------------------------------------------
>>> Dhaval varia
>>> (9924343883)
>>>
>>
>> Greetings,
>> It's nice to see more people interested in Squid. (cc'ing to
squid-dev
>> mailing list, where developer discussions take place)
>>
>> Did you have any ideas about what sort of thing you would be most
>> interested in?
>>
>>
>> The current developer focus for this year is (mostly) on preparing
Squid
>> 3.2 for better traffic scaling via SMP CPU support. Our planned
>> architecture so far is described here:
>> http://wiki.squid-cache.org/Features/SmpScale
>>
>> With Squid becoming multi-instance the most urgent project I'm looking
>> for someone to create a daemon for reliable logging of data from N
squid
>> instances simultaneously to one log file.
>>
>> This daemon needs to open its own configurable socket for accepting
>> connection requests from various Squid instances.
>> On receiving a request it needs to receive the unique hostname from
>> the Squid connecting and store it for optional configured pre-pending
to
>> every log line received via that TCP link.
>> It needs to cope cleanly with sockets opening and closing at any
time.
>> Logging of many thousands of requests per second, ideally a minimum
>> 10,000/sec per connected Squid instance. Maybe ignore the in-channel
log
>> rotate commands but rotate whenever the logs reaches a configurable
size.
>>
>> A module internal to Squid will also need to be created to use the new
>> helper. Derived from the src/log/ModUdp.* daemon but using TCP logging
>> and setup as well. Possibly to a daemon running on a remote machine.
>>
>> Deadline would be mid-year 2010 for something testable. End of year for
>> something hopefuly able to be committed for use.
>>
>> Interested?
>>
>> Amos
>> --
>> Please be using
>> Current Stable Squid 2.7.STABLE7 or 3.0.STABLE23
>> Current Beta Squid 3.1.0.16
>>
Received on Wed Feb 10 2010 - 23:45:14 MST
This archive was generated by hypermail 2.2.0 : Thu Feb 11 2010 - 12:00:06 MST