Re: Autoupdate URL with parameters

Radim Kubacki <[email protected]>
Newsgroups gmane.comp.java.netbeans.devel
Message-ID <CAOt7YhSWfDaryzL+18ywX1VVGhAz+UovRUb1O7uB3dMKJ+3w6g@mail.gmail.com>
OK, thanks for comments. Brett is correct and he explained my idea
perfectly. And I guess I can either fix this by providing my own
UpdateUnitProvider or just use some simpler workaround where I will scan &
update AUC settings in the runtime to pass information that I can use to
serve the best content.

Thank you guys,
Radim

2015-11-02 18:00 GMT+01:00 Peter Hansson <[email protected]>:

>
>
> I had the exact same issue.
>
> I first looked if there was a simple way I could overwrite NB's default
> logic in this area. What you want to do essentially is register an UC with
> not only an URL but also some query parameters that are always passed along
> with URL. Unfortunately I couldn't figure out how I could easily implement
> my own UpdateUnitProvider without replicating too much code. So I skipped
> that idea.
>
> Instead I'm using a method where the information I need to pass along is
> embedded in the Update Center URL itself, something like
> http://myserver/updatecenter/xxxx, where xxxx is some chars inside which
> I embed information. In reality - in my case - xxxx is a base64 encoded
> string of 40 chars which I can then decode on the server side. This is
> enough for me to convey the information needed.
>
> What happens is this:
>
> 1. When an application instance starts up it figures out which URL (or
> rather only the xxxx's) it must use to register the UC. It then registers'
> the UC. This is all done behind the scenes as in my case the user never
> sees the Update Center URL. It is all handled for him. He cannot add or
> remove UCs himself.
>
> 2. The application contacts the server (the Update Center) with an URL
> where only the first part is common between application instances. There's
> however only one servlet on the server side that handles all processing for
> these URL. The servlet 'decodes' the URL and then returns different results
> to the applications depending on the information it has decoded from the
> URL.
>
> Clearly this is a workaround. I believe this is not an uncommon request,
> i.e. the idea that some information should be passed along to the UC with
> every GET request and the right method to do that would of course be
> through parameters. So perhaps you should launch an RFE ?
>
>
> Peter
>
>
>
>
> On Sunday, November 1, 2015 9:08 PM, Radim Kubacki <
> [email protected]> wrote:
>
>
> >
> >
> >Hello,
> >
> >
> >is there any way how to use some parameters in AutoUpdate URL. I'd like
> to have one URL for all NBAndroid users like
> >http://nbandroid.org/release/{netbeans.version}/update.xml
> >
> >
> >This would be simpler for users when they upgrade their IDE. I want to
> have an older version of the plugin available even if I switch the
> development focus to a newer one. That forces me to have several AU centers
> and creates usability problem how to switch between them.
> >
> >
> >-Radim
> >
> >
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.