You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jspwiki.apache.org by Brian Burch <br...@pingtoo.com> on 2014/01/17 13:01:04 UTC
PhotoCollectionPlugin now available with JSPWiki
My PhotoCollectionPlugin has been available for JSPWiki 2.8
(com.eycrd.jspwiki packages) for several years. I have just converted it
to run under the apache releases. I have tested it against 2.10, running
under ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
I have just added:
https://jspwiki-wiki.apache.org/Wiki.jsp?page=PhotoCollectionPlugin
.. and linked it from:
https://jspwiki-wiki.apache.org/Wiki.jsp?page=ContributedPlugins
.. where I say:
"I wonder how anyone can manage without this plugin! If you have a
collection of photos in a single directory tree of arbitrary depth, this
plugin will automatically associate "why not create this page" links
with every directory and photo (without consuming any space).
All you have to do is click on one of these virtual links, then simply
save the automatically generated page, and that part of your photo
collection gets its own wiki page. By adding wiki text to the page,
everything becomes indexed and searchable. No more worrying about which
year and month you went somewhere or met someone!"
Come on everyone... give it a try!
Regards,
Brian
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Brian Burch <br...@PingToo.com>.
On 21/01/14 09:09, Brian Burch wrote:
> On 20/01/14 17:17, Harry Metske wrote:
>> Brian,
>>
>> on your last question, it is a good point to keep this "data" (photo's)
>> separate from the "code" (the war).
>> Using a (rather abstract definition of) a resource might be little
>> overkill, I would be satisfied with the current option, but maybe other
>> users would like to see more/other things.
>
> Thanks for clarifying, Harry.
>
> When I originally developed the plugin, I struggled to achieve webapp
> access outside the container - a good thing. The only approach that
> worked for me was to use a symlink inside the container. That was years
> ago and subsequently a couple of people have said they didn't think it
> was necessary.
>
> I will remind myself of the logic and work on that change later this week.
>
> Regards,
>
> Brian
>
>> regards,
>> Harry
>>
>>
>>
>> On 18 January 2014 17:10, Brian Burch <br...@pingtoo.com> wrote:
>>
>>> On 18/01/14 13:09, Harry Metske wrote:
>>>
>>>> Brian,
>>>>
>>>> I played around a bit with the PhotoCollectionPlugin, a nice
>>>> combination
>>>> of
>>>> wiki and photo collections.
>>>>
>>>
>>> Thanks for trying it.
>>>
>>>
>>> I found just two minor issues :
>>>>
>>>> * The values for photoCollection.default.phototype appear to be case
>>>> sensitive (I had to add lowercase .png .jpg to get it working). I think
>>>> they should be case insensitive.
>>>>
>>>
>>> I agree with you.
I did some checking and wrote some new unit test cases. I was surprised
to find the original code already had logic to match the photo file type
in a case-insensitive manner.
I have just uploaded a new new version of photocollection.jar to the
wiki (works with the new unit tests).
I have uploaded a new version of the sample jspwiki-custom.properties
which points out the case-insensitive match and also sets a default to
support *.jpg, *.jpeg, *.png. All 3 types work fine on my own wiki.
Finally, I updated the description page on the wiki to reflect these
changes.
Regards,
Brian
>>> When I originally wrote the plugin most cameras made JPG's, but my
>>> wife's
>>> Android phone makes jpg's. I add JPG to my /etc/mime.types to get most
>>> tools to handle the JPG file type, so I haven't picked up on your issue
>>> since I wrote the original code.
>>>
>>> I should probably add support for *.jpeg at the same time, because that
>>> exists in mime.types too.
>>>
>>>
>>> * The photoCollection.collection.base is always considered relative to
>>>> the
>>>> webapp, even if you start it's value with a "/". You are forced to
>>>> fiddle
>>>> in your installed war, even if you use symlinks (and start making
>>>> questionable changes to the tomcat configuration). In general we
>>>> like to
>>>> stay away from "war surgery", and therefore you should be able to use
>>>> absolute paths for this property.
>>>>
>>>
>>> You have a good point. My next enhancement was to investigate
>>> handling the
>>> entire PhotoCollection as resources rather than Files. Do you think
>>> that is
>>> a good potential approach for fetching the collection - I think it
>>> would/should always be located outside the webapp directory?
>>>
>>>
>>> Thanks for your efforts !
>>>>
>>>
>>> No problem. I'm pleased to help when I have time to spare, or when
>>> jspwiki
>>> reaches the top of my priority list. I'm usually an "if it aint
>>> broke, dont
>>> fix it" kind of guy...
>>>
>>> Brian
>>>
>>>
>>> kind regards,
>>>> Harry
>>>>
>>>>
>>>>
>>>> On 17 January 2014 14:03, Dave Koelmeyer <dave.koelmeyer@davekoelmeyer.
>>>> co.nz
>>>>
>>>>> wrote:
>>>>>
>>>>
>>>>
>>>>> On 18/01/14 01:01, Brian Burch wrote:
>>>>>
>>>>> My PhotoCollectionPlugin has been available for JSPWiki 2.8
>>>>>> (com.eycrd.jspwiki packages) for several years. I have just converted
>>>>>> it to
>>>>>> run under the apache releases. I have tested it against 2.10, running
>>>>>> under
>>>>>> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>>>>>>
>>>>>>
>>>>>
>>>>> Awesome!
>>>>>
>>>>> --
>>>>> Dave Koelmeyer
>>>>> http://blog.davekoelmeyer.co.nz
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Brian Burch <br...@pingtoo.com>.
On 20/01/14 17:17, Harry Metske wrote:
> Brian,
>
> on your last question, it is a good point to keep this "data" (photo's)
> separate from the "code" (the war).
> Using a (rather abstract definition of) a resource might be little
> overkill, I would be satisfied with the current option, but maybe other
> users would like to see more/other things.
Thanks for clarifying, Harry.
When I originally developed the plugin, I struggled to achieve webapp
access outside the container - a good thing. The only approach that
worked for me was to use a symlink inside the container. That was years
ago and subsequently a couple of people have said they didn't think it
was necessary.
I will remind myself of the logic and work on that change later this week.
Regards,
Brian
> regards,
> Harry
>
>
>
> On 18 January 2014 17:10, Brian Burch <br...@pingtoo.com> wrote:
>
>> On 18/01/14 13:09, Harry Metske wrote:
>>
>>> Brian,
>>>
>>> I played around a bit with the PhotoCollectionPlugin, a nice combination
>>> of
>>> wiki and photo collections.
>>>
>>
>> Thanks for trying it.
>>
>>
>> I found just two minor issues :
>>>
>>> * The values for photoCollection.default.phototype appear to be case
>>> sensitive (I had to add lowercase .png .jpg to get it working). I think
>>> they should be case insensitive.
>>>
>>
>> I agree with you.
>>
>> When I originally wrote the plugin most cameras made JPG's, but my wife's
>> Android phone makes jpg's. I add JPG to my /etc/mime.types to get most
>> tools to handle the JPG file type, so I haven't picked up on your issue
>> since I wrote the original code.
>>
>> I should probably add support for *.jpeg at the same time, because that
>> exists in mime.types too.
>>
>>
>> * The photoCollection.collection.base is always considered relative to
>>> the
>>> webapp, even if you start it's value with a "/". You are forced to fiddle
>>> in your installed war, even if you use symlinks (and start making
>>> questionable changes to the tomcat configuration). In general we like to
>>> stay away from "war surgery", and therefore you should be able to use
>>> absolute paths for this property.
>>>
>>
>> You have a good point. My next enhancement was to investigate handling the
>> entire PhotoCollection as resources rather than Files. Do you think that is
>> a good potential approach for fetching the collection - I think it
>> would/should always be located outside the webapp directory?
>>
>>
>> Thanks for your efforts !
>>>
>>
>> No problem. I'm pleased to help when I have time to spare, or when jspwiki
>> reaches the top of my priority list. I'm usually an "if it aint broke, dont
>> fix it" kind of guy...
>>
>> Brian
>>
>>
>> kind regards,
>>> Harry
>>>
>>>
>>>
>>> On 17 January 2014 14:03, Dave Koelmeyer <dave.koelmeyer@davekoelmeyer.
>>> co.nz
>>>
>>>> wrote:
>>>>
>>>
>>>
>>>> On 18/01/14 01:01, Brian Burch wrote:
>>>>
>>>> My PhotoCollectionPlugin has been available for JSPWiki 2.8
>>>>> (com.eycrd.jspwiki packages) for several years. I have just converted
>>>>> it to
>>>>> run under the apache releases. I have tested it against 2.10, running
>>>>> under
>>>>> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>>>>>
>>>>>
>>>>
>>>> Awesome!
>>>>
>>>> --
>>>> Dave Koelmeyer
>>>> http://blog.davekoelmeyer.co.nz
>>>>
>>>>
>>>>
>>>>
>>>
>>
>
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Harry Metske <ha...@gmail.com>.
Brian,
on your last question, it is a good point to keep this "data" (photo's)
separate from the "code" (the war).
Using a (rather abstract definition of) a resource might be little
overkill, I would be satisfied with the current option, but maybe other
users would like to see more/other things.
regards,
Harry
On 18 January 2014 17:10, Brian Burch <br...@pingtoo.com> wrote:
> On 18/01/14 13:09, Harry Metske wrote:
>
>> Brian,
>>
>> I played around a bit with the PhotoCollectionPlugin, a nice combination
>> of
>> wiki and photo collections.
>>
>
> Thanks for trying it.
>
>
> I found just two minor issues :
>>
>> * The values for photoCollection.default.phototype appear to be case
>> sensitive (I had to add lowercase .png .jpg to get it working). I think
>> they should be case insensitive.
>>
>
> I agree with you.
>
> When I originally wrote the plugin most cameras made JPG's, but my wife's
> Android phone makes jpg's. I add JPG to my /etc/mime.types to get most
> tools to handle the JPG file type, so I haven't picked up on your issue
> since I wrote the original code.
>
> I should probably add support for *.jpeg at the same time, because that
> exists in mime.types too.
>
>
> * The photoCollection.collection.base is always considered relative to
>> the
>> webapp, even if you start it's value with a "/". You are forced to fiddle
>> in your installed war, even if you use symlinks (and start making
>> questionable changes to the tomcat configuration). In general we like to
>> stay away from "war surgery", and therefore you should be able to use
>> absolute paths for this property.
>>
>
> You have a good point. My next enhancement was to investigate handling the
> entire PhotoCollection as resources rather than Files. Do you think that is
> a good potential approach for fetching the collection - I think it
> would/should always be located outside the webapp directory?
>
>
> Thanks for your efforts !
>>
>
> No problem. I'm pleased to help when I have time to spare, or when jspwiki
> reaches the top of my priority list. I'm usually an "if it aint broke, dont
> fix it" kind of guy...
>
> Brian
>
>
> kind regards,
>> Harry
>>
>>
>>
>> On 17 January 2014 14:03, Dave Koelmeyer <dave.koelmeyer@davekoelmeyer.
>> co.nz
>>
>>> wrote:
>>>
>>
>>
>>> On 18/01/14 01:01, Brian Burch wrote:
>>>
>>> My PhotoCollectionPlugin has been available for JSPWiki 2.8
>>>> (com.eycrd.jspwiki packages) for several years. I have just converted
>>>> it to
>>>> run under the apache releases. I have tested it against 2.10, running
>>>> under
>>>> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>>>>
>>>>
>>>
>>> Awesome!
>>>
>>> --
>>> Dave Koelmeyer
>>> http://blog.davekoelmeyer.co.nz
>>>
>>>
>>>
>>>
>>
>
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Brian Burch <br...@PingToo.com>.
On 18/01/14 13:09, Harry Metske wrote:
> Brian,
>
> I played around a bit with the PhotoCollectionPlugin, a nice combination of
> wiki and photo collections.
Thanks for trying it.
> I found just two minor issues :
>
> * The values for photoCollection.default.phototype appear to be case
> sensitive (I had to add lowercase .png .jpg to get it working). I think
> they should be case insensitive.
I agree with you.
When I originally wrote the plugin most cameras made JPG's, but my
wife's Android phone makes jpg's. I add JPG to my /etc/mime.types to get
most tools to handle the JPG file type, so I haven't picked up on your
issue since I wrote the original code.
I should probably add support for *.jpeg at the same time, because that
exists in mime.types too.
> * The photoCollection.collection.base is always considered relative to the
> webapp, even if you start it's value with a "/". You are forced to fiddle
> in your installed war, even if you use symlinks (and start making
> questionable changes to the tomcat configuration). In general we like to
> stay away from "war surgery", and therefore you should be able to use
> absolute paths for this property.
You have a good point. My next enhancement was to investigate handling
the entire PhotoCollection as resources rather than Files. Do you think
that is a good potential approach for fetching the collection - I think
it would/should always be located outside the webapp directory?
> Thanks for your efforts !
No problem. I'm pleased to help when I have time to spare, or when
jspwiki reaches the top of my priority list. I'm usually an "if it aint
broke, dont fix it" kind of guy...
Brian
> kind regards,
> Harry
>
>
>
> On 17 January 2014 14:03, Dave Koelmeyer <dave.koelmeyer@davekoelmeyer.co.nz
>> wrote:
>
>>
>> On 18/01/14 01:01, Brian Burch wrote:
>>
>>> My PhotoCollectionPlugin has been available for JSPWiki 2.8
>>> (com.eycrd.jspwiki packages) for several years. I have just converted it to
>>> run under the apache releases. I have tested it against 2.10, running under
>>> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>>>
>>
>>
>> Awesome!
>>
>> --
>> Dave Koelmeyer
>> http://blog.davekoelmeyer.co.nz
>>
>>
>>
>
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Harry Metske <ha...@gmail.com>.
Brian,
I played around a bit with the PhotoCollectionPlugin, a nice combination of
wiki and photo collections.
I found just two minor issues :
* The values for photoCollection.default.phototype appear to be case
sensitive (I had to add lowercase .png .jpg to get it working). I think
they should be case insensitive.
* The photoCollection.collection.base is always considered relative to the
webapp, even if you start it's value with a "/". You are forced to fiddle
in your installed war, even if you use symlinks (and start making
questionable changes to the tomcat configuration). In general we like to
stay away from "war surgery", and therefore you should be able to use
absolute paths for this property.
Thanks for your efforts !
kind regards,
Harry
On 17 January 2014 14:03, Dave Koelmeyer <dave.koelmeyer@davekoelmeyer.co.nz
> wrote:
>
> On 18/01/14 01:01, Brian Burch wrote:
>
>> My PhotoCollectionPlugin has been available for JSPWiki 2.8
>> (com.eycrd.jspwiki packages) for several years. I have just converted it to
>> run under the apache releases. I have tested it against 2.10, running under
>> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>>
>
>
> Awesome!
>
> --
> Dave Koelmeyer
> http://blog.davekoelmeyer.co.nz
>
>
>
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Dave Koelmeyer <da...@davekoelmeyer.co.nz>.
On 18/01/14 01:01, Brian Burch wrote:
> My PhotoCollectionPlugin has been available for JSPWiki 2.8
> (com.eycrd.jspwiki packages) for several years. I have just converted
> it to run under the apache releases. I have tested it against 2.10,
> running under ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
Awesome!
--
Dave Koelmeyer
http://blog.davekoelmeyer.co.nz
Re: PhotoCollectionPlugin now available with JSPWiki
Posted by Juan Pablo Santos RodrÃguez <ju...@gmail.com>.
cool, thanks Brian!
On Fri, Jan 17, 2014 at 1:01 PM, Brian Burch <br...@pingtoo.com> wrote:
> My PhotoCollectionPlugin has been available for JSPWiki 2.8
> (com.eycrd.jspwiki packages) for several years. I have just converted it to
> run under the apache releases. I have tested it against 2.10, running under
> ubuntu 13.10, OpenJDK 1.7.0_25 and apache Tomcat 7.0.42.
>
> I have just added:
> https://jspwiki-wiki.apache.org/Wiki.jsp?page=PhotoCollectionPlugin
>
> .. and linked it from:
> https://jspwiki-wiki.apache.org/Wiki.jsp?page=ContributedPlugins
>
> .. where I say:
>
> "I wonder how anyone can manage without this plugin! If you have a
> collection of photos in a single directory tree of arbitrary depth, this
> plugin will automatically associate "why not create this page" links with
> every directory and photo (without consuming any space).
>
> All you have to do is click on one of these virtual links, then simply
> save the automatically generated page, and that part of your photo
> collection gets its own wiki page. By adding wiki text to the page,
> everything becomes indexed and searchable. No more worrying about which
> year and month you went somewhere or met someone!"
>
> Come on everyone... give it a try!
>
> Regards,
>
> Brian
>